I am running redis in cluster mode with one master and two replicas. I have a host where for some reason all redis instances were down and when I do ps -ef|grep redis , I would get nothing. Then I start redis manually using redis-server command as follows.
sudo redis-server /p1/p2/conf/redis-3021.conf
sudo redis-server /p1/p2/conf/redis-3022.conf
sudo redis-server /p1/p2/conf/redis-3023.conf
when I do ps -ef|grep redis
, I see the above three instances created.
When I check the cluster nodes command as below,
redis-cli -h localhost -p 3021 cluster nodes|grep myself
I get the below output.
599ca9dae5sdfb52dc8b5ca460fbb2e3c4 <localhostIp>:3021@13021 myself,slave 88fb2ewer1f0asfew520d20cb3c57e994be914 0 1664316404000 87 connected
I get similar output for 3022 and 3033
. All of them got added as replicas to existing cluster. I wanted to add 3021 as a new master node and 3022 and 3033 as replicas for some other master node. I tried deleting these nodes with redis-cli del-node command but did not work as it has some data. Is it the case that there was already some data on this instance when it was running before and when I bring up the instance, it loads it up from file system into memory? Appreciate your help. Thanks.