I'm running HBase in pseudo-distributed mode on my workstation. We also have HBase running on a cluster. Using the HBase shell, I'd like to access the HBase instance that's running on the cluster from my workstation. I would like to do this without logging into one of the cluster machines.
我在我的工作站上以伪分布式模式运行HBase。我们还在群集上运行HBase。使用HBase shell,我想从我的工作站访问在集群上运行的HBase实例。我想在不登录其中一台集群机器的情况下这样做。
With Hadoop, you can run jobs on a remote cluster by specifying the -conf parameter and supplying an alternate version of hadoop-site.xml. Is there an equivalent for the HBase shell?
使用Hadoop,您可以通过指定-conf参数并提供hadoop-site.xml的备用版本来在远程集群上运行作业。是否有HBase shell的等价物?
I'm running cloudera cdh3u3 on my workstation and on the cluster machines.
我正在我的工作站和集群机器上运行cloudera cdh3u3。
3 个解决方案
#1
4
Make changes to the following conf files.
更改以下conf文件。
- For hadoop: core-site.xml, mapred-site.xml.
- 对于hadoop:core-site.xml,mapred-site.xml。
- For hbase: hbase-site.xml.
- 对于hbase:hbase-site.xml。
You could create multiple versions of these files and switch between them as needed.
您可以创建这些文件的多个版本,并根据需要在它们之间切换。
#2
3
change hbase-site.xml add zookeeper host port with hbase server.
更改hbase-site.xml使用hbase服务器添加zookeeper主机端口。
<configuration>
<property>
<name>hbase.zookeeper.quorum</name>
<value>zk.hostname</value>
</property>
</configuration>
#3
1
I'm using following command:
我正在使用以下命令:
hbase --config "path to folder with config files" shell
Folder with configuration should contain at least hbase-site.xml with content:
配置文件夹应至少包含带内容的hbase-site.xml:
<configuration>
<property>
<name>hbase.cluster.distributed</name>
<value>true</value>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>zk1,zk2,zk3</value>
</property>
<property>
<name>zookeeper.znode.parent</name>
<!--or /hbase-->
<value>/hbase-unsecure</value>
</property>
</configuration>
#1
4
Make changes to the following conf files.
更改以下conf文件。
- For hadoop: core-site.xml, mapred-site.xml.
- 对于hadoop:core-site.xml,mapred-site.xml。
- For hbase: hbase-site.xml.
- 对于hbase:hbase-site.xml。
You could create multiple versions of these files and switch between them as needed.
您可以创建这些文件的多个版本,并根据需要在它们之间切换。
#2
3
change hbase-site.xml add zookeeper host port with hbase server.
更改hbase-site.xml使用hbase服务器添加zookeeper主机端口。
<configuration>
<property>
<name>hbase.zookeeper.quorum</name>
<value>zk.hostname</value>
</property>
</configuration>
#3
1
I'm using following command:
我正在使用以下命令:
hbase --config "path to folder with config files" shell
Folder with configuration should contain at least hbase-site.xml with content:
配置文件夹应至少包含带内容的hbase-site.xml:
<configuration>
<property>
<name>hbase.cluster.distributed</name>
<value>true</value>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>zk1,zk2,zk3</value>
</property>
<property>
<name>zookeeper.znode.parent</name>
<!--or /hbase-->
<value>/hbase-unsecure</value>
</property>
</configuration>