* [LARTC] HTB and diff.serv
@ 2001-12-05 16:43 Øystein Løkås
2001-12-05 16:54 ` Øystein Løkås; NTNU; H01
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: Øystein Løkås @ 2001-12-05 16:43 UTC (permalink / raw)
To: lartc
Hi all.
As part of a project on the Norweigan University of Science and
Technology, I am trying to implement diffserv on a linux router. I have
started using HTB as part of this, since I have read the documentation on
it and find it easier to use than CBQ.
But I ran into problems when I tried to implement the AF classes. To do
this, I map each AF class to one HTB class. Now I need to attach a GRED
queue to each of the HTB classes to implement the drop preferences. But
GRED needs the skb->tcindex field from the dsmark qdisc to select the
correct virtual queue. So I configured dsmark as the root qdisc, and HTB inside this. But now I can't
use filters inside the HTB qdisc, because it is an internal qdisc.
Is it anyway around this, or do I have to go back to using CBQ? I'd rather not,
because it has given me some weird results earlier, and HTB works like a
charm!
My setup is something like this (_very_ incomplete code):
tc qdisc add dev eth0 root handle 1: dsmark
tc qdisc add dev eth0 parent 1:0 handle 2:0 htb
tc class add dev eth0 parent 2:0 classid 2:1 htb
tc class add dev eth0 parent 2:1 classid 2:10 htb
tc class add dev eth0 parent 2:1 classid 2:20 htb
tc class add dev eth0 parent 2:1 classid 2:30 htb
tc class add dev eth0 parent 2:1 classid 2:40 htb
2 of these classes are for EF and BE. That is not a problem. The other 2
are for AF1x and AF2x. Now I need the GRED queue:
tc qdisc add dev eth0 parent 2:20 handle 3:0
tc qdisc add dev eth0 parent 2:30 handle 4:0
The problem with this setup is as mentioned, to be able to filter the
packets into the right htb class. I'm hoping anyone can help me with this.
Øystein Løkås.
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/2.4Routing/
^ permalink raw reply [flat|nested] 5+ messages in thread* [LARTC] HTB and diff.serv
2001-12-05 16:43 [LARTC] HTB and diff.serv Øystein Løkås
@ 2001-12-05 16:54 ` Øystein Løkås; NTNU; H01
2001-12-06 6:21 ` Martin Devera
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Øystein Løkås; NTNU; H01 @ 2001-12-05 16:54 UTC (permalink / raw)
To: lartc
Hi all.
As part of a project on the Norweigan University of Science and
Technology, I am trying to implement diffserv on a linux router. I have
started using HTB as part of this, since I have read the documentation on
it and find it easier to use than CBQ.
But I ran into problems when I tried to implement the AF classes. To do
this, I map each AF class to one HTB class. Now I need to attach a GRED
queue to each of the HTB classes to implement the drop preferences. But
GRED needs the skb->tcindex field from the dsmark qdisc to select the
correct virtual queue. So I configured dsmark as the root qdisc, and HTB inside this. But now I can't
use filters inside the HTB qdisc, because it is an internal qdisc.
Is it anyway around this, or do I have to go back to using CBQ? I'd rather not,
because it has given me some weird results earlier, and HTB works like a
charm!
My setup is something like this (_very_ incomplete code):
tc qdisc add dev eth0 root handle 1: dsmark
tc qdisc add dev eth0 parent 1:0 handle 2:0 htb
tc class add dev eth0 parent 2:0 classid 2:1 htb
tc class add dev eth0 parent 2:1 classid 2:10 htb
tc class add dev eth0 parent 2:1 classid 2:20 htb
tc class add dev eth0 parent 2:1 classid 2:30 htb
tc class add dev eth0 parent 2:1 classid 2:40 htb
2 of these classes are for EF and BE. That is not a problem. The other 2
are for AF1x and AF2x. Now I need the GRED queue:
tc qdisc add dev eth0 parent 2:20 handle 3:0
tc qdisc add dev eth0 parent 2:30 handle 4:0
The problem with this setup is as mentioned, to be able to filter the
packets into the right htb class. I'm hoping anyone can help me with this.
Øystein Løkås.
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/2.4Routing/
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [LARTC] HTB and diff.serv
2001-12-05 16:43 [LARTC] HTB and diff.serv Øystein Løkås
2001-12-05 16:54 ` Øystein Løkås; NTNU; H01
@ 2001-12-06 6:21 ` Martin Devera
2001-12-06 8:23 ` Øystein Løkås; NTNU; H01
2001-12-06 8:33 ` Martin Devera
3 siblings, 0 replies; 5+ messages in thread
From: Martin Devera @ 2001-12-06 6:21 UTC (permalink / raw)
To: lartc
> But I ran into problems when I tried to implement the AF classes. To do
> this, I map each AF class to one HTB class. Now I need to attach a GRED
> queue to each of the HTB classes to implement the drop preferences. But
> GRED needs the skb->tcindex field from the dsmark qdisc to select the
> correct virtual queue. So I configured dsmark as the root qdisc, and HTB inside this. But now I can't
> use filters inside the HTB qdisc, because it is an internal qdisc.
There is nothing which should you prevent from using filters
with internal (non root) qdisc ..
What problem are you experiencing ?
devik
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/2.4Routing/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [LARTC] HTB and diff.serv
2001-12-05 16:43 [LARTC] HTB and diff.serv Øystein Løkås
2001-12-05 16:54 ` Øystein Løkås; NTNU; H01
2001-12-06 6:21 ` Martin Devera
@ 2001-12-06 8:23 ` Øystein Løkås; NTNU; H01
2001-12-06 8:33 ` Martin Devera
3 siblings, 0 replies; 5+ messages in thread
From: Øystein Løkås; NTNU; H01 @ 2001-12-06 8:23 UTC (permalink / raw)
To: lartc
On Thu, 6 Dec 2001, Øystein Løkås wrote:
>
> > But I ran into problems when I tried to implement the AF classes. To do
> > this, I map each AF class to one HTB class. Now I need to attach a GRED
> > queue to each of the HTB classes to implement the drop preferences. But
> > GRED needs the skb->tcindex field from the dsmark qdisc to select the
> > correct virtual queue. So I configured dsmark as the root qdisc, and HTB inside this. But now I can't
> > use filters inside the HTB qdisc, because it is an internal qdisc.
>
> There is nothing which should you prevent from using filters
> with internal (non root) qdisc ..
>
> What problem are you experiencing ?
>
> devik
>
Hmm.. maybe I'm wrong. I tried this yesterday afternoon, and got a
RTNETLINK error message. I think it was "no such file or directory". Then
I thought I remembered reading in your documentation that filters couldn't
be attached to internal htb qdisc, so I tried to use the same setup with
CBQ classes, and that worked.
But if you say it can be done, I will take another good look at my code
and try again. I would certainly like to be able to use HTB for this
purpose, because it has given me great results with link-sharing so far.
Thanks for a good and easy to use qdisc..;-)
Øystein Løkås
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/2.4Routing/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [LARTC] HTB and diff.serv
2001-12-05 16:43 [LARTC] HTB and diff.serv Øystein Løkås
` (2 preceding siblings ...)
2001-12-06 8:23 ` Øystein Løkås; NTNU; H01
@ 2001-12-06 8:33 ` Martin Devera
3 siblings, 0 replies; 5+ messages in thread
From: Martin Devera @ 2001-12-06 8:33 UTC (permalink / raw)
To: lartc
> > There is nothing which should you prevent from using filters
> > with internal (non root) qdisc ..
> >
> > What problem are you experiencing ?
>
> Hmm.. maybe I'm wrong. I tried this yesterday afternoon, and got a
> RTNETLINK error message. I think it was "no such file or directory". Then
> I thought I remembered reading in your documentation that filters couldn't
> be attached to internal htb qdisc, so I tried to use the same setup with
> CBQ classes, and that worked.
That doc only said that you can't attach (yet) filter to inner CLASS not
qdisc itself. But Bert is working on it so that you should be able to
do it in short time.
> purpose, because it has given me great results with link-sharing so far.
> Thanks for a good and easy to use qdisc..;-)
nice to hear ;-) I'm currently cleaning the source up to be
ready for merge into 2.4 so that I definitely need all user
feedback I can get.
devik
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://ds9a.nl/2.4Routing/
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2001-12-06 8:33 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-12-05 16:43 [LARTC] HTB and diff.serv Øystein Løkås
2001-12-05 16:54 ` Øystein Løkås; NTNU; H01
2001-12-06 6:21 ` Martin Devera
2001-12-06 8:23 ` Øystein Løkås; NTNU; H01
2001-12-06 8:33 ` Martin Devera
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox