Hello,
Ihave rebuild nginx 1.9.1 from source to use SO_REUSEPORT on my wheezy
install with kernel 3.16 (from backports).
(packages from http://nginx.org/packages/mainline/debian/has not include
SO_REUSEPORT)
Some errors are still present:
[emerg] 19351#19351: duplicate listen options for 0.0.0.0:80 in …
Is there a way to use “reuseports” for multiple locations?
How can I test if it works for a special location?
Is there a header send or something else? Or is the only way to compare
“stress test” like siege?
Regards,
Basti
Try the latest 1.9.2, in 191 is was added but not working.
Posted at Nginx Forum:
Some errors are still present:
[emerg] 19351#19351: duplicate listen options for 0.0.0.0:80 in …
Is there a way to use “reuseports” for multiple locations?
You have to declare it once and only once.
Please read:
http://nginx.org/en/docs/http/ngx_http_core_module.html#listen
Lukas
On 6/10/15 1:06 PM, itpp2012 wrote:
Try the latest 1.9.2, in 191 is was added but not working.
http part is fully functional in 1.9.1. The author has different
issue and Lukas T. already answered.
–
Maxim K.
Thanks for your answer Maxim
Hello!
On Wed, Jun 10, 2015 at 06:06:22AM -0400, itpp2012 wrote:
Try the latest 1.9.2, in 191 is was added but not working.
This is not true.
–
Maxim D.
http://nginx.org/
Hello!
On Wed, Jun 10, 2015 at 11:46:49AM +0200, basti wrote:
Is there a way to use “reuseports” for multiple locations?
How can I test if it works for a special location?
Is there a header send or something else? Or is the only way to compare
“stress test” like siege?
Much like all other listening socket options, “reuseport” have to
be specified only once, usually in a default server for a listen
socket in question. That is, if you have many servers listening
on port 80, you should write something like:
server {
listen 80 reuseport;
server_name default.example.com;
...
}
server {
listen 80; # no options here
server_name virtual.example.com;
...
}
To check if reuseport actually works just check how many listening
sockets were created - normally there will be just one,
but with reuseport you’ll see multiple listening sockets, one for
each of nginx worker processes. Something like “ss -nlt” should
show listening sockets on Linux.
–
Maxim D.
http://nginx.org/
Maxim D. Wrote:
Hello!
On Wed, Jun 10, 2015 at 06:06:22AM -0400, itpp2012 wrote:
Try the latest 1.9.2, in 191 is was added but not working.
This is not true.
I stand corrected, mistakenly took
http://hg.nginx.org/nginx/rev/f654addf0eea for a http issue.
Posted at Nginx Forum:
Where can I find? The latest tag I have found is 1.9.1.
(nginx – nginx)