0
votes

I have a Redis cluster configuration with a master and 2 slaves. I want to enable AOF (fsync:always) on the master for full durability, while RDB in both the slaves. My question is, in case the master fails, and one of the slaves is chosen as the new master; will the old master config be also copied to the new master. And, when the old master restarts as the new slave, will the slave config be copied to the new slave by the redis sentinel automatically?

1

1 Answers

1
votes

What you have isn't a Redus cluster, as cluster is a different setup. Pointedly Redis Cluster and Sentinel do not go together.

That said, no, Sentinel does not "copy configuration" it simply elects a new master. A Sentinel constellation elects a new master and issues a slave of Command on it to make it the master, then points any other slaves to the newly minted master. You will either need to write something which picks up the change and reconfigures the new master or keep those configuration items the same.