码迷,mamicode.com
首页 > 其他好文 > 详细

redis error It was not possible to connect to the redis server(s); to create a disconnected multiplexer, disable AbortOnConnectFail. SocketFailure on PING

时间:2017-01-24 23:55:00      阅读:1740      评论:0      收藏:0      [点我收藏+]

标签:was   which   erro   net   rto   value   ping   字符串   get   

应用redis出现如下错误

 It was not possible to connect to the redis server(s); to create a disconnected multiplexer, disable AbortOnConnectFail. SocketFailure on PING

参考stack overflow上文章 http://stackoverflow.com/questions/30895507/it-was-not-possible-to-connect-to-the-redis-servers-to-create-a-disconnected

是因为在StackExchange.Redis会默认 abortconnect=true,即当redis连接报错(如服务器上停止redis service等)时StackExchange会自动停止,即便后来redis服务端修好能够接通时,也不会自动连接。

所以需要在连接字符串里将值设置为false。若在webconfig中写成    <RedisCaching Enabled="false" ConnectionString="88.110.22.88,abortConnect=false" />

The error you are getting is usually a sign that you have not set abortConnect=false in your connection string. The default value for abortConnect is true, which makes it so thatStackExchange.Redis won‘t reconnect to the server automatically under some conditions. We strongly recommend that you set abortConnect=false in your connection string so that SE.Redis will auto-reconnect in the background if a network blip occurs.

redis error It was not possible to connect to the redis server(s); to create a disconnected multiplexer, disable AbortOnConnectFail. SocketFailure on PING

标签:was   which   erro   net   rto   value   ping   字符串   get   

原文地址:http://www.cnblogs.com/taoshengyujiu/p/6348007.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!