Support Questions
Find answers, ask questions, and share your expertise

CDH 5.1 migration

Highlighted

CDH 5.1 migration

Expert Contributor

since we need migrate data-center, so our CDH also should be migrated to new env, the two data-center network is connectted.

 

there are near 1000+ tables in Hbase and HIVE, and also there are 100+ oozie jobs.  we have just one day+ to migrate all data to new env.

total data size is not big, just 2TB.

 

my sloution is using hbase cluster replication to replicate all hbase tables, but it seems so difficult, there near 1000+ tables, it means i need add

1000+ peers.

 

about hive tables, it seems just has one solution, export all table and import to new env.  

 

oozie jobs as i think just export source database to new database is ok, but since all the ip address has been changed, this is also a difficult point.

 

 

here i am asking peoples who has this experience of migration CDH to new env can give me some advises?

 

 

8 REPLIES 8
Highlighted

Re: CDH 5.1 migration

Master Guru
Seems to me like the easiest way for the HBase problem may be to shut HBase down cleanly and copy over /hbase as-is (preserving permissions and ownership) from the source to destination.
Highlighted

Re: CDH 5.1 migration

Expert Contributor

just copy /hase is ok ?  how about tables definition ?  

Highlighted

Re: CDH 5.1 migration

Master Guru
HBase persists all required metadata and data into HDFS, into the common root-dir location (/hbase).
Highlighted

Re: CDH 5.1 migration

Expert Contributor

thanks very much,  what about HIVE migration ?   if i copy all /usr/hive, and migrate hive in MySQL to new cluster, it will work fine ?

Highlighted

Re: CDH 5.1 migration

Master Guru
Yes, it should. Ensure to keep the permissions and ownership the same, BTW.
Highlighted

Re: CDH 5.1 migration

Expert Contributor

the hostname and ip address are diffierent from the old cluster, i have checked some file in /hbase, there are some files include namenode hostname, and you know hbase region has arranged by hbase master, all the thing is diffierent.

 

so i don't think cp /hbase to new cluster can migrate hbase.

Highlighted

Re: CDH 5.1 migration

Master Guru
The point about a clean shutdown covers that. The host-named files are the
WALs, which are not needed if you close the cluster cleanly (i.e. flushed
regions).
Highlighted

Re: CDH 5.1 migration

Expert Contributor
my migration is nearly done.

My solution is migrating the base data for hive and hbase, then migrating increment data every day until switching data center .
for hive just copy the HDFS data, and create the same table definition, if the table is a partition table, need more step as alter table add partition.

for hbase using snapshot, this is better than export/import. after that using program to migrate increment data every day or hour.

for solr, just flush data from hase one more time, about how to flush , you can go to find it in search document
Don't have an account?