Could not connect to Redis at 127.0.0.1:6379: Connection refused

启动redis:  redis-server ../redis.conf

Could not connect to Redis at 127.0.0.1:6379: Connection refused_第1张图片

redis启动成功后

执行命令行redis-cli报:Could not connect to Redis at 127.0.0.1:6379: Connection refused错误


那是因为redis安装路径下的redis.conf文件配置未修改:

redis.conf文件中:

将daemonize no 修改为 daemonize yes

Could not connect to Redis at 127.0.0.1:6379: Connection refused_第2张图片

再输入 redis-server /usr/local/src/redis-4.0.10/redis.conf

redis-cli

就OK啦!


你可能感兴趣的:(redis)