云南省建设系统网站,什么网站做电脑系统好,跨境经验分享,做网站是怎么回事操作实现 此处应该6台虚拟机#xff0c;其中3台是哨兵#xff0c;但因为内存限制没有那么多
1.将sentinel文件拷贝到/myredis目录下 2.sentinel.conf文件重要参数 新建配置文件sentinel26379.conf sentinel26380.conf sentinel26381.conf
bind 0.0.0.0
daemonize yes
pr… 操作实现 此处应该6台虚拟机其中3台是哨兵但因为内存限制没有那么多
1.将sentinel文件拷贝到/myredis目录下 2.sentinel.conf文件重要参数 新建配置文件sentinel26379.conf sentinel26380.conf sentinel26381.conf
bind 0.0.0.0
daemonize yes
protected-mode no
port 26379
logfile /myredis/sentinel26379.log
pidfile /var/run/redis-sentinel26379.pid
dir /myredis
sentinel monitor mymaster 192.168.248.132 6379 2
sentinel auth-pass mymaster dc123启动三个哨兵
redis-sentinel sentinel26379.conf --sentinel
redis-sentinel sentinel26380.conf --sentinel
redis-sentinel sentinel26381.conf --sentinel//关闭
redis-cli -p 26379 shutdown主机宕机后会选出新的主节点
原来的主节点回来会变为从节点