> > guess it's a small bug in the patch for tcng. > > I thought that it is required: > tc qdisc add dev eth0 handle 2:0 parent 1:0 htb default 5 r2q 100 > ~~~~~~~ The default parameter is not required for htb. I have only experience in creating htb scripts and I don't know if the tcng generated syntax is bug free. The tcng config you include seems OK to me. But don't trust me on that :) Stef > > dev "eth0" { > egress { > $base = 100 * 1kBps; > > class (<$cl1_2>) if ((raw[6] & 0xfe) == 0); > class (<$cl1_12>) if (raw[6] == 2); > class (<$cl1_10>) if (raw[6] == 0); > class (<$cl1_11>) if (raw[6] == 1); > > > htb (r2q 100) { > class(rate 10 * $base) { > $cl1_2 = class (rate 4 * $base, ceil 8 * $base,) { > $cl1_10 = class (rate 3 * $base, ceil 10 * $base, prio 1) { fifo(limit > 8p); } $cl1_11 = class (rate 1 * $base, ceil 10 * $base, prio 0) { > fifo(limit 8p); } } > } > $cl1_12 = class (rate 6 * $base, ceil 10 * $base, prio 1, default) { > fifo(limit 8p); } } > } > } > > # ================================ Device eth0 > ================================ > > tc qdisc add dev eth0 handle 1:0 root dsmark indices 8 default_index 0 > tc qdisc add dev eth0 handle 2:0 parent 1:0 htb default 5 r2q 100 > tc class add dev eth0 parent 2:0 classid 2:1 htb rate 1000000bps > tc class add dev eth0 parent 2:1 classid 2:2 htb rate 400000bps ceil > 800000bps tc class add dev eth0 parent 2:2 classid 2:3 htb rate 300000bps > ceil 1000000bps prio 1 tc qdisc add dev eth0 handle 3:0 parent 2:3 pfifo > limit 8 > tc class add dev eth0 parent 2:2 classid 2:4 htb rate 100000bps ceil > 1000000bps prio 0 tc qdisc add dev eth0 handle 4:0 parent 2:4 pfifo limit 8 > tc class add dev eth0 parent 2:0 classid 2:5 htb rate 600000bps ceil > 1000000bps prio 1 tc qdisc add dev eth0 handle 5:0 parent 2:5 pfifo limit 8 > tc filter add dev eth0 parent 2:0 protocol ip prio 1 tcindex mask 0x7 shift > 0 tc filter add dev eth0 parent 2:0 protocol ip prio 1 handle 4 tcindex > classid 2:4 tc filter add dev eth0 parent 2:0 protocol ip prio 1 handle 3 > tcindex classid 2:3 tc filter add dev eth0 parent 2:0 protocol ip prio 1 > handle 2 tcindex classid 2:5 tc filter add dev eth0 parent 2:0 protocol ip > prio 1 handle 1 tcindex classid 2:2 tc filter add dev eth0 parent 1:0 > protocol ip prio 1 handle 1:0:0 u32 divisor 1 tc filter add dev eth0 parent > 1:0 protocol ip prio 1 u32 match u8 0x0 0xfe at 6 classid 1:1 tc filter add > dev eth0 parent 1:0 protocol ip prio 1 u32 match u8 0x2 0xff at 6 classid > 1:2 tc filter add dev eth0 parent 1:0 protocol ip prio 1 u32 match u8 0x0 > 0xff at 6 classid 1:3 tc filter add dev eth0 parent 1:0 protocol ip prio 1 > u32 match u8 0x1 0xff at 6 classid 1:4 > > _______________________________________________ > LARTC mailing list / LARTC@mailman.ds9a.nl > http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/ -- stef.coene@docum.org "Using Linux as bandwidth manager" http://www.docum.org/ #lartc @ irc.openprojects.net _______________________________________________ LARTC mailing list / LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/