Apache Cassandra is a free and open-source distributed NoSQL database management system designed to handle large amounts of data across many commodity servers, providing high availability with no single point of failure.
There is some documentation out their about how to migrate from one cluster to anoter :
Here is some script to help you do that quite easily, method doesn't care if you're restoring on the cluster or to another cluster, with same or different topology :
- Export of keyspace schema structure with
DESC keyspace
- Create a snapshot
- Create a tar file with all the data
- Remove the snapshot
The export script export.sh
is doing all that, just run it like that on one of the Cassandra cluster node :
$ ./export.sh <keyspace name>
You can have a list of your keyspace with desccribe keyspaces
Transfer the tar file to one of the node of the new cluster.
Now you need to import data to do so, you have to :
- Drop the old keyspace
- Create the keyspace schema
- Import date into table with sstableloader
That what the import.sh
script is doing from the previous generated tar file.
$ ./import.sh <keypsace backup tar file>