cassandrashutdownrecoverypower-off

cassandra cluster not re-starting upon improper shutdown


I have a test cluster on 3 machines where 2 are seeds all centos7 and all cassandra 3.4. Yesterday all was fine they were chating and i had the "brilliant" idea to ....power all those machines off to simulate a power failure. As a newbie that i am, i simply powered the machines back and i expected probably some kind of supermagic, but here it is my cluster is not up again, each individual refuses to connect. And yes, my firewalld is disabled.

My question : what damage was made and how can i recover the cluster to the previous running state?


Solution

  • Since you abruptly shutdown your cluster, that simply means, nodes were not able to drain themselves.

    Don't worry, it is unlikely any data loss happened because of this, as cassandra maintains commit logs, and will read from it when it is restarted.

    First, find your seed node ip from cassandra.yaml Start your seed node first.

    Check the start up logs in cassandra.log and system.log and wait for it to start up completely, it will take sometime. As it will read from commit log for pending actions, and will replay them.

    Once it finishes starting up, start other nodes, and tail their log files.