hi,mailist:
i want to move data from hbase 0.94 to 0.96 ,someone told
me ReplicationBridgeServer can do this, i do it use the following process
download code from
https://github.com/hortonworks/HBaseReplicationBridgeServer
compile& assembly
mvn clean install -DskipTests
mvn assembly:single -DskipTests
copy hbase-replication-bridge-1.0.tar.gz to my hbase 0.96 master node,and
modify the conf file like:
vi ./conf/hbase-site.xml
<configuration>
<property>
<name>hbase.defaults.for.version.skip</name>
<value>true</value>
</property>
<property>
<name>hbase.bridge.server.port</name>
<value>60080</value>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>192.168.10.23,192.168.10.24,192.168.10.49</value>
<description>Comma separated list of servers in the ZooKeeper Quorum.
For example, "host1.mydomain.com,host2.mydomain.com,host3.mydomain.com".
</description>
</property>
<property>
<name>hbase.bridge.source.zookeeper.quorum</name>
<value>192.168.10.22:2281,192.168.10.34:2281,192.168.10.35:2281</value>
</property>
</configuration>
start bridge
export HADOOP_HOME=/usr/lib/hadoop
# java -cp
./conf:./lib/hbase-common-0.96.0-hadoop2.jar:./lib/hbase-0.94-jarjar.jar:./lib/*:./hbase-replication-bridge-1.0.jar
com.hortonworks.hbase.replication.bridge.ReplicationBridgeServer
and i see znode /hbase96 created on source zookeeper
and i add the following option on all my source hbase node(master node and
regionserver node)
<property>
<name>hbase.replication</name>
<value>true</value>
</property>
on my source hbase i use test table
hbase(main):003:0> disable 'test_1'
hbase(main):004:0> alter 'test_1',NAME=>'info',REPLICATION_SCOPE=>'1'
Updating all regions with the new schema...
1/1 regions updated.
Done.
hbase(main):005:0> enable 'test_1'
hbase(main):004:0> add_peer '1', '192.168.10.23:2181:/hbase'
0 row(s) in 0.0430 seconds
hbase(main):005:0> list_peers
PEER_ID CLUSTER_KEY STATE
1 192.168.10.23:2181:/hbase ENABLED
hbase(main):005:0> start_replication
0 row(s) in 0.0090 seconds
hbase(main):006:0> scan 'test_1'
ROW COLUMN+CELL
a0-200001 column=info:url,
timestamp=1404287286019, value=10001\x0910002\x0910005
a0-200002 column=info:url,
timestamp=1404287286019, value=10001\x0910004\x0910006
a0-200003 column=info:url,
timestamp=1404287286019, value=10002\x0910003\x0910004
a0-200004 column=info:url,
timestamp=1404287286019, value=10004
a0-200005 column=info:url,
timestamp=1404287286019, value=10002
a0-200006 column=info:url,
timestamp=1404287286019, value=10002\x0910005
a0-200007 column=info:url,
timestamp=1404287286019, value=10003\x0910005
7 row(s) in 0.0430 seconds
on my destination hbase 0..96 i see no data sync
hbase(main):008:0> scan 'test_1'
ROW COLUMN+CELL
0 row(s) in 0.0140 seconds
hbase(main):009:0> scan 'default:test_1'
ROW COLUMN+CELL
0 row(s) in 0.0120 seconds
hbase(main):010:0> scan 'pipe:test_1'
ROW COLUMN+CELL
0 row(s) in 0.0080 seconds
hbase(main):011:0> list_namespace
NAMESPACE
default
hbase
pipe
3 row(s) in 0.0470 seconds
anyone can help me?