- 论坛徽章:
- 0
|
老大,我抄了一个限速的pf.conf,
我用的是8139卡,主机用于ADSL网关,rl0为局域网,rl1通ADSL MODEN
现在就是不能限速,帮忙看看,怎样改才能把192.168.1.220的上传定为10Kb,下载定为20Kb,
192.168.1.5上传定为15Kb,下载定为5Kb呢??
下面这个就是有问题,请帮忙看看,谢谢..
- ext_if="tun0"
- int_if="rl0"
- user_1="192.168.1.5"
- user_2="192.168.1.6"
- user_3="192.168.1.29"
- me_if="192.168.1.220"
- set state-policy if-bound
- set block-policy return
- set optimization aggressive
- scrub in all
- altq on $ext_if hfsc bandwidth 64Kb queue { u1, uother, dme}
- queue u1 bandwidth 5Kb hfsc ( upperlimit 5Kb red )
- queue dme bandwidth 20Kb hfsc ( upperlimit 20Kb red)
- queue uother bandwidth 32Kb hfsc ( default upperlimit 48Kb )
- altq on $int_if hfsc bandwidth 100Mb queue{ c1, other ,ume}
- queue c1 bandwidth 15Kb hfsc( upperlimit 15Kb red )
- queue ume bandwidth 10Kb hfsc( upperlimit 10Kb red)
- queue other bandwidth 20Kb hfsc( default upperlimit 29Kb)
- block all
- pass quick on lo0 all
- antispoof for $ext_if
- pass in on $ext_if inet proto tcp from any to ($ext_if) port ssh flags S/SA keep
- state
- pass in quick on $int_if inet from $me_if to any keep state tag $me_if queue dme
- pass out quick on $ext_if inet all keep state tagged $me_if queue ume
- pass in quick on $int_if inet from $user_1 to any keep state tag $user_1 queue u
- 1
- pass out quick on $ext_if inet all keep state tagged $user_1 queue c1
- pass in quick on $int_if inet from $user_2 to any keep state tag $user_2 queue u
- 1
- pass out quick on $ext_if inet all keep state tagged $user_2 queue c1
复制代码 |
|