* Per IP maximal speed limit inside HTB class
@ 2008-01-16 11:30 Покотиленко Костик
2008-01-16 16:04 ` Dzianis Kahanovich
0 siblings, 1 reply; 2+ messages in thread
From: Покотиленко Костик @ 2008-01-16 11:30 UTC (permalink / raw)
To: netfilter
Hi there,
I already have HTB class tree which makes channel division between
client groups.
One of those groups now has to have clients with limited maximal speed
to implement "unlimited" traffic billing.
So the question is: is there any queueing discipline which can limit
maximal speed for any source/destination IP with one rule so that I
would not have to insert clases for each new IP?
For example it would be perfect if I could make something like this:
+ HTB class with from 5 Mbit/s to 5 Mbit/s
| HTB class with from 1 Mbit/s to 5 Mbit/s prio 2 (for clients without
unlimited traffic)
| HTB class with from 4 Mbit/s to 5 Mbit/s prio 1 (for clients with
unlimited traffic)
+ {some limit qdisc}
| max speed limit 128 KBit/s (for 128K unlimited traffic) prio 1
| max speed limit 256 KBit/s (for 128K unlimited traffic) prio 2
| max speed limit 512 KBit/s (for 128K unlimited traffic) prio 3
Any hints?
--
Покотиленко Костик <casper@meteor.dp.ua>
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: Per IP maximal speed limit inside HTB class
2008-01-16 11:30 Per IP maximal speed limit inside HTB class Покотиленко Костик
@ 2008-01-16 16:04 ` Dzianis Kahanovich
0 siblings, 0 replies; 2+ messages in thread
From: Dzianis Kahanovich @ 2008-01-16 16:04 UTC (permalink / raw)
To: netfilter; +Cc: casper
Покотиленко Костик wrote:
> I already have HTB class tree which makes channel division between
> client groups.
> One of those groups now has to have clients with limited maximal speed
> to implement "unlimited" traffic billing.
>
> So the question is: is there any queueing discipline which can limit
> maximal speed for any source/destination IP with one rule so that I
> would not have to insert clases for each new IP?
There are not too nefilter questions, but while I experiment with
unconditional class 3 of PSPacer 2.1[.1]
(http://www.gridmpi.org/pspacer-2.1/index.en.jsp), I remember there are IMHO
may (with additional programming) do it. Mode 3 still not complete and fall
kernel, but I comment out estimate_target_rate() code up to "cl->rate =
cp->rate;" line and do "cl->rate = <rate>;" and IMHO rate was reached. But I
not sure about there are warrantied rate. You may try to remove "tcp" code
from PSPacer and make some kind of hash, based on source and|or destination
IP. I just not found way to use it - I prefer to bound rate for my network to
common channel and use it in concurrent way to fill channel. And not sure to
commercial-quality of rate (there are high-quality lostless scheduler, but
"warrantied" rate are not high-quality in this sense, only limited).
Else you must use not QoS (like HTB) anymore, just drop packets up the limit
with "tc filter ... policy ..." commands. There are not netfilter too.
>
> For example it would be perfect if I could make something like this:
>
> + HTB class with from 5 Mbit/s to 5 Mbit/s
> | HTB class with from 1 Mbit/s to 5 Mbit/s prio 2 (for clients without
> unlimited traffic)
> | HTB class with from 4 Mbit/s to 5 Mbit/s prio 1 (for clients with
> unlimited traffic)
> + {some limit qdisc}
> | max speed limit 128 KBit/s (for 128K unlimited traffic) prio 1
> | max speed limit 256 KBit/s (for 128K unlimited traffic) prio 2
> | max speed limit 512 KBit/s (for 128K unlimited traffic) prio 3
>
> Any hints?
>
--
WBR,
Denis Kaganovich, mahatma@eu.by http://mahatma.bspu.unibel.by
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-01-16 16:04 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-16 11:30 Per IP maximal speed limit inside HTB class Покотиленко Костик
2008-01-16 16:04 ` Dzianis Kahanovich
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox