I use CBQ with sfq and tbf. I want to have one "mother" class that gets all traffic in our network. So I define cbq-0010.mother with RULE=:,192.0.0.0/24 and I want a subclass to get all the data from a specific ip. So I define a subclass cbq-0065.8011_in with PARENT:0010 and RULE=192.0.0.10 It doesnt matter how I do it. I''ve tested chainging the names, parent numbers and so on. The mother class always gets all the data.. Why ? Ofcourse the first rule says that it should but, what if there''se some other class that also would have triggerd on the packet ? How do I control witch class gets what packet, if therese multiple true rules.. ?? please, anyone ?? / Paul
On Sat, Dec 08, 2001 at 01:45:30PM +0100, Paul Wis?n wrote:> I use CBQ with sfq and tbf.Paul, I''ve seen your ''small ISP'' posting but have not yet gotten round to thinking it over.> > I want to have one "mother" class that gets all traffic in our network. > So I define cbq-0010.mother > with RULE=:,192.0.0.0/24You are using cbq.init.> > and I want a subclass to get all the data from a specific ip. > So I define a subclass > > cbq-0065.8011_in > with > PARENT:0010 > and RULE=192.0.0.10 > > It doesnt matter how I do it. I''ve tested chainging the names, parent > numbers and so on. > The mother class always gets all the data.. Why ?# LEAF=none|tbf optional, default "tbf" # # Instructs the script to attach leaf queueing discipline to CBQ class. # By default, TBF is used. This parameter is useful for parent classes # where you probably want to specify LEAF=none. In future it might be # possible to use SFQ or CBQ (or other) as leaf qdisc. You might want to specify that. But it might be that you are exceeding the limits of cbq.init. What you basically need is to get your second class to have a filter that comes *first*, before the filter directing all everything to cbq-0010!> Ofcourse the first rule says that it should but, what if there''se some other > class that also would have triggerd on the packet ? How do I control witch > class gets what packet, if therese multiple true rules.. ??You can also set cbq.init to write out what it will do. Then you can change the priority of filters, making sure that the more specific rules get tested first. Regards, bert -- http://www.PowerDNS.com Versatile DNS Software & Services Trilab The Technology People Netherlabs BV / Rent-a-Nerd.nl - Nerd Available - ''SYN! .. SYN|ACK! .. ACK!'' - the mating call of the internet
Hi, and thanks a _lot_ for the answers. Got some question first i need to ask though, before I can try that out.> > > > I want to have one "mother" class that gets all traffic in our network. > > So I define cbq-0010.mother > > with RULE=:,192.0.0.0/24 > > You are using cbq.init.ehrm.. did I forgot to tell you that ? :)> # LEAF=none|tbf optional, default "tbf" > # > # Instructs the script to attach leaf queueing discipline > to CBQ class. > # By default, TBF is used. This parameter is useful for > parent classes > # where you probably want to specify LEAF=none. In future > it might be > # possible to use SFQ or CBQ (or other) as leaf qdisc. > > You might want to specify that. But it might be that you are exceeding the > limits of cbq.init.But, if I set LEAF=none, the mother class will not do any Fair Quing.. And, that''s what I want. Exept that protocols like ssh and such should always come through first.> > What you basically need is to get your second class to have a filter that > comes *first*, before the filter directing all everything to cbq-0010!Agree, the question is how do I do that.. I''ve been playing around with different names on the classes, different classid''s and so on, trying to figure out how I control what class will come first. Now, Maybe the PRIO is the thing that sets that, but then, why didn''t it work then, ssh got prio 1 in my configuration..> > Ofcourse the first rule says that it should but, what if > there''se some other > > class that also would have triggerd on the packet ? How do I > control witch > > class gets what packet, if therese multiple true rules.. ?? > > You can also set cbq.init to write out what it will do.how ??> Then you can change > the priority of filters, making sure that the more specific rules > get tested first. >I will try that again then. / Paul
On Sat, Dec 08, 2001 at 05:24:06PM +0100, Paul Wisen wrote:> Hi, and thanks a _lot_ for the answers.No problem. These answers are found by google - a lot. Think of answering these questions as being an audience for the internet.> > # LEAF=none|tbf optional, default "tbf"(...)> > You might want to specify that. But it might be that you are exceeding the > > limits of cbq.init. > > But, if I set LEAF=none, the mother class will not do any Fair Quing.. And, > that''s what I want. Exept that protocols like ssh and such should always > come through first.Ok. That''s often the most important part, precisely specifying what you want.> > What you basically need is to get your second class to have a filter that > > comes *first*, before the filter directing all everything to cbq-0010! > > Agree, the question is how do I do that..> > > class gets what packet, if therese multiple true rules.. ?? > > > > You can also set cbq.init to write out what it will do. > > how ??Edit the script and change this line: ### Uncomment for debugging #LOG_FILE="/var/run/cbq-$1" Then it should be easy to see what is happening, or to change it. Also, look at HTB, it is very well suited for what you try to achieve. Regards, bert -- http://www.PowerDNS.com Versatile DNS Software & Services Trilab The Technology People Netherlabs BV / Rent-a-Nerd.nl - Nerd Available - ''SYN! .. SYN|ACK! .. ACK!'' - the mating call of the internet