2
votes

The official documentation of Cassandra says, that:

Configure the keyspace and create the new datacenter:

Use ALTER KEYSPACE to use the NetworkTopologyStrategy for the following keyspaces:

  • All user-created
  • system: system_distributed and system_traces
  • system_auth and dse_security, see Configuring system_auth and dse_security keyspace replication.

This step is required for multiple datacenter clusters because nodetool rebuild (10) requires a replica of these keyspaces in the specified source datacenter.

I understand that system keyspace holds information specific to a node, so that cannot be shared with other nodes.

What about the system_schema keyspace?

Based on the documentation it holds information about user-defined

  • types,
  • aggregates,
  • functions

and also on

  • triggers,
  • keypace durable writes and replication
  • dropped columns, etc..

My guess would be that all of these should be also replicated among the datacenters, but I am a bit suspicious why is it not mentioned at all in the documentation?

1

1 Answers

5
votes

The system_schema keyspace (and system as well) has LocalStrategy as replication strategy - in this case, all changes applied only on current node. The discrepancy between schemas are detected via gossip, and triggering the process of data update.

You shouldn't change replication for these keyspaces.

Update in 2020th. You can use https://github.com/DataStax-Toolkit/cassandra-dse-helper-scripts/tree/master/adjust-keyspaces for automatically adjustment of all necessary keyspaces