{"record":{"id":"1a5a7b97322ec963","repo":"apache/cassandra","slug":"this-node-was-decommissioned-and-will-not-rejoin-t","errorCode":null,"errorMessage":"This node was decommissioned and will not rejoin the ring unless cassandra.override_decommission=true has been set, or all existing data is removed and the node is bootstrapped again","messagePattern":"This node was decommissioned and will not rejoin the ring unless cassandra\\.override_decommission=true has been set, or all existing data is removed and the node is bootstrapped again","errorType":"exception","errorClass":"ConfigurationException","httpStatus":null,"severity":"critical","filePath":"src/java/org/apache/cassandra/service/StorageService.java","lineNumber":803,"sourceCode":"            if (!(notification instanceof SSTablesVersionsInUseChangeNotification))\n                return;\n\n            Set<Version> versions = ((SSTablesVersionsInUseChangeNotification) notification).versionsInUse;\n            logger.debug(\"Updating local sstables version in Gossip to {}\", versions);\n\n            Gossiper.instance.addLocalApplicationState(ApplicationState.SSTABLE_VERSIONS,\n                                                       valueFactory.sstableVersions(versions));\n        });\n\n        if (SystemKeyspace.wasDecommissioned())\n        {\n            if (CassandraRelevantProperties.OVERRIDE_DECOMMISSION.getBoolean())\n            {\n                logger.warn(\"This node was decommissioned, but overriding by operator request.\");\n            }\n            else\n            {\n                throw new ConfigurationException(\"This node was decommissioned and will not rejoin the ring unless cassandra.override_decommission=true has been set, or all existing data is removed and the node is bootstrapped again\");\n            }\n        }\n\n        if (DatabaseDescriptor.getReplaceTokens().size() > 0 || DatabaseDescriptor.getReplaceNode() != null)\n            throw new RuntimeException(\"Replace method removed; use cassandra.replace_address instead\");\n\n        if (isReplacing())\n        {\n            if (SystemKeyspace.bootstrapComplete())\n                throw new RuntimeException(\"Cannot replace with a node that is already bootstrapped\");\n\n            InetAddressAndPort replaceAddress = DatabaseDescriptor.getReplaceAddress();\n            Directory directory = ClusterMetadata.current().directory;\n            if (directory.peerId(replaceAddress) == null || directory.peerState(replaceAddress) != JOINED)\n                throw new RuntimeException(String.format(\"Cannot replace node %s which is not currently joined\", replaceAddress));\n\n            BootstrapAndReplace.checkUnsafeReplace(shouldBootstrap());\n        }","sourceCodeStart":785,"sourceCodeEnd":821,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/service/StorageService.java#L785-L821","documentation":"During initServer, Cassandra checks system.local for a recorded decommission. A decommissioned node is not allowed to rejoin the ring because its data is stale; the only sanctioned paths are setting cassandra.override_decommission=true or wiping the data directory and re-bootstrapping. If the override flag is not set, a ConfigurationException is thrown.","triggerScenarios":"Starting (initServer) a node whose system keyspace still contains the DECOMMISSIONED status, without -Dcassandra.override_decommission=true.","commonSituations":"Restoring a decommissioned node from an old snapshot; reverting a decommission operation; cloning a disk image from a node that was later decommissioned; misfired decommission that left status behind.","solutions":["If re-joining is intentional, start with -Dcassandra.override_decommission=true (cassandra.override_decommission=true)","Wipe the data directories and let the node bootstrap fresh","Restore the correct system keyspace state from a pre-decommission backup","Check `nodetool info`/system.local peer status before restarting a node that was decommissioned"],"exampleFix":"// before\nbin/cassandra\n// after\nbin/cassandra -Dcassandra.override_decommission=true  # or rm -rf data/* to rebootstrap","handlingStrategy":"validation","validationCode":"String status = SELECT status FROM system.local; if (\"DECOMMISSIONED\".equals(status)) { /* override or wipe */ }","typeGuard":null,"tryCatchPattern":"try { startNode(); } catch (ConfigurationException e) { if (e.getMessage().contains(\"decommissioned\")) { /* wipe data or restart with override */ } }","preventionTips":["Never restart a node that was decommissioned without a plan","Keep decommission operations and snapshots clearly separated","Document the override flag usage for on-call operators"],"tags":["bootstrap","decommission","configuration","startup"],"backgroundTag":"invalid-config-value","analyzedSha":"88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1","analyzedAt":"2026-09-10T07:29:22.284Z","contentChangedAt":"2026-09-10T07:29:22.284Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}