nginx_tcp_proxy_module
nginx_tcp_proxy_module copied to clipboard
Is it possible to use both nginx_tcp_proxy_module & nginx_upstream_check_module?
Hi,
I'm trying to use both nginx_tcp_proxy_module & nginx_upstream_check_module, but I'm not able to see the tcp checks (I only see the http ones).
Here is how I compiled/installed nginx (1.2.6):
patch -p1 < ../nginx_upstream_check_module/check_1.2.6+.patch
patch -p1 < ../nginx_tcp_proxy_module/tcp.patch
./configure --add-module=../nginx_upstream_check_module --add-module=../nginx_tcp_proxy_module
And here are excerpts of my Nginx configuration files, first the tcp block:
tcp {
upstream websockets {
server 127.0.0.1:3338;
server 127.0.0.1:3339;
check interval=3000 rise=2 fall=5 timeout=1000;
}
server {
server_name _;
listen 8080;
websocket_pass websockets;
}
}
And then this (which is included in the http block):
upstream localhost {
server 127.0.0.1:3333;
server 127.0.0.1:3334;
check type=http interval=3000 rise=2 fall=5 timeout=1000;
}
server {
listen 0.0.0.0:80;
server_name localhost;
location /status {
check_status;
}
location / {
proxy_pass http://localhost;
}
}
Is that possible that the problem comes from both modules defining the check_status "value"?