redis日志 - redis配置 - redis报错:READONLY You can‘t write against a read only replica - 只读报错 - 主从同步报错
高版本redis 找到replica-read-only设置为no。低版本redis 找到slave-read-only设置为no。修改redis配置文件redis.conf。Redis 配置_redis教程。
·
错误
READONLY You can‘t write against a read only replica.
解决
修改redis配置文件redis.conf
// 高版本redis 找到replica-read-only设置为no
replica-read-only no
// 低版本redis 找到slave-read-only设置为no
slave-read-only no
重启redis服务
使用redis密码登录到redis-cli
redis-cli -a 123321
检查当前配置
127.0.0.1:6379> config get slave-read-only
1) "slave-read-only"
2) "no"
127.0.0.1:6379> config get replica-read-only
1) "replica-read-only"
2) "no"
127.0.0.1:6379>
P.s. redis日志
locate redis.log
P.s. redis配置文件
locate redis.conf
P.s. redis配置详细说明
Redis 配置_redis教程https://www.redis.net.cn/tutorial/3504.html
ending...
更多推荐
所有评论(0)