搭建服务器集群,实现均衡负载。
环境:5个tomcat6(1-4在同一台电脑上,5在另一台电脑上)+nginx+memcached
防火墙端口11211已开启,telent正常

现象:1-4可以实现session共享,后台无报错,5后台出现连接失败,session无法共享
tomcat5后台
2017-01-16 10:03:41.658 WARN net.spy.memcached.MemcachedConnection: Closing, an
d reopening {QA sa=/172.16.73.89:11211, #Rops=0, #Wops=0, #iq=0, topRop=null, to
pWop=null, toWrite=0, interested=0}, attempt 2.
2017-01-16 10:03:41.698 INFO net.spy.memcached.MemcachedConnection: Connection
state changed for sun.nio.ch.SelectionKeyImpl@14d1d4
2017-01-16 10:03:41.698 INFO net.spy.memcached.MemcachedConnection: Reconnectin
g due to failure to connect to {QA sa=/172.16.73.89:11211, #Rops=0, #Wops=0, #iq
=0, topRop=null, topWop=null, toWrite=0, interested=0}
java.net.ConnectException: Connection timed out: no further information
at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:599
at net.spy.memcached.MemcachedConnection.handleIO(MemcachedConnection.ja
va:322)
at net.spy.memcached.MemcachedConnection.handleIO(MemcachedConnection.ja
va:219)
at net.spy.memcached.MemcachedClient.run(MemcachedClient.java:1591)
2017-01-16 10:03:41.698 WARN net.spy.memcached.MemcachedConnection: Closing, an
d reopening {QA sa=/172.16.73.89:11211, #Rops=0, #Wops=0, #iq=0, topRop=null, to
pWop=null, toWrite=0, interested=0}, attempt 2.
2017-01-16 10:03:41.838 INFO net.spy.memcached.MemcachedConnection: Connection
state changed for sun.nio.ch.SelectionKeyImpl@14df764
2017-01-16 10:03:41.838 INFO net.spy.memcached.MemcachedConnection: Reconnectin
g due to failure to connect to {QA sa=/172.16.73.89:11211, #Rops=0, #Wops=0, #iq
=0, topRop=null, topWop=null, toWrite=0, interested=0}