hbase에서는 ROOT catalog table을 사용하고 있었다. 그러나. 0.95, 0.98부터는 ROOT catalog table을 사용하지 않고, .META table을 직접 읽고 쓰도록  바뀌었다. 원래 ROOT영역은 여러개의 meta region을 지원하기 위해서 만든건데. 현실적으로 Hbase는 심플하게 하나의 meta region만 쓰기 때문에 바뀌었다. 여러개의 meta region이 존재하게 된다면 그때 다시 ROOT table이 생길듯 하다. 



1. HBASE-3171(https://issues.apache.org/jira/browse/HBASE-3171)



Rather than storing the ROOT region location in ZooKeeper, going to ROOT, and reading the META location, we should just store the META location directly in ZooKeeper.

The purpose of the root region from the bigtable paper was to support multiple meta regions. Currently, we explicitly only support a single meta region, so the translation from our current code of a single root location to a single meta location will be very simple. Long-term, it seems reasonable that we could store several meta region locations in ZK. There's been some discussion in HBASE-1755 about actually moving META into ZK, but I think this jira is a good step towards taking some of the complexity out of how we have to deal with catalog tables everywhere.

As-is, a new client already requires ZK to get the root location, so this would not change those requirements in any way.

The primary motivation for this is to simplify things like CatalogTracker. The way we can handle root in that class is really simple but the tracking of meta is difficulty and a bit hacky. This hack on tracking of the meta location is what caused one of the bugs over in HBASE-3159.



2. 현재 hbase 문서에서는 ROOT의 내용이 여전히 남아 있다. 그러나 조만간에 삭제될 예정이다. 


http://hbase.apache.org/book/arch.catalog.html


9.2. Catalog Tables

The catalog tables -ROOT- and .META. exist as HBase tables. They are filtered out of the HBase shell's list command, but they are in fact tables just like any other.

9.2.1. ROOT

-ROOT- keeps track of where the .META. table is. The -ROOT- table structure is as follows:

Key:

  • .META. region key (.META.,,1)

Values:

  • info:regioninfo (serialized HRegionInfo instance of .META.)
  • info:server (server:port of the RegionServer holding .META.)
  • info:serverstartcode (start-time of the RegionServer process holding .META.)




'nosql' 카테고리의 다른 글

[hbase] hbase shell의 prompt  (0) 2013.07.05
[hbase] Phoenix 성능  (0) 2013.06.24
[hbase] 제한적인 트랙잭션  (0) 2013.06.20
[hbase] shell에서 major compation 지원  (0) 2013.06.19
hbase - block, block cache 공부  (0) 2013.06.07
Posted by '김용환'
,