hadoop – Incompatible namespaceIDs in hadoop/dfs/data

Are you seeing this ?

org.apache.hadoop.hdfs.server.datanode.DataNode: java.io.IOException: Incompatible namespaceIDs in hadoop/dfs/data: namenode namespaceID = X; datanode namespaceID = Y

The fix (in the order)

  1. Delete VERSION files in the dfs directory
    $ find /hadoop/dfs -name VERSION -exec rm -rf "{}" \;)
  2. Format the namenode (#hadoop namenode -format)

Cause

A new namespaceIDs (present in VERSION file) is generated each time the HDFS is formatted. It should be same for both VERSION files of data and name node.

Caution

Backup all your data. I am not responsible for your loss of data.

 

 

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *