{"record":{"id":"9ff7820707b08ec1","repo":"apache/druid","slug":"skipping-deep-storage-directory-kill-storage-dire","errorCode":null,"errorMessage":"Skipping deep storage directory kill: storage directory not configured","messagePattern":"Skipping deep storage directory kill: storage directory not configured","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"extensions-core/hdfs-storage/src/main/java/org/apache/druid/storage/hdfs/HdfsDataSegmentKiller.java","lineNumber":202,"sourceCode":"      return null;\n    }\n    if (relativePath.charAt(0) == '/') {\n      log.warn(\"Skipping deep storage directory kill: relative path must not be absolute, got [%s]\", relativePath);\n      return null;\n    }\n    if (relativePath.indexOf('\\\\') >= 0) {\n      log.warn(\"Skipping deep storage directory kill: backslash not allowed in path [%s]\", relativePath);\n      return null;\n    }\n    for (String segment : StringUtils.splitPreserveAllTokens(relativePath, '/')) {\n      if (segment.isEmpty() || \"..\".equals(segment)) {\n        log.warn(\"Skipping deep storage directory kill: invalid path[%s]\", relativePath);\n        return null;\n      }\n    }\n\n    if (storageDirectory == null) {\n      log.warn(\"Skipping deep storage directory kill: storage directory not configured\");\n      return null;\n    }\n\n    final String hdfsRelativePath = relativePath.replace(':', '_');\n    final String storageDirectoryString = storageDirectory.toString();\n    final String sep = storageDirectoryString.endsWith(Path.SEPARATOR) ? \"\" : Path.SEPARATOR;\n    return new Path(storageDirectoryString + sep + hdfsRelativePath);\n  }\n}\n","sourceCodeStart":184,"sourceCodeEnd":212,"githubUrl":"https://github.com/apache/druid/blob/9b90983fd291f26935af934383ce360473179e4d/extensions-core/hdfs-storage/src/main/java/org/apache/druid/storage/hdfs/HdfsDataSegmentKiller.java#L184-L212","documentation":"constructHdfsDeletePath requires druid.storage.storageDirectory to be configured; if storageDirectory is null it logs this warning and returns null, skipping the directory kill. Without a configured base directory the killer cannot safely compute the absolute HDFS path to delete.","triggerScenarios":"Running the kill task (or segment kill via coordinator) with the HDFS deep storage extension loaded but druid.storage.storageDirectory unset in the runtime properties.","commonSituations":"Fresh cluster setups where druid.storage.type=hdfs was set but the storageDirectory property was omitted, or different runtime property files between coordinator and historical nodes.","solutions":["Set druid.storage.storageDirectory in the common runtime properties (e.g. druid.storage.storageDirectory=/druid/segments)","Restart the affected services so the config is picked up","Verify HdfsDataSegmentPusher pushes to the same directory so killer and pusher agree"],"exampleFix":"// before (runtime.properties)\ndruid.storage.type=hdfs\n// after\ndruid.storage.type=hdfs\ndruid.storage.storageDirectory=/druid/segments","handlingStrategy":"validation","validationCode":"String dir = props.getProperty(\"druid.storage.storageDirectory\");\nif (dir == null || dir.isEmpty()) { throw new IllegalStateException(\"druid.storage.storageDirectory must be set when druid.storage.type=hdfs\"); }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Include druid.storage.storageDirectory in every runtime.properties template","Add startup config checks for hdfs deep storage","Keep common runtime properties identical across coordinator/historical/middleManager nodes"],"tags":["hdfs","segment-kill","configuration","druid"],"backgroundTag":"missing-config-value","analyzedSha":"9b90983fd291f26935af934383ce360473179e4d","analyzedAt":"2026-09-07T13:32:30.957Z","contentChangedAt":"2026-09-07T13:32:30.957Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}