2

I have a Cassandra cluster composed of 2 nodes. One node could not start Cassandra yesterday. I deleted the system keyspace directory and I started the node again. The node is running after system keyspace directory deletion.

What are consequences of system keyspace missing?

All data are present in my cluster and I find no errors at the moment.

1

The system keyspace is where a Cassandra node maintains information about itself and other nodes. So things like network addresses, responsible token ranges, status from gossip, hints, schema, and other local information. The system keyspace has its own, special replication strategy known as "LocalStrategy:"

cqlsh:system> desc KEYSPACE;

CREATE KEYSPACE system WITH replication = {
  'class': 'LocalStrategy'
};

This should tell you that data in the system keyspace isn't replicated to other nodes, and is largely specific to itself.

Sometimes you can fix gossip-related issues by blowing-away the system keyspace (or even just all entries in system.peers). Removing it via the filesystem (as you did) has the same effect. The reason this works, is because it forces the node to rewrite all of that data, most of which it already has (system.local) or it can learn from gossip.

While I wouldn't make a habit out of it, deleting the system keyspace via the filesystem is ok...as long as you have another node in the cluster for it to communicate with.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.