user2527312
user2527312

Reputation: 89

cassandra snapshots provides latest data or not

I have 4 nodes in my cluster. When i take snapshots whether it checks for the latest data from the cluster or it will take from that node data alone. My question is, snapshots provides the latest data or not?

If it provides latest data no need to take snapshot on each and every node in the cluster right?

Upvotes: 2

Views: 270

Answers (1)

Lyuben Todorov
Lyuben Todorov

Reputation: 14153

Snapshots flush all the memtables to disc (i.e. makes sstables) so that all the latest node data is present in your snapshot. The command works at the node level, meaning you back up the very latest data for each node, not every node at once.

The advice given on the DataStax docs is if you want to back up all the data at the same time, you should use a command-line utility that can execute requests in parallel (pssh is the suggested util).

If it provides latest data no need to take snapshot on each and every node in the cluster right?

I cant really see a case where you need to backup your data daily when you're using Cassandra unless you are running a single node environment (which for C* seems slightly pointless). If you have a high enough replication factor, your data will always be backed up, and unless you are expecting a catastrophic hardware failures where all your servers (aka your entire cluster) will simultaneously burst into fire, you do not need to backup daily.

Upvotes: 2

Related Questions