private void moveIntermediateArchivedDirToOriginalParent(Path originalDir, Path intermediateArchivedDir,
      FileSystem fs) throws HiveException {
    if (!HdfsUtils.pathExists(originalDir, context.getConf())) {
      context.getConsole().printInfo("Moving " + intermediateArchivedDir + " to " + originalDir);
      moveDir(fs, intermediateArchivedDir, originalDir);
    } else {
      context.getConsole().printInfo(originalDir + " already exists. Assuming it contains the archived version of "
          + "the partition");
    }
  }
Move the intermediate archived directory to the original parent directory.
ql/src/java/org/apache/hadoop/hive/ql/ddl/table/storage/archive/AlterTableArchiveOperation.java