{"record":{"id":"c2e6140ca173a154","repo":"apache/cassandra","slug":"gossip-not-settled-but-startup-forced-by-cassandra","errorCode":null,"errorMessage":"Gossip not settled but startup forced by cassandra.skip_wait_for_gossip_to_settle. Gossip total polls: {}","messagePattern":"Gossip not settled but startup forced by cassandra\\.skip_wait_for_gossip_to_settle\\. Gossip total polls: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"src/java/org/apache/cassandra/gms/Gossiper.java","lineNumber":2090,"sourceCode":"        while (numOkay < GOSSIP_SETTLE_POLL_SUCCESSES_REQUIRED)\n        {\n            Uninterruptibles.sleepUninterruptibly(GOSSIP_SETTLE_POLL_INTERVAL_MS, TimeUnit.MILLISECONDS);\n            int currentSize = Gossiper.instance.getEndpointCount();\n            totalPolls++;\n            if (currentSize == epSize)\n            {\n                logger.debug(\"Gossip looks settled. {}\", Gossiper.instance.endpointStateMap);\n                numOkay++;\n            }\n            else\n            {\n                logger.info(\"Gossip not settled after {} polls.\", totalPolls);\n                numOkay = 0;\n            }\n            epSize = currentSize;\n            if (forceAfter > 0 && totalPolls > forceAfter)\n            {\n                logger.warn(\"Gossip not settled but startup forced by cassandra.skip_wait_for_gossip_to_settle. Gossip total polls: {}\",\n                            totalPolls);\n                break;\n            }\n        }\n        if (totalPolls > GOSSIP_SETTLE_POLL_SUCCESSES_REQUIRED)\n            logger.info(\"Gossip settled after {} extra polls; proceeding\", totalPolls - GOSSIP_SETTLE_POLL_SUCCESSES_REQUIRED);\n        else\n            logger.info(\"No gossip backlog; proceeding\");\n    }\n\n    /**\n     * Blockingly wait for all live nodes to agree on the current schema version.\n     *\n     * @param maxWait maximum time to wait for schema agreement\n     * @param unit TimeUnit of maxWait\n     * @return true if agreement was reached, false if not\n     */\n    // TODO: (TM/alexp): we do not need to wait for schema convergence for the purpose of view building;","sourceCodeStart":2072,"sourceCodeEnd":2108,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/gms/Gossiper.java#L2072-L2108","documentation":"Before declaring itself ready, Gossiper polls the cluster until gossip 'settles' (endpoint count stable across required successful polls). If cassandra.skip_wait_for_gossip_to_settle forces startup after a threshold of polls while gossip is still unsettled, it warns that startup proceeded against the operator's explicit override.","triggerScenarios":"Waiting for gossip settlement with forceAfter configured; totalPolls exceeds forceAfter while the endpoint set is still changing, so the loop breaks and startup continues.","commonSituations":"Setting -Dcassandra.skip_wait_for_gossip_to_settle=0/30 to speed up restarts of large clusters; doing rolling restarts with heavy membership churn; emergency restarts during incident recovery.","solutions":["Remove cassandra.skip_wait_for_gossip_to_settle for normal startups; let gossip settle naturally.","If used intentionally during recovery, verify ring stability after startup with nodetool status before serving traffic.","Reduce cluster churn (avoid restarting many nodes simultaneously) so gossip settles quickly.","Set a larger forceAfter value (e.g., 30) rather than 0 to give gossip a bounded chance to settle."],"exampleFix":"// before\nJVM_OPTS=\"$JVM_OPTS -Dcassandra.skip_wait_for_gossip_to_settle=0\"\n// after\n# remove the property entirely, or allow bounded forcing:\nJVM_OPTS=\"$JVM_OPTS -Dcassandra.skip_wait_for_gossip_to_settle=30\"","handlingStrategy":"fallback","validationCode":"// start without the skip flag unless recovering\nif (System.getProperty(\"cassandra.skip_wait_for_gossip_to_settle\") != null && !recoveryMode) logger.warn(\"skip_wait_for_gossip_to_settle set outside recovery\");","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Use skip_wait_for_gossip_to_settle only for controlled recovery, then remove it.","After forced startup, always verify nodetool status before client traffic.","Avoid mass concurrent restarts so gossip settles quickly by default."],"tags":["cassandra","gossip","startup","jvm-flag"],"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"}