{"record":{"id":"9707b824e77e58a5","repo":"influxdata/influxdb","slug":"tried-to-stop-a-node-node-id-that-is-already-stopped","errorCode":null,"errorMessage":"tried to stop a node ({node_id}) that is already stopped","messagePattern":"tried to stop a node \\((.+?)\\) that is already stopped","errorType":"error_code","errorClass":"CatalogError","httpStatus":null,"severity":"warning","filePath":"influxdb3_catalog/src/error.rs","lineNumber":297,"sourceCode":"    #[error(\"cannot parse token permission, {0}\")]\n    CannotParsePermissionForToken(String),\n\n    #[error(\"token name already exists, {0}\")]\n    TokenNameAlreadyExists(String),\n\n    #[error(\"token hash already exists\")]\n    TokenHashAlreadyExists,\n\n    #[error(\"missing admin token, cannot update\")]\n    MissingAdminTokenToUpdate,\n\n    #[error(\"cannot delete internal db\")]\n    CannotDeleteInternalDatabase,\n\n    #[error(\"cannot modify internal db\")]\n    CannotModifyInternalDatabase,\n\n    #[error(\"tried to stop a node ({node_id}) that is already stopped\")]\n    NodeAlreadyStopped { node_id: Arc<str> },\n\n    #[error(\n        \"node '{node_id}' is not fully stopped (current state: {current_state}); run \\\"stop node\\\" first\"\n    )]\n    NodeNotFullyStopped {\n        node_id: Arc<str>,\n        current_state: &'static str,\n    },\n\n    #[error(\"node '{node_id}' has compact mode and cannot be removed\")]\n    NodeModeNotRemovable { node_id: Arc<str> },\n\n    #[error(\"invalid stop ack for node '{node_id}' (current state: {current_state})\")]\n    InvalidStopAck {\n        node_id: Arc<str>,\n        current_state: &'static str,\n    },","sourceCodeStart":279,"sourceCodeEnd":315,"githubUrl":"https://github.com/influxdata/influxdb/blob/06200ef96ba82c5f6727e5038a83af8e722c6875/influxdb3_catalog/src/error.rs#L279-L315","documentation":"This error is returned when a request to stop a node finds the node is already in the stopped state. Stopping is only valid from a running/paused state; the node id is included in the message. It prevents redundant or conflicting node-state transitions in the catalog.","triggerScenarios":"Calling node stop (e.g. `stop_node` or the corresponding admin HTTP endpoint) for a node whose catalog state is already `stopped`.","commonSituations":"Retrying a stop command after a first successful attempt; orchestration scripts with stale views of node state; concurrent operators issuing the same stop command.","solutions":["Treat the node as already stopped and proceed — no action needed","Check node state (`influxdb3 show nodes`) before issuing stop","Make orchestration idempotent: catch this error and continue","Only issue stop for nodes in a running/active state"],"exampleFix":"// before\nadmin.stop_node(node_id)?;\n// after\nmatch admin.stop_node(node_id) {\n    Ok(_) => {},\n    Err(e) if e.to_string().contains(\"already stopped\") => {}, // idempotent\n    Err(e) => return Err(e.into()),\n}","handlingStrategy":"try-catch","validationCode":"fn is_stopped(state: &NodeState) -> bool { matches!(state, NodeState::Stopped) }\n// only call stop when !is_stopped(node.state)","typeGuard":"fn as_stopped(state: &NodeState) -> Option<&NodeStopped> {\n    match state { NodeState::Stopped(s) => Some(s), _ => None }\n}","tryCatchPattern":"match stop_node(node_id) {\n    Err(CatalogError::NodeAlreadyStopped { .. }) => Ok(()), // idempotent success\n    r => r,\n}","preventionTips":["Make stop operations idempotent by catching this error as success","Query node state before issuing stop commands","Avoid concurrent stop requests from multiple operators"],"tags":["catalog","nodes","lifecycle","idempotency"],"backgroundTag":"invalid-state-transition","analyzedSha":"06200ef96ba82c5f6727e5038a83af8e722c6875","analyzedAt":"2026-09-19T12:55:30.003Z","contentChangedAt":"2026-09-19T12:55:30.003Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}