Pivotal Knowledge Base


Start of a PHD cluster fails with ERRORS: [<HOSTNAME>] : [FORMAT ERROR] Preformatted namenode already exists.


While starting a fresh PHD cluster using icm_client, below error message is observed
ERRORS: [cvlppvtlan3priv.cablevision.com : [FORMAT ERROR] Preformatted namenode already exists. Please delete the following directories: {dfs.namenode.name.dir}/current (from namenode) and {dfs.datanode.data.dir}/current (from datanodes) before trying to start the cluster


Cluster is new deployment and does not have any useful data.


During start of phd cluster, based on the state of the cluster if current/VERSION file exists under dfs.namenode.name.dir, icm_client throws this error message. 
Such situation may occur if there was a cluster which was deployed and successfully started earlier but later uninstalled. Then during next cluster installation, such error may be thrown.

Resolution steps:
- Stop the cluster
- Login to the namenode
- Verify hdfs-site.xml to identify the value of dfs.namenode.name.dir (Ex: /data/nn/dfs/name)
- Delete contents under namenode directory, Ex: rm -rf /data/nn/dfs/name/current/*
- If datanodes have data, you may identify the value of dfs.datanode.data.dir from hdfs-site.xml. (Ex: /data/1/dfs/data,/data/2/dfs/data)
- Delete contents from all the datanode's, (Ex: rm -rf /data/1/dfs/data /data/2/dfs/data)
- Start the cluster


Powered by Zendesk