All of lore.kernel.org
 help / color / mirror / Atom feed
* Should I define 4K classes if I want to give 4K user each a fix bandwidth of 70kbps
@ 2014-09-15  6:58 Akshat Kakkar
  2014-09-15  9:43 ` Andy Furniss
  0 siblings, 1 reply; 2+ messages in thread
From: Akshat Kakkar @ 2014-09-15  6:58 UTC (permalink / raw)
  To: lartc

I am having around 4K users. I have to limit each user to 70kbps
bandwidth. For this, I define 4K filters and 4K classes. Each filter
is matched to each ip of an user, and each class is configured for a
rate of 70kbps. Then I define 4K sfq qdisc mapped to each class.
It works fine. No issues.

But just that creating 4K exactly similar classes with just a
difference in classid, is a kind of time consuming. The same holds for
filters and sfq too.

Is there a simpler way of doing it?

I can't use iptables marking as I am using it for some other purpose.

Please help.

I am quite puzzled.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Should I define 4K classes if I want to give 4K user each a fix bandwidth of 70kbps
  2014-09-15  6:58 Should I define 4K classes if I want to give 4K user each a fix bandwidth of 70kbps Akshat Kakkar
@ 2014-09-15  9:43 ` Andy Furniss
  0 siblings, 0 replies; 2+ messages in thread
From: Andy Furniss @ 2014-09-15  9:43 UTC (permalink / raw)
  To: lartc

Akshat Kakkar wrote:
> I am having around 4K users. I have to limit each user to 70kbps
> bandwidth. For this, I define 4K filters and 4K classes. Each filter
> is matched to each ip of an user, and each class is configured for a
> rate of 70kbps. Then I define 4K sfq qdisc mapped to each class. It
> works fine. No issues.
>
> But just that creating 4K exactly similar classes with just a
> difference in classid, is a kind of time consuming. The same holds
> for filters and sfq too.

I assume you are using hashing filters for run time speed.

As for loading time, in some test I did years ago using tc batch to load
many rules was way way faster than a script.

So if you are not already doing it try adjusting your script to produce
a file with just the rules ie. no "tc" at the start of every line and
load it with

tc -b <filename>


>
> Is there a simpler way of doing it?

Can't think of one - which doesn't mean there isn't - I don't really do
qos seriously.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-09-15  9:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-15  6:58 Should I define 4K classes if I want to give 4K user each a fix bandwidth of 70kbps Akshat Kakkar
2014-09-15  9:43 ` Andy Furniss

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.