0

I configured Redis and Redis-Sentinel in order to enable automatic failover.
Redis has one master and 2 slaves.
There are 3 sentinel nodes.

I configured redis with authentication, so in redis.conf file of the master I added this:

requirepass mypassword  

and in the redis.conf of the slaves, this:

masterauth mypassword   

When I stop the master, one of the slaves becomes the master, as expected.
However, when I connect to the new master using redis-cli I notice that no password is required.
I expect this is because the redis.conf file of the new master remains with the value of 'masterauth mypassword', instead of 'requirepass mypassword'.

Is this the expected behavior? Shouldn't Redis-Sentinel configure this? or should I set something else in the conf files for the new master to require authentication?

Tamar
  • 145
  • 4
  • 15

1 Answers1

2

You should also configure slave node with password, i.e. requirepass mypassword.

Slave node sync data from master node, but it does not sync password. So you need to configure it manually.

for_stack
  • 21,012
  • 4
  • 35
  • 48