ERROR: KeeperErrorCode = NoNode for /hbase/master, hbase reports an error when viewing the table on the shell command line

Error ERROR: KeeperErrorCode = NoNode for /hbase/master

error message

Cause Analysis

Modifying the hbase configuration file hbase-site.xml in a pseudo-distributed environment will result in incomplete files. The files on hadoop are inconsistent with the local files, so when entering hbase, the list cannot search for the entire previous file. In short, before the distributed storage, there were 3 machines, 1 of which stored 1 block to form a complete file. Now that 2 are removed, an error will be reported when querying again.

solution

1. Exit the hbase shell

hbase:002:0> exit

2. Exit hbase

[root@node1 hbase-2.4.13]# stop-hbase.sh

3. Exit hadoop

[root@node1 hbase-2.4.13]# stop-all.sh

4. View progress

[root@node1 hbase-2.4.13]# jps

no process state

5. Restart hadoop

[root@node1 hbase-2.4.13]# start-all.sh

6. Enter the hadoop file path

[root@node1 hbase-2.4.13]# cd /usr/local/hadoop-3.3.0

7. View hadoop root directory

[root@node1 hadoop-3.3.0]# hadoop fs -ls /

hbase file exists

8. Disable Hadoop Safe Mode

[root@node1 hadoop-3.3.0]# hdfs dfsadmin -safemode leave

safe mode off

9. delete hbase

[root@node1 hadoop-3.3.0]# hadoop fs -rm -r  /hbase

delete hbase

10. View the directory again

[root@node1 hadoop-3.3.0]# hadoop fs -ls

no hbase

11. Start hbase

[root@node1 hadoop-3.3.0]# start-hbase.sh

12. Enter the shell command line

[root@node1 hadoop-3.3.0]# hbase shell

13. View table

hbase:001:0> list

insert image description here

Successfully resolved

Guess you like

Origin blog.csdn.net/m0_58353740/article/details/130447392