Welcome! Log In Create A New Profile

Advanced

Limit_conn not working

Posted by azraelno1 
Limit_conn not working
October 13, 2014 12:57AM
After

Here is nginx info:
nginx version: nginx/1.4.4
built by gcc 4.4.7 20120313 (Red Hat 4.4.7-4) (GCC)
TLS SNI support enabled
configure arguments: --user=nobody --group=nobody --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --add-module=/root/software/ngx_devel_kit/ --add-module=/root/software/lua-nginx-module/ --add-module=/root/software/redis2-nginx-module/ --add-module=/root/software/set-misc-nginx-module/ --add-module=/root/software/echo-nginx-module/ --add-module=/root/software/memc-nginx-module/

Here is uname -a info:
Linux AY1401061723573984e3Z 2.6.32-358.6.2.el6.x86_64 #1 SMP Thu May 16 20:59:36 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

Here is nginx conf

http {
limit_req_zone $binary_remote_addr zone=req_one:10m rate=2r/s;
limit_conn_zone $binary_remote_addr zone=addr:10m;

location /v1/ {
limit_conn addr 1;
limit_req zone=req_one burst=5;
if (!-d $request_filename) {
#common
rewrite ^/v1/(\w+)/(\w+)(.html)?$ /api/v1/$1.php?a=$2 last;
}
}
}

why the limit is not working?
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 213
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready