=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/share/pf/Attic/faq-example3,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- src/share/pf/Attic/faq-example3 2003/08/06 16:04:45 1.2 +++ src/share/pf/Attic/faq-example3 2005/07/02 16:16:39 1.3 @@ -1,11 +1,11 @@ -# $OpenBSD: faq-example3,v 1.2 2003/08/06 16:04:45 henning Exp $ +# $OpenBSD: faq-example3,v 1.3 2005/07/02 16:16:39 joel Exp $ # # Company Network # http://www.openbsd.org/faq/pf/queueing.html#example2 # - + # enable queueing on the external interface to queue packets going out # to the Internet. use the cbq scheduler so that the bandwidth use of # each queue can be controlled. the max outgoing bandwidth is 1.5Mbps. @@ -17,15 +17,15 @@ # outgoing traffic on fxp0. # www_ext - container queue for WWW server queues. limit to # 500Kbps. -# www_ext_http - http traffic from the WWW server -# www_ext_misc - all non-http traffic from the WWW server -# boss_ext - traffic coming from the boss's computer +# www_ext_http - http traffic from the WWW server; higher priority. +# www_ext_misc - all non-http traffic from the WWW server. +# boss_ext - traffic coming from the boss's computer. -queue std_ext cbq(default) +queue std_ext bandwidth 500Kb cbq(default borrow) queue www_ext bandwidth 500Kb { www_ext_http, www_ext_misc } - queue www_ext_http priority 3 cbq(red) - queue www_ext_misc priority 1 -queue boss_ext priority 3 + queue www_ext_http bandwidth 50% priority 3 cbq(red borrow) + queue www_ext_misc bandwidth 50% priority 1 cbq(borrow) +queue boss_ext bandwidth 500Kb priority 3 cbq(borrow) # enable queueing on the internal interface to control traffic coming # from the Internet or the DMZ. use the cbq scheduler to control the @@ -41,15 +41,15 @@ # is 1.0Mbps. # std_int - the standard queue. also the default queue for outgoing # traffic on dc0. -# it_int - traffic to the IT Dept network. -# boss_int - traffic to the boss's PC. -# www_int - traffic from the WWW server in the DMZ. +# it_int - traffic to the IT Dept network; reserve them 500Kbps. +# boss_int - traffic to the boss's PC; assign a higher priority. +# www_int - traffic from the WWW server in the DMZ; full speed. queue net_int bandwidth 1.0Mb { std_int, it_int, boss_int } - queue std_int cbq(default) + queue std_int bandwidth 250Kb cbq(default borrow) queue it_int bandwidth 500Kb cbq(borrow) - queue boss_int priority 3 -queue www_int cbq(red) + queue boss_int bandwidth 250Kb priority 3 cbq(borrow) +queue www_int bandwidth 99Mb cbq(red borrow) # enable queueing on the DMZ interface to control traffic destined for # the WWW server. cbq will be used on this interface since detailed @@ -63,13 +63,13 @@ # define the parameters for the child queues. # internal_dmz - traffic from the internal network. # net_dmz - container queue for traffic from the Internet. -# net_dmz_http - http traffic. +# net_dmz_http - http traffic; higher priority. # net_dmz_misc - all non-http traffic. this is also the default queue. -queue internal_dmz # no special settings needed +queue internal_dmz bandwidth 99Mb cbq(borrow) queue net_dmz bandwidth 500Kb { net_dmz_http, net_dmz_misc } - queue net_dmz_http priority 3 cbq(red) - queue net_dmz_misc priority 1 cbq(default) + queue net_dmz_http bandwidth 50% priority 3 cbq(red borrow) + queue net_dmz_misc bandwidth 50% priority 1 cbq(default borrow) # ... in the filtering section of pf.conf ...