How to restart redis cluster after its all shutdown

2,254 views
Skip to first unread message

optimi...@163.com

unread,
Jun 16, 2017, 3:51:54 AM6/16/17
to Redis DB
Dear redis supporter,

I build a redis cluster for example, they are as below:

When I use "./redis-trib.rb create --replicas 1 127.0.0.1:7000 127.0.0.1:7001 127.0.0.1:7002 127.0.0.1:7003 127.0.0.1:7004 127.0.0.1:7005" command to start them at first time,
they are working but when I close them all and restart again, it shows the following errors.

[ERR] Node 127.0.0.1:7000 is not empty. Either the node already knows other nodes (check with CLUSTER NODES) or contains some key in database 0. 

Of course, one solution is to delete three files(appendonly.aof dump.rdb nodes.conf) but all previous data will be lost. I don't think it is viable in the production line.
Would you please give me a good idea or  better solution? Thank you
Best regards,
Mike.Xu

Jan-Erik Rediger

unread,
Jun 16, 2017, 4:09:27 AM6/16/17
to redi...@googlegroups.com
The nodes.conf file on every node contains all the state required to
bring up the Cluster again.
You should be able to just restart every node and they will connect back
to each known node.
> --
> You received this message because you are subscribed to the Google Groups "Redis DB" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.
> To post to this group, send email to redi...@googlegroups.com.
> Visit this group at https://groups.google.com/group/redis-db.
> For more options, visit https://groups.google.com/d/optout.

徐亮

unread,
Jun 16, 2017, 4:14:27 AM6/16/17
to redis-db
Dear supporter,

As my understanding, I just run redis-server redis.conf to restart the crash node. Right?
Thank you!

Sent from Mail Master
You received this message because you are subscribed to a topic in the Google Groups "Redis DB" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/redis-db/-nmSfmhXG6g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to redis-db+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages