一般来说,出现
net.rubyeye.xmemcached.exception.MemcachedException: There is no available connection at this moment
的原因,要么就是接入的memcached服务不存在,另外可能还有一个原因:启动memcached服务的方式有问题.
在出现这个问题前,我启动服务的方法如下:
./memcached -d -m 128 -u root -l localhost -p 12000 -c 1024 -P /tmp/memcached.pid
一直都是报no available connection的错误,后来把localhost换成memcached服务的 IP地址就可以了,虽然不太懂,这里记录一下。
./memcached -d -m 128 -u root -l 192.168.0.126 -p 12000 -c 1024 -P /tmp/memcached.pid
本文介绍了MemcachedException中There is no available connection at this moment错误的解决方法。通过更改memcached服务启动命令中的地址从localhost到实际IP,成功解决了连接不可用的问题。
1102

被折叠的 条评论
为什么被折叠?



