We have been using HTB for last 10-11 months
without any problem. But from last few days we have been facing huge packet loss
when we turn on traffic shaping using HTB. I upgraded to 2.4.24 kernel (without
any htb patch), still there is same problem.
Avg. traffic is around 2Mbps and 4Mbps at peak
hours. There are around 110 HTB classes and SFQ attached to each
class.
We are using 4 port Tulip (only 2 ports
in use) card and a 3Com 59x card.
Previously I was using default quantum and
r2q values for all the classes.
Somewhere I saw quantum = (link in Kbit) * 1024 / (
8 * 1500) so I tried by increasing the qntm. value of the main class (and
other classes with rate above 512K) still there is no improvement.
tc qdisc add dev eth2 root handle 3: htb default
256
tc class add dev eth2 parent 3: classid 3:1 htb
quantum 786 rate 9mbit ceil 9mbit (this is the main class)
These rules are to shape client b/w. There are more
100 rules like this.
tc class add dev eth2 parent 3:1 classid 3:11
htb quantum 10 rate 64kbit ceil 64kbit
tc class add dev eth0 parent 1:1 classid 1:11 htb quantum 10 rate 64kbit ceil 64kbit iptables -t mangle -A FORWARD -s 192.168.0.11 -j MARK --set-mark 11 iptables -t mangle -A FORWARD -s 192.168.0.11 -j MARK --set-mark 11 tc filter add dev eth2 protocol ip parent 3: prio 5 handle 11 fw
classid 3:11
tc filter add dev eth0 protocol ip parent 1: prio 5 handle 11 fw classid 1:11 tc qdisc add dev eth2 parent 3:11 sfq perturb 10 tc qdisc add dev eth0 parent 1:11 sfq perturb 10 I'm not able to find out what the problem is. For backup I'm thinking to
switch to FreeBSD. I'll be glad to read your suggestions.
Thanks to everyone.
with regards,
Birkant Neupane
|