bandwidth controlling with ALTQ

Volker volker at vwsoft.com
Fri May 18 09:25:07 UTC 2007


On 05/18/07 10:12, Umar wrote:
> Dear Members!
> 
>  I am running cable internet and I have 1Mb DSL link now I want to restrict
> my user's bandwidth. e.g I want to restrict per IP bandwidth 10KB (donwload
> and upload) so please help me how i can mange in PF-ALTQ.
> 
> my pf.conf
> 
> int_inf = emo
> ext_inf = fxp0
> 
> local_net = 192.168.1.0/24

Umar,

if you want to limit per IP address, you need to create one queue for
every IP address in your internal network. The bandwidth sum of all
queues must not exceed the bandwidth of the root queue. If your
upstream has a b/w of 256 kBit/s (if it's asymmetric) you can only
create 25 queues with 10 kBit/s.

You may consider doing it different, as creating one queue for every
internal IP address is a nightmare for administration.

I'm using hfsc scheduler for the internal network, so every IP should
be served fair and a limited cbq queue for them on the external
interface and reach good results with that. If b/w is limited as other
traffic passes, these stations get their traffic through limited.

HTH

Volker


More information about the freebsd-pf mailing list