Search code examples
hbasereplicationfailover

hbase when particular region server fails, read the data from the replicated cluster


As I'm new to hbase file storage, is there any option available to read particular regions from the replicated cluster when the region server fails

For example, In hbase cluster, with replication mode enabled master-master mode(data cluster with separate zookeeper) it has 1 Master and 5 region servers. In that one region server fails, in this case shall I able to read data belongs to that region server from replicated cluster? Like the concept proposed by facebook

https://code.facebook.com/posts/321111638043166/hydrabase-the-evolution-of-hbase-facebook/

or else if we face issues with many region server in the main cluster then we need to change the read and write to be served from the replicated server. (Main cluster becomes replicated cluster and vice versa)

For this, what configuration we need to do this work apart from the zookeeper quorum connection via Java API?


Solution

  • In Hbase [With HDFS storage & replication enabled] if a region server fails, the regions served by this failed region server will get reassigned to other region servers [Since the HFiles and WAL are replicated in HDFS, you will not lose your data]. Due to the nature of failover in Hbase, this reassignment will result in splitting and replaying the contents of WAL which lengthens the time of recovery.

    However in Hydrabase, each region is served by a quorum of region servers and all the read and writes from the clients are served by the leader in quorum. Each hosting region server synchronously writes to the WAL corresponding the modified region. If the leader goes down, one of the follower will get elected as the leader and will continue to serve the read and write requests.

    Both Hbase and Hydrabase ensure the data availability in case of region server failure. Hydrabase ensures the reduction of downtime due to region server failure.