So your approach should work... here are some things to observe
- Make sure you shut down your C* on the node to replace.
- Make it impossible to start C* on the old node by accident (move the jar files away for example, or at least temporarily move the /etc/init.d/dse script somewhere else)
- Copy everything to the new machine
- Shutdown the old machine (disconnect network if possible).
- Make sure that the new machine has the same ip address as the old one, and that for the first boot it's not gonna start C* (not a real requirement, but more a precaution in case the ip address doesn't match, or there is something else wrong with that box).
- double check everything is fine, reenable C* and restart the machine. Depending on how you copied that machine I would be more concerned with OS system files in terms of stability. If you just copied the C* app and data files you should be fine.
- make sure you NEVER start the old machine with an active C*.
I haven't tried this, but there isn't anything I know off that would prevent this from working (now that I said this, I am probably gonna get dinged... but I DID ask one of our key engineers :-).
The more "standard" procedure is this, which I will propose for our docs:
Replacing a running node
Replace a node with a new node, for example to update to newer hardware/proactiv e maintenance.
You must prepare and start the replacement node, integrate it into the cluster, and then remove the old node.
Procedure
Confirm that the node is alive:
a) Run nodetool ring if not using vnodes.
b) Run nodetool status if using vnodes.
The nodetool command shows a up status for the node (UN)
- Note Host ID of the node to replace; it is used in the last step.
- Add and start the replacement node as described in http://www.datastax.com/docs/1.1/cluster_management#adding-capacity-to-an-existing-cluster
- Using the Host ID of the original old node, remove the old node from the cluster using the nodetool removenode command. See http://www.datastax.com/documentation/cassandra/2.0/cassandra/operations/ops_remove_node_t.html for detaile dinstructions.