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

Zhihong Yu commented on HBASE-5603:
-----------------------------------

w.r.t. http://hbase.apache.org/book.html#rolling, I think we can add more 
details to it.
e.g. see the following code snippet in bin/rolling-restart.sh:
{code}
    "$bin"/hbase-daemons.sh --config "${HBASE_CONF_DIR}" \
      --hosts "${HBASE_BACKUP_MASTERS}" stop master-backup
{code}
bin/graceful_stop.sh is mentioned in 
http://hbase.apache.org/book.html#decommission so people may not intuitively 
associate it with rolling restart.

Different companies have different practices w.r.t. rolling restart.
Since rolling-restart.sh was recently enhanced to respect region placement:
{code}
r1299983 | stack | 2012-03-12 23:30:15 -0700 (Mon, 12 Mar 2012) | 1 line

HBASE-5314 racefully rolling restart region servers in rolling-restart.sh
------------------------------------------------------------------------
{code}
I think we should put it in a useable form.
                
> rolling-restart.sh script hangs when attempting to detect expiration of 
> /hbase/master znode.
> --------------------------------------------------------------------------------------------
>
>                 Key: HBASE-5603
>                 URL: https://issues.apache.org/jira/browse/HBASE-5603
>             Project: HBase
>          Issue Type: Bug
>          Components: zookeeper
>    Affects Versions: 0.92.0, 0.94.0, 0.96.0
>            Reporter: Jonathan Hsieh
>            Priority: Blocker
>
> Due to bugfix ZOOKEEPER-1059 (ZK 3.4.0+), the rolling-restart.sh script will 
> hang when attempting to make sure the /hbase/master znode is deleted.
> Here's the code
> {code}
> # make sure the master znode has been deleted before continuing
>     zparent=`$bin/hbase org.apache.hadoop.hbase.util.HBaseConfTool 
> zookeeper.znode.parent`
>     if [ "$zparent" == "null" ]; then zparent="/hbase"; fi
>     zmaster=`$bin/hbase org.apache.hadoop.hbase.util.HBaseConfTool 
> zookeeper.znode.master`
>     if [ "$zmaster" == "null" ]; then zmaster="master"; fi
>     zmaster=$zparent/$zmaster
>     echo -n "Waiting for Master ZNode ${zmaster} to expire"
>     while bin/hbase zkcli stat $zmaster >/dev/null 2>&1; do
>       echo -n "."
>       sleep 1
>     done
>     echo #force a newline
> {code}
> Prior to ZOOKEEPER-1059, stat on a null znode would NPE and cause zkcli to 
> exit with retcode 1.  Afterwards, the null is caught, zkcli will exit with 0 
> in the case where the znode is present and in the case where it does not 
> exist.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to