wchevreuil commented on PR #6448:
URL: https://github.com/apache/hbase/pull/6448#issuecomment-2755002936

   > Which version were you guys on when you hit this problem?
   
   This issue is being observed on a 2.4.17 (with some extra backports), but I 
guess it could also affect higher versions.
   
   > I still do not get the point that why the regions could be in offline 
state...
   My reading is that the meta replicas never get assigned, because we never 
trigger the ModifyTableProcedure to change region replicas count in the meta 
table descriptor:
   
   1) [We will enter the block here because replica count is 3 in the 
config](https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java#L1167)
   
   2) [This will return 1 because we are running this master for the first time 
and no meta replica node has been created yet in 
ZK](https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java#L1175)
   
   3) [This returns false because we are using a root dir of a previous 
existing cluster, where meta replica was enabled, so the meta descriptor is 
already 3] 
(https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java#L1177)
   
   4) [This too returns false, and we never trigger the ModifyTableProcedure] 
(https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java#L1185)
   
   5) Since we miss triggering the ModifyTableProcedure, we never manage to 
assign the meta replicas, which should occur 
[here](https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/master/procedure/ModifyTableProcedure.java#L244)
   
   @Apache9 @richardantal does the above make sense? If so, I think the 
proposed fix should be improved, as it would update the metaDesc with 1 as 
replica count just to pass [this if 
check](https://github.com/apache/hbase/pull/6448/files#diff-0e55b368bd805325243956ccd037e06bf8954c2c2cb99b665a1dd4c88f26f97bR1177),
 create a new descriptor with replica count 3 and trigger the modify proc. 
   
   We should rather just trigger the meta replicas assignment, when we see 
replica count in table desc is greater than existingReplicasCount.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to