1

I am new to Scylla, and I'm looking to setup a proper Backup & Restore solution.

I've just tested running nodetool snapshot -t my_backup, and see that what it does is create a snapshot folder caled my_backup, inside each keyspace & table folder.

This causes a few limitations in my view:

  1. I can't easily save the backups on another server, in case this specific server dies

  2. I can't easily restore a backup on another server (e.g. as a daily snapshot for production support purposes/tests)

How do DBAs normally store backups in another server and restore a whole database into another server ?

--

Another issue I noticed is that nodetool listsnapshots doesn't seem to mention the snapshot creation date in the output.

So I don't seem to be able to find a way to purge old snapshots.

How do I "delete snapshots older than 10 days" or "keep last 3 backups", for example?

Nuno
  • 829
  • 1
  • 12
  • 24

1 Answers1

2

Assuming that you're moving your snapshots to another server or cloud storage (ex: S3 bucket) then removing old snapshots after a certain number of days is a simple matter of running a Linux find for each snapshot dir by date, and then an rm -rf on each that you want to get rid of.

This question was asked on Stack Overflow a while ago, and the answers are still relevant: https://stackoverflow.com/questions/31144980/deleting-specific-cassandra-snapshots/31147289#31147289

My answer above contained a script that pretty much did what I described above.

It's also worth checking out Medusa, which is a Cassandra backup utility. I'm fairly certain that it has ways of managing old snapshots.

Aaron
  • 4,420
  • 3
  • 23
  • 36