Welcome! Log In Create A New Profile

Advanced

RE: Anyway to limit amount of requests to no more then 20 requests per hour for each file?

Joseph Cabezas
June 05, 2012 06:20PM
Great....

So all I need is that single line in the httpd section, or server section?

limit_req_zone $uri zone=one:32m rate=1r/m;

Iam thinking I need some other line to actually apply the limit such as this?

location / { limit_req zone=one; proxy_pass http://backend1; }


Or something like this?


Joseph



> From: ne@vbart.ru
> To: nginx@nginx.org
> Subject: Re: Anyway to limit amount of requests to no more then 20 requests per hour for each file?
> Date: Wed, 6 Jun 2012 00:54:48 +0400
>
> On Wednesday 06 June 2012 00:30:26 Joseph Cabezas wrote:
> > Hello,
> >
> > Iam trying to avoid a seperate location {} for each file, instead just
> > limit the amount of reqeusts per second based on each object.
> >
>
> If you're happy with 60 requests per hour, then you can take advantage of
> the http_limit_req module.
>
> http://nginx.org/en/docs/http/ngx_http_limit_req_module.html
>
> limit_req_zone $uri zone=one:32m rate=1r/m;
>
> wbr, Valentin V. Bartenev
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Anyway to limit amount of requests to no more then 20 requests per hour for each file?

Joseph Cabezas June 05, 2012 04:32PM

Re: Anyway to limit amount of requests to no more then 20 requests per hour for each file?

Valentin V. Bartenev June 05, 2012 04:56PM

RE: Anyway to limit amount of requests to no more then 20 requests per hour for each file?

Joseph Cabezas June 05, 2012 06:20PM

Re: Anyway to limit amount of requests to no more then 20 requests per hour for each file?

Valentin V. Bartenev June 05, 2012 06:26PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 114
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready