WebHosting

Friday, February 22, 2013

Hbase Backup and Restory : Export / Import Mapreduce



Command to use for export:
-------------------------------------------------------------------------------------------------------
[incrimental backup]




bin/hadoop jar /path/to/hbase-0.20.3.jar export
Usage: Export <tablename> <outputdir> [<versions> [<starttime> [<endtime>]]]




[full one time backup]

bin/hadoop jar /path/to/hbase-0.20.3.jar export
Usage: Export <tablename> <outputdir>

 
Exporting table:
----------------------------------------------------------------------------------------------------------

bin/hadoop jar /path/to/hbase-0.20.3.jar export table_backed hdfs://<namenode>:9000/backupdata/table_backed

Copying from hdfs to local drive:
---------------------------------------------------------------------------------------------------------

bin/hadoop -copyToLocal /export/table_backed /somewhere/local

Copying from local to hdfs
---------------------------------------------------------------------------------------------------------

bin/hadoop -copyFromLocal /somewhere/local /import/table_backed

Importing to hdfs for hbase
---------------------------------------------------------------------------------------------------------

bin/hadoop jar /path/to/hbase-0.20.3.jar import table_backed  hdfs://<namenode>:9000/backupdata/table_backed


No comments:

Post a Comment

Thank you for Commenting Will reply soon ......

Featured Posts

How to Enable and Configure Remote Desktop (RDP) on Ubuntu 24.04.4 LTS

Remote Desktop Protocol (RDP) support in Ubuntu has become considerably easier with the GNOME Remote Desktop stack included in modern Ubuntu...