I am building Hadoop Pseudo cluster in my personal machine using CentOS 9 and Hadoop 3.1.1. I completed the installation of hadoop and performed some operation, everything was fine. In later time, when I do jps, my namenode daemon was not running. So as per the guidelines from google search, I deleted namenode and datanode directory, recreated those and did "hadoop namenode -format", then my namenode (datanode as well) daemon started up and running. But I am not able to get any data stored in hdfs using "hdfs dfs -ls" which used to get me data before formatting the namenode.
I understand that formatting a namenode will create new namespace ID and cluster ID in namenode VERSION file due to which we are not able to get the old data from hdfs.
I want to know how can we recover the data as well.
I tried the below but doesnt work.
1. Replaced the clusterID value from datanode VERSION file to namenode VERSION file, assuming datanode will send the hearbeat and report to namenode thus namenode will build the metadata. But it doesnt help.
Any advice to restore the data please?
Asked by user3625945
(1 rep)
Jul 3, 2023, 02:34 AM
Last activity: Jul 13, 2023, 11:17 AM
Last activity: Jul 13, 2023, 11:17 AM