Limit downlaod speed per ip

Hello,

   Is there a way to limit speed per ip ? Doesn't matter how many

connections the single ip is consuming but he shouldn’t be able to get
more
than assigned download limit.

limit_rate directive is for per connection but not for per ip.

Looking forward to your help. Thanks

On 01/24/2013 06:52 PM, shahzaib shahzaib wrote:

Hello,

    Is there a way to limit speed per ip ? Doesn't matter how many

connections the single ip is consuming but he shouldn’t be able to get more
than assigned download limit.

limit_rate directive is for per connection but not for per ip.

Looking forward to your help. Thanks

You need to do it on system level, like tc on linux or ipfw on freebsd
and so on.

– Piotr.

Can you explain a bit ? We are using Centos 6.3.

On 01/24/2013 07:02 PM, shahzaib shahzaib wrote:

Can you explain a bit ? We are using Centos 6.3.

$ man tc

Regards,
Patrick

Thanks guyz, i’ll look into your module, if it works for me and will let
you know about that :slight_smile:

I used to write a simple module for such purpose, It should work. Have a
try: GitHub - yaoweibin/nginx_limit_speed_module: limit the total speed from the specific user

2013/1/25 Patrick L. [email protected]