[ 
https://issues.apache.org/jira/browse/WHIRR-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12992925#comment-12992925
 ] 

Lars George commented on WHIRR-177:
-----------------------------------

To enable this we need to add the ZooKeeper details to the hbase-site.xml and 
start it through the HBase daemon script, for example:

{code}
HBASE_HOME=`ls -d /usr/local/hbase-*`

# HBase configuration (Zookeeper)
cat > $HBASE_HOME/conf/hbase-site.xml <<EOF
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
<property>
  <name>hbase.zookeeper.quorum</name>
  <value>$ZOOKEEPER_QUORUM</value>
</property>
<property>
  <name>zookeeper.session.timeout</name>
  <value>60000</value>
</property>
<property>
  <name>hbase.zookeeper.property.dataDir</name>
  <value>/mnt/hbase/zk</value>
</property>
<property>
  <name>hbase.zookeeper.property.maxClientCnxns</name>
  <value>100</value>
</property>
</configuration>
EOF

...

mkdir -p /mnt/hbase/logs
mkdir -p /mnt/hbase/zk

...

[ ! -f /etc/hosts ] &&  echo "127.0.0.1 localhost" > /etc/hosts

...

"$HBASE_HOME"/bin/hbase-daemon.sh start zookeeper
{code}

Obviously we need to make sure not to override any existing hbase-site.xml but 
add to it. 

> [HBase] Support embedded ZooKeeper
> ----------------------------------
>
>                 Key: WHIRR-177
>                 URL: https://issues.apache.org/jira/browse/WHIRR-177
>             Project: Whirr
>          Issue Type: Improvement
>          Components: service/hbase
>    Affects Versions: 0.3.0
>            Reporter: Lars George
>            Assignee: Lars George
>             Fix For: 0.4.0
>
>
> This can be achieved like so:
> * Check if there is no "zk" role in the template -> set HBaseManagesZK = true
> * Emit a zoo.cfg from the HBase post-configure script next to the 
> hbase-site.xml
> * Set the option in hbase-env.sh to indicate that HBase manages ZK:
> {code}HBASE_MANAGES_ZK=true{code}
> Question is how many nodes run ZK? All slaves? A subset?

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to