i'm a bit lost with the command line of "tc class add"
first i do that and it works
# tc qdisc add dev eth0 root handle 1: prio
# tc filter add dev eth0 protocol ip parent 1: prio 1 u32 match ip
dport 22 0xffff flowid 1:1
then i do
# tc class add dev eth0 parent:1.0 classid1:2
and the result is "RTNETLINK answers: File Exist"
which seams normal to me because when i create the prio qdisc with
the first command it add automatically 3 classes (1:1, 1:2, 1:3)
No, i think the problem is not here. It must be the 'how-to' i refer
to which must be false.
So how to choose 1 of the 3 queue of prio as the default
one. ...that remains a mistery.
anyway thanks for your help.
Vincent.
Le 27 juil. 07 à 04:00, 吴明津 a écrit :
you should try to add the class that the filter said unknown flowid
On 7/27/07, Vincent Dautremont <vdautrem@xxxxxxxxx> wrote:
Are you sure ?
because that's not what is written in the how-to
http://lartc.org/howto/lartc.qdisc.classful.html
check section 9.5.3 which says that three classes are
automatically created
by default.
and in section 9.5.3.2 :
# tc qdisc add dev eth0 root handle 1: prio
## This *instantly* creates classes 1:1, 1:2, 1:3
Vincent.
Le 27 juil. 07 à 03:45, 吴明津 a écrit :
It seems you miss the class .
On 7/27/07, Vincent Dautremont <vdautrem@xxxxxxxxx> wrote:
Le 26 juil. 07 à 13:55, Georgi Alexandrov a écrit :
> Vincent Dautremont wrote:
>
>> Hi,
>> here I have another newcomer question :-)
>> in the section 9.6.1 of this how too
>>
http://tldp.org/HOWTO/Adv-Routing-HOWTO/lartc.qdisc.filters.html
>> we can read commands about filters :
>> ------------------------------------------
>>
>> # tc filter add dev eth0 protocol ip parent 10: prio 1 u32 match \
>> ip dport 22 0xffff flowid 10:1
>> # tc filter add dev eth0 protocol ip parent 10: prio 1 u32 match \
>> ip sport 80 0xffff flowid 10:1
>> # tc filter add dev eth0 protocol ip parent 10: prio 2 flowid 10:2
>>
>> What does this say? It says: attach to eth0, node 10: a priority 1
>> u32
>> filter that matches on IP destination port 22 *exactly* and send
>> it to
>> band 10:1. And it then repeats the same for source port 80. The
last
>> command says that anything unmatched so far should go to band
>> 10:2, the
>> next-highest priority.
>>
>> ------------------------------------------
>>
>> i try to do this at home as i want my ssh traffic prioritary to
other
>> traffic but the problem is with the last command ! it simply don't
>> work.
>> The last command that says default trafic goes to prio 2
doesn't work
>>
>> # tc filter add dev eth0 protocol ip parent 10: prio 2 flowid 10:2
>>
>> just give me the error: "Unknown filter flowid, hence option
1:2 is
>> unparsable"
>>
>> So I don't get what do I must do in order to say that the default
>> trafic
>> goes on priority 2 of the prio filter
>>
>> is this how too always valid with the current version of tc ? did
>> i do
>> something wrong ?
>>
>> Thank you for your help.
>>
> <snip>
>
> You should have posted *all* your tc rules.
>
> --
> regards,
> Georgi Alexandrov
>
> key server - pgp.mit.edu :: key id - 0x37B4B3EE
> Key fingerprint = E429 BF93 FA67 44E9 B7D4 F89E F990 01C1 37B4
B3EE
>
>
Ok, thanks for you advise, here are all my tc rules :
# tc qdisc add dev eth0 root handle 1: prio
# tc filter add dev eth0 protocol ip parent 1: prio 1 u32 match ip
dport 22 0xffff flowid 1:1
# tc filter add dev eth0 protocol ip parent 1: prio 2 flowid 1:2
----
does this lack one rule ? anyway the last one is not accepted by tc.
Vincent.
_______________________________________________
LARTC mailing list
LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
_______________________________________________
LARTC mailing list
LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc