天天看点

ClusterId read in ZooKeeper is null,java.net.UnknownHostException: unknown host: master

1、ZooKeeperRegistry.getClusterId --> ClusterId read in ZooKeeper is null

ClusterId read in ZooKeeper is null,java.net.UnknownHostException: unknown host: master

解决办法:在设置HBaseConfiguration处添加以下配置

configuration.set(“zookeeper.znode.parent”, “/hbase-unsecure”);
ClusterId read in ZooKeeper is null,java.net.UnknownHostException: unknown host: master

2、java.net.UnknownHostException: unknown host: master

按以上配置好后,发现还是有问题

ClusterId read in ZooKeeper is null,java.net.UnknownHostException: unknown host: master

解决办法:在C:\Windows\System32\drivers\etc\hosts文件添加一行

192.168.x.xxx master

前面地址为HBase所在服务器的地址