Restore HDFS metadata from a backup using Cloudera Manager

When both the NameNode hosts have failed, you can use Cloudera Manager to restore HDFS metadata.

  1. Remove the NameNode, JournalNode, and Failover Controller roles from the HDFS service.
  2. Add the host on which the NameNode role will run.
  3. Create the NameNode data directory, ensuring that the permissions, ownership, and group are set correctly.
  4. Copy the backed up files to the NameNode data directory.
  5. Add the NameNode role to the host.
  6. Add the Secondary NameNode role to another host.
  7. Enable high availability.
    If not all roles are started after the wizard completes, restart the HDFS service. Upon startup, the NameNode reads the fsimage file and loads it into memory. If the JournalNodes are up and running and there are edit files present, any edits newer than the fsimage are applied.