The Bootstrap and Anti Entropy Repair processes are generally the best ways to move data to new nodes. In some cases, it is more efficient to move data around with a file copy tool such as rsync
. This method is efficient when doing a one-to-one move from old hardware to new hardware.
For this example, assume the node cassandra05
is being replaced by cassandra05-new
and the Cassandra data directory is /var/lib/cassandra
. This recipe requires an SSH Server and SSH Client, but any method of transferring binary data such as FTP is sufficient.
Create an executable script
/root/sync.sh
that uses thersync
command:nohup rsync -av --delete --progress /v ar/lib/cassandra/data \ root@cassandra05-new:/var/lib/cassandra/ 2> /tmp/sync.err \ 1> /tmp/sync.out & $ chmod a+x /root/sync.sh $ sh /root/sync.sh
On the source server,
cassandra05
, stop the Cassandra process and run the sync again. It will take much less time than...