{"record":{"id":"4ea2c9c5e7ff2b7c","repo":"apache/hadoop","slug":"satisfystoragepolicy-is-not-supported-for-httpfs-o","errorCode":null,"errorMessage":"satisfyStoragePolicy is not supported for HttpFs on {0}. Please check your fs.defaultFS configuration","messagePattern":"satisfyStoragePolicy is not supported for HttpFs on (.+?)\\. Please check your fs\\.defaultFS configuration","errorType":"exception","errorClass":"UnsupportedOperationException","httpStatus":400,"severity":"error","filePath":"hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/java/org/apache/hadoop/fs/http/server/FSOperations.java","lineNumber":2210,"sourceCode":"   * Executor that performs a satisfyStoragePolicy operation.\n   */\n  @InterfaceAudience.Private\n  public static class FSSatisyStoragePolicy\n      implements FileSystemAccess.FileSystemExecutor<Void> {\n\n    private Path path;\n\n    public FSSatisyStoragePolicy(String path) {\n      this.path = new Path(path);\n    }\n\n    @Override\n    public Void execute(FileSystem fs) throws IOException {\n      if (fs instanceof DistributedFileSystem) {\n        DistributedFileSystem dfs = (DistributedFileSystem) fs;\n        dfs.satisfyStoragePolicy(path);\n      } else {\n        throw new UnsupportedOperationException(\"satisfyStoragePolicy is \"\n            + \"not supported for HttpFs on \" + fs.getClass()\n            + \". Please check your fs.defaultFS configuration\");\n      }\n      return null;\n    }\n  }\n\n  /**\n   * Executor that performs a getFileBlockLocations operation.\n   */\n\n  @InterfaceAudience.Private\n  @SuppressWarnings(\"rawtypes\")\n  public static class FSFileBlockLocations implements FileSystemAccess.FileSystemExecutor<Map> {\n    final private Path path;\n    final private long offsetValue;\n    final private long lengthValue;\n","sourceCodeStart":2192,"sourceCodeEnd":2228,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/java/org/apache/hadoop/fs/http/server/FSOperations.java#L2192-L2228","documentation":"FSOperations.FSSatisyStoragePolicy.execute() invokes SATISFYSTORAGEPOLICY through DistributedFileSystem.satisfyStoragePolicy(), which schedules block-level storage-policy changes and exists only in HDFS. On any other backing filesystem the executor throws UnsupportedOperationException (HTTP 400 with this text), indicating the HttpFS server's fs.defaultFS is not HDFS.","triggerScenarios":"Client sends op=SATISFYSTORAGEPOLICY via webhdfs:// (e.g., after changing a dir to COLD/HOT policy) while HttpFS proxies to a non-HDFS filesystem.","commonSituations":"Storage-tiering automation pointed at an HttpFS gateway fronting object storage; standalone HttpFS test servers; fs.defaultFS lost during config refactors.","solutions":["Set the HttpFS server's fs.defaultFS to the HDFS nameservice and restart","Trigger policy satisfaction via WebHDFS or hdfs crypto/evm CLI directly on the cluster","For non-HDFS stores, remove the satisfy step: policy enforcement there is store-native","Confirm the response is this capability error, not a 403/404 on the path, before changing configs"],"exampleFix":"<!-- before: httpfs-site.xml -->\n<property><name>fs.defaultFS</name><value>file:///</value></property>\n<!-- after -->\n<property><name>fs.defaultFS</name><value>hdfs://ns1</value></property>\n<!-- restart HttpFS; SATISFYSTORAGEPOLICY then schedules block moves on HDFS -->","handlingStrategy":"try-catch","validationCode":null,"typeGuard":"static DistributedFileSystem asDfs(FileSystem fs) {\n  return fs instanceof DistributedFileSystem ? (DistributedFileSystem) fs : null;\n}","tryCatchPattern":"try {\n  fs.satisfyStoragePolicy(path);\n} catch (IOException e) {\n  if (e.getMessage() != null && e.getMessage().contains(\"not supported for HttpFs\")) {\n    throw new UnsupportedFeatureException(\"satisfyStoragePolicy requires HDFS-backed HttpFS\", e);\n  }\n  throw e;\n}","preventionTips":["Tiering automation should detect non-HDFS gateways and skip policy-satisfaction steps","Verify SATISFYSTORAGEPOLICY works in staging (HDFS-backed) before scheduling in prod","Remember this op is asynchronous even on HDFS; success only means the request was scheduled"],"tags":["httpfs","webhdfs","storage-policy","unsupported-operation","fs-defaultfs"],"backgroundTag":"unsupported-filesystem-operation","analyzedSha":"2add9630210752f88ceb1bb74eb65e37bf41da8e","analyzedAt":"2026-08-22T19:55:07.957Z","schemaVersion":2},"datasetVersion":"2026-08-22T20:17:22.307Z"}