Ruby Forum NGINX > bandwidth throttling (on a per ip/user basis)

Posted by Armin Roehrl (Guest)
on 18.08.2008 13:22
(Received via mailing list)
Dear all,

  does anybody have any experience throttling
the bandwith on a per ip/user basis with nginx?

Any pointers, ideas, etc. how to implement this
would be highly appreciated.

All the best,
  -Armin
Posted by Maxim Dounin (Guest)
on 18.08.2008 14:36
(Received via mailing list)
Hello!

On Mon, Aug 18, 2008 at 01:12:23PM +0200, Armin Roehrl wrote:

>  does anybody have any experience throttling
> the bandwith on a per ip/user basis with nginx?
>
> Any pointers, ideas, etc. how to implement this
> would be highly appreciated.

The only way to do it with nginx is to use request bandwidth
limits with connection number limits.  See:

http://wiki.codemongers.com/NginxHttpCoreModule#limit_rate
http://wiki.codemongers.com/NginxHttpLimitZoneModule

This can't effectively limit bandwidth for many small requests and
doesn't allow flexible aggregate limits though.  So it's probably
better to use your firewall for bandwidth limiting instead.

Maxim Dounin