ps-ef | grep redis 查看是否端口被占用 然后kill -15 pid 或者 kill -9 pid
redis-server[230033]: 230033:C 19 Mar 2022 11:14:19.860 # Fatal error, can't open config file '/usr/
redis-cli -h 127.0.0.1 -p 6379 -a "密码" linux上面 启动客户端 报错:
原因是:没有启动 服务端
redis相关命令:
redis-cli -h 127.0.0.1 -p 6379 -a "密码" 启动客户端(/usr/local/bin 客户端启动路径) 启动的前提是启动 服务端
redis的根目录启动
(/usr/local/redis/redis-6.2.6
) : 根目录下执行的 指令 : ./src/redis-server redis.conf
Warning: Using a password with '-a' or '-u' option on the command line interface may not be safe.
Could not connect to Redis at 127.0.0.1:6379: Connection refused