While I know how to configure and run Redis master and slave on two different servers, I would like to whether my Webserver will be able to connect to slave redis server if the master redis server goes down?
If that is not the case, May I know how can I achieve that?
Thanks
Balaji
Best Answer
At the server side, for a simple failover, you can do it by using Nagios and NRPE.
On the Nagios server:
promote_redis.sh
On the slave:
nrpe.cfg
promote_redis.sh
Virtual IP can be set up by using
keepalived
, something like this:/etc/keepalived/keepalived.conf
But what happens if you want to run multiple instances?
Yves Trudeau and Percona wrote a great resource agent to failover MySQL. Based on that, Martin Walter rewrite for the Redis service. Give it a try!
crm configure show
crm status