Never mind, Nginx was actually limiting requests correctly.
What I was seeing in my logs was requests for non-existent .js and .css
files, which were then being passed to index.php as per my try_files in the
/ location block.
Posted at Nginx Forum:
https://forum.nginx.org/read.php?2,265244,26524
I have a location ~* \.php$ with limit_req set inside it. But requests
outside of this location block, e.g. for .js and .css files are also being
limited. I only want to limit the number of requests to .php files.
This is my config:
worker_processes 2;
pid logs/nginx.pid;
events {
work
imit_re
> q>.
> They are supplementing each other.
> ---
> *B. R.*
>
> On Fri, Jan 8, 2016 at 8:52 PM, djeyewater
>
> wrote:
>
> > itpp2012 Wrote:
> > ---
> > > No because one user (web browser
itpp2012 Wrote:
---
> No because one user (web browser) can easily open 20 or more
> simultaneous connections to get a better web response.
> A bot might be less prone to do the same but most connect at about 5
> simultaneous connections.
The li
I want to limit requests to 1 per second for each user, counting a bot that
makes requests from multiple ips as a single user. Does this make sense:
map $http_user_agent $single_user {
default $binary_remote_addr;
~PaperLiBot 1;
}
limit_req_zone $single_user zone=one:10m r
Thanks Maxim, the perl_modules work around works well.
Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,254255,254324#msg-254324
___
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
When I try to start nginx with embedded perl I get the error "Can't locate
nginx.pm in @INC"
@INC includes the folder I specified using --with-perl_modules_path, but
doesn't include the arch-name subfolder (i386-linux-thread-multi), which is
where the nginx.pm module was installed to.
This is my