Quantcast
Channel: Nginx Forum - Nginx Mailing List - English
Viewing all articles
Browse latest Browse all 7229

nginx proxy websocket to multi nodes (no replies)

$
0
0
I use nginx as proxy server, backend are socketio services. Follow the [document](http://socket.io/docs/using-multiple-nodes/) , nginx configuration, ip_hash instruction that indicates the connections will be sticky.

upstream socketio {
ip_hash;
server server1:3000;
server server1:3001;
server server2:3100;
server server2:3101;
}

But for this configuration, same client request always proxy to same backend server.


If want same server request proxy to different backend server, have tried [hash directive](http://nginx.org/en/docs/http/ngx_http_upstream_module.html#hash) but doesn't work

upstream socketio {
hash "${remote_addr}${remote_port}";



Any solution?

Viewing all articles
Browse latest Browse all 7229

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>