为什么运行 HBase Master 的网页为 http://server:60010

为什么运行 HBase Master 的网页为 http://server:60010

我通过以下方式安装:

wget http://archive.cloudera.com/cdh/3/hbase-0.90.3-cdh3u1.tar.gz

这是我的 hbase_site.xml

<property>
    <name>hbase.master</name>
    <value>localhost:60000</value>
    <description>The host and port that the HBase master runs at.A value of 'local' runs the master and a regionserver in a single process.</description>
</property>
<property>
    <name>hbase.rootdir</name>
    <value>hdfs://localhost:9000/hdfs</value>
    <description>The directory shared by region servers.</description>
</property>
<property>
    <name>hbase.cluster.distributed</name>
    <value>true</value>
    <description>The mode the cluster will be in. Possible values are false: standalone and pseudo-distributed setups with managed  Zookeeper true: fully-distributed with unmanaged Zookeeper Quorum (see hbase-env.sh)
    </description>
</property>
<property>
    <name>hbase.zookeeper.property.clientPort</name>
    <value>2183</value>
    <description>Property from ZooKeeper's config zoo.cfg.The port at which the clients will connect.</description>
</property>
<property>
    <name>hbase.zookeeper.quorum</name>
    <value>localhost</value>
    <description>Comma separated list of servers in the ZooKeeper Quorum.For example,"host1.mydomain.com,host2.mydomain.com".By default this is set to localhost for local and pseudo-distributed modes of operation. For afully-distributed setup, this should be set to a full list of ZooKeeper quorum servers. If HBASE_MANAGES_ZK is set in hbase-env.sh this is the list of servers which we will start/stop ZooKeeper on. </description>
</property>

hbase-环境变量.h

# Tell HBase whether it should manage it's own instance of Zookeeper or not.
export HBASE_MANAGES_ZK=false

Here we are running our separate Zookeeper so needs to specify false. Default Hbase starts the default zookeeper compes up with Hbase.

#JAVA_HOME
export JAVA_HOME=/usr/lib/jvm/java-6-openjdk

当启动 hbase 时

<HBASE_HOME>/bin/start-hbase.sh

并尝试打开http://服务器:60010它没打开?

为什么 ?

答案1

从评论来看 - 这个问题是由于 zookeeper 没有运行而引起的。

答案2

首先检查“hbase-hduser-master-ubuntu.log“文件来自日志你的hbase安装路径的文件夹

如果你收到以下错误

2014-09-07 20:22:24,505 错误 [main] master.HMasterCommandLine: Master 退出 java.lang.RuntimeException:HMaster 中止于org.apache.hadoop.hbase.master.HMasterCommandLine.startMaster(HMasterCommandLine.java:194) 在 org.apache.hadoop.hbase.master.HMasterCommandLine.run(HMasterCommandLine.java:135) 在 org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70) 在 org.apache.hadoop.hbase.util.ServerCommandLine.doMain(ServerCommandLine.java:126) 在 org.apache.hadoop.hbase.master.HMaster.main(HMaster.java:2794)

比较核心站点.xmlHadoophbase 的站点.xml数据库. 两个文件中的 hdfs URL 应该相同

核心站点.xml

 <configuration>
    <property>
        <name>fs.default.name</name>
        <value>hdfs://192.168.203.130:9000</value>
    </property>
 </configuration>

hbase 的站点.xml

 <property>
    <name>hbase.rootdir</name>
    <!-- <value>hdfs://localhost:9000/hbase</value> -->
    <value>hdfs://192.168.203.130:9000/hbase</value> 
    <description>The directory shared by RegionServers.
    </description>
 </property>

答案3

添加“hadoop-core-.jar”HADOOP_HOME和“commons-configuration-.jar”HADOOP_HOME/lib放入文件夹中HBASE_HOME/lib。还要编辑“hosts”文件,将“127.0.1.1”替换为“127.0.0.1”。

答案4

从此来源下载并按照以下步骤操作:

wget http://www-us.apache.org/dist/hbase/stable/hbase-1.2.4-bin.tar.gz

tar xvzf hbase-1.2.4-bin.tar.gz

解压后使用 sudo mv 命令将文件移动到您应有的enter code here位置,我的是:

 sudo mv hbase-1.2.4 /*path of untar file*/ /usr/local/hbase/

相关内容