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

Jonathan Hsieh commented on HBASE-11405:
----------------------------------------


Let's tell the user where the lock file is in case it was left by an hbck 
instance terminated with kill -9 that left the tmp file behind.  Also say to 
delete if you are sure the other hbck is dead.
{code}
+    // Check if another instance of balancer is running
+    hbckOutFd = checkAndMarkRunningHbck(); 
+    if (hbckOutFd == null) {
+      LOG.error("Another balancer is running - Exiting this instance");
+      setRetCode(-1);
+      Runtime.getRuntime().exit(-1);
+    }
{code}

> Multiple invocations of hbck in parallel disables balancer permanently 
> -----------------------------------------------------------------------
>
>                 Key: HBASE-11405
>                 URL: https://issues.apache.org/jira/browse/HBASE-11405
>             Project: HBase
>          Issue Type: Bug
>          Components: Balancer, hbck
>    Affects Versions: 0.99.0
>            Reporter: bharath v
>            Assignee: bharath v
>         Attachments: HBASE-11405-trunk-rebased.patch, 
> HBASE-11405-trunk.patch, HBASE-11405-trunk.patch.1, 
> hbase-11405.rebase.140911.patch
>
>
> This is because of the following piece of code in hbck
> {code:borderStyle=solid}
>   boolean oldBalancer = admin.setBalancerRunning(false, true);
>     try {
>       onlineConsistencyRepair();
>     }
>     finally {
>       admin.setBalancerRunning(oldBalancer, false);
>     }
> {code}
> Newer invocations set oldBalancer to false as it was disabled by previous 
> invocations and this disables balancer permanently unless its manually turned 
> on by the user. Easy to reproduce, just run hbck 100 times in a loop in 2 
> different sessions and you can see that balancer is set to false in the 
> HMaster logs.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to