[
https://issues.apache.org/jira/browse/HBASE-24923?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Duo Zhang resolved HBASE-24923.
-------------------------------
Fix Version/s: 2.7.0
3.0.0-beta-2
2.5.16
2.6.7
Hadoop Flags: Reviewed
Resolution: Fixed
Pushed to all active branches.
Thanks [~swaralijoshi] for contributing!
> Running InitMetaProcedures are missed if Hmaster startup happens after Meta
> assign
> ----------------------------------------------------------------------------------
>
> Key: HBASE-24923
> URL: https://issues.apache.org/jira/browse/HBASE-24923
> Project: HBase
> Issue Type: Bug
> Affects Versions: 3.0.0-alpha-1
> Reporter: Zach York
> Assignee: Swarali Joshi
> Priority: Major
> Labels: pull-request-available
> Fix For: 2.7.0, 3.0.0-beta-2, 2.5.16, 2.6.7
>
>
> In HMaster startup, if the InitMetaProcedure was stopped after the meta
> assign stage, it will have a RegionState assigned to it and will not fall
> into this if statement:
> https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java#L1044.
>
> This means if an InitMetaProcedure is running (in the
> INIT_META_CREATE_NAMESPACES state), we won't look for any instances of
> running InitMetaProcedures and won't correctly await until they are done:
> https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java#L1065
> The check for running InitMetaProcedures should be moved outside of the if
> statement and only if it is null should it try to add a new InitMetaProcedure
> (if there is no RegionState for meta or if meta is offline). This way we will
> correctly wait for procedures that are running that have passed the
> INIT_META_ASSIGN_META state (which sets the RegionStates that HMaster is
> looking at).
--
This message was sent by Atlassian Jira
(v8.20.10#820010)