Skip to contentSkip to conversation

Some good news - Strange behavior deleting filters

LARTC Andre Correa 2 participants 2 messages Jan 9, 2004 – Jan 10, 2004

lore
Share & tools
lore
#0 lore raw

Hi list,

I've got a private e-mail from O. Brewer pointing something important that we hadn't figured out yet:

tc qdisc del dev eth1 root
tc qdisc add dev eth1 root handle 1:0 htb
tc class add dev eth1 parent 1:0 classid 1:1 htb rate 1mbit tc class add dev eth1 parent 1:0 classid 1:2 htb rate 1mbit tc filter add dev eth1 parent 1:0 protocol ip prio 1 handle ::10 u32 match ip src 10.10.10.10 classid 1:1
tc filter add dev eth1 parent 1:0 protocol ip prio 1 handle ::11 u32 match ip src 10.10.10.11 classid 1:2

tc -r filter show dev eth1 parent 1:
filter protocol ip pref 1 u32 filter protocol ip pref 1 u32 fh 800:[80000000] ht divisor 1 filter protocol ip pref 1 u32 fh
800::10[80000010] order 16 key ht 800 bkt 0 flowid 1:1 match
0a0a0a0a/ffffffff at 12
filter protocol ip pref 1 u32 fh 800::11[80000011] order 17 key ht 800
bkt 0 flowid 1:2 match 0a0a0a0b/ffffffff at 12

tc filter del dev eth1 parent 1: protocol ip prio 1 handle 800::11 u32

tc -r filter show dev eth1 parent 1:
filter protocol ip pref 1 u32 filter protocol ip pref 1 u32 fh 800:[80000000] ht divisor 1 filter protocol ip pref 1 u32 fh
800::10[80000010] order 16 key ht 800 bkt 0 flowid 1:1 match
0a0a0a0a/ffffffff at 12

as we expect...

So we figure out that using handle and u32 in the end of our command line works fine. Good... There is still a lot of trouble to figure out what is the value of handle XXX::yy when it is a script that manages filters, but it is better then nothing...

tks for pointing this out Orlie...

Anybody else replicated the behavior? Does anybody know is tc development is taking place?

tks a lot...

Andre
_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

#1 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Andre,

Very good, I tried that too and its work :-)
Note: I'm using kernel 2.4.21.

Telles

Andre Correa wrote:

|
| Hi list,
|
| I've got a private e-mail from O. Brewer pointing something important
| that we hadn't figured out yet:
|
| tc qdisc del dev eth1 root
| tc qdisc add dev eth1 root handle 1:0 htb
| tc class add dev eth1 parent 1:0 classid 1:1 htb rate 1mbit
| tc class add dev eth1 parent 1:0 classid 1:2 htb rate 1mbit
| tc filter add dev eth1 parent 1:0 protocol ip prio 1 handle ::10 u32
| match ip src 10.10.10.10 classid 1:1
| tc filter add dev eth1 parent 1:0 protocol ip prio 1 handle ::11 u32
| match ip src 10.10.10.11 classid 1:2
|
|
| tc -r filter show dev eth1 parent 1:
| filter protocol ip pref 1 u32 filter protocol ip pref 1 u32 fh
| 800:[80000000]  ht divisor 1 filter protocol ip pref 1 u32 fh
| 800::10[80000010]  order 16 key ht 800 bkt 0 flowid 1:1   match
| 0a0a0a0a/ffffffff at 12
| filter protocol ip pref 1 u32 fh 800::11[80000011]  order 17 key ht 800
| bkt 0 flowid 1:2   match 0a0a0a0b/ffffffff at 12
|
| tc filter del dev eth1 parent 1: protocol ip prio 1 handle 800::11 u32
|
| tc -r filter show dev eth1 parent 1:
| filter protocol ip pref 1 u32 filter protocol ip pref 1 u32 fh
| 800:[80000000]  ht divisor 1 filter protocol ip pref 1 u32 fh
| 800::10[80000010]  order 16 key ht 800 bkt 0 flowid 1:1   match
| 0a0a0a0a/ffffffff at 12
|
| as we expect...
|
| So we figure out that using handle and u32 in the end of our command
| line works fine. Good... There is still a lot of trouble to figure out
| what is the value of handle XXX::yy when it is a script that manages
| filters, but it is better then nothing...
|
| tks for pointing this out Orlie...
|
| Anybody else replicated the behavior? Does anybody know is tc
| development is taking place?
|
| tks a lot...
|
| Andre
| _______________________________________________
| LARTC mailing list / [email protected]
| http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
|
|

- --
- ------------------------------------------------------ Rodrigo P. Telles <[email protected]>
Gerente de Projetos - http://www.devel-it.com.br
Devel-IT - Uma empresa do Grupo TDKOM
- ------------------------------------------------------ -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFAAHdyiLK8unYgEMQRAnpvAJ9jyj2AJJDwrPZLdJMnXiuIJ4qqyQCePOjC XLtX5GIX2SnByWadnTU1QwQ=zlOC
-----END PGP SIGNATURE-----

_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/