186d7f5d3SJohn Marino# $OpenBSD: queue4,v 1.2 2003/08/22 21:50:34 david Exp $ 286d7f5d3SJohn Marino# $DragonFly: src/share/examples/pf/queue4,v 1.1 2005/12/13 01:58:27 corecode Exp $ 386d7f5d3SJohn Marino# 486d7f5d3SJohn Marino# Hierarchical queueing for a university. 586d7f5d3SJohn Marino# Three faculties; engineering, law and art are defined. 686d7f5d3SJohn Marino# Departments under the engineering faculty are defined as child queues. 786d7f5d3SJohn Marino# The total bandwidth for engineering faculty is shared between three 886d7f5d3SJohn Marino# departments. CS department gets the half of the bandwidth, EE and IE 986d7f5d3SJohn Marino# departments get the thirty percent and twenty percent of bandwidth 1086d7f5d3SJohn Marino# respectively. These sibling departments can use more than their linkshare 1186d7f5d3SJohn Marino# whenever there is no backlogged sibling queue but when a queue gets 1286d7f5d3SJohn Marino# backlogged, it is guaranteed that the queue gets its linkshare. 1386d7f5d3SJohn Marino 1486d7f5d3SJohn Marinoaltq on dc0 bandwidth 16Mb hfsc queue { eng law art } 1586d7f5d3SJohn Marinoqueue eng bandwidth 10Mb { cs ee ie } 1686d7f5d3SJohn Marinoqueue cs hfsc( default linkshare 50% ) 1786d7f5d3SJohn Marinoqueue ee hfsc( linkshare 30% ) 1886d7f5d3SJohn Marinoqueue ie hfsc( linkshare 20% ) 1986d7f5d3SJohn Marinoqueue law bandwidth 3Mb 2086d7f5d3SJohn Marinoqueue art bandwidth 3Mb 21