HBase Backup/Export/Import Tool
Sep.22,2008
We (Mahalo) have just released a backup and restore tool for HBase.
From the docs:
Attached is a simple import, export, and backup utility. Mahalo.com has been using this in production for several months to back up our HBase clusters as well as to migrate data from production to development clusters, etc. Simple MapReduce job for exporting data from an HBase table. The exported data is in a simple, flat format that can then be imported using another MapReduce job. This gives you both a backup capability, and a simple way to import and export data from tables. The output of a backup job is a flat text file, or series of flat text files. Each row is represented by a single line, with each item tab delimited. Column names are plain text, while column values are base 64 encoded. This helps us deal with tabs and line breaks in the data. Generally you should not have to worry about this at all.
Both comments and pings are currently closed.
Filed Under :
Tags :
It seems like this doesn’t work with hadoop/hbase 0.19 Or at lease with my limited java_fu I can’t get the ant build to work with that version and what gets downloaded from the link http://issues.apache.org/jira/browse/HBASE-897
Is this still considered the best way to backup HBase? Is there a version of the tool that works with hbase 0.19.x? Or am I just doing something wrong. The error on build is:
[javac] /root/hbase_backup_release/src/com/mahalo/hadoop/hbase/TableImporter.java:34: no interface expected here [javac] public class TableImporter extends TableReduce { [javac] ^ [javac] /root/hbase_backup_release/src/com/mahalo/hadoop/hbase/Exporter.java:79: cannot find symbol [javac] symbol : method setOutputPath(org.apache.hadoop.fs.Path) [javac] location: class org.apache.hadoop.mapred.JobConf [javac] c.setOutputPath(new Path(_output ) ); [javac] ^ [javac] /root/hbase_backup_release/src/com/mahalo/hadoop/hbase/Exporter.java:81: warning: [unchecked] unchecked conversion [javac] found : java.lang.Class [javac] required: java.lang.Class [javac] c.setReducerClass(exporterClass); [javac] ^ [javac] /root/hbase_backup_release/src/com/mahalo/hadoop/hbase/Importer.java:52: cannot find symbol [javac] symbol : method setInputPath(org.apache.hadoop.fs.Path) [javac] location: class org.apache.hadoop.mapred.JobConf [javac] c.setInputPath( new Path( args[0] ) ); [javac] ^ [javac] /root/hbase_backup_release/src/com/mahalo/hadoop/hbase/Importer.java:58: warning: [unchecked] unchecked conversion [javac] found : java.lang.Class [javac] required: java.lang.Class [javac] c.setReducerClass( importerClass ); [javac] ^ [javac] /root/hbase_backup_release/src/com/mahalo/hadoop/hbase/Importer.java:59: cannot find symbol [javac] symbol : method initJob(java.lang.String,java.lang.Class,org.apache.hadoop.mapred.JobConf) [javac] location: interface org.apache.hadoop.hbase.mapred.TableReduce [javac] TableReduce.initJob( args[1], importerClass, c ); [javac] ^ [javac] /root/hbase_backup_release/src/com/mahalo/hadoop/hbase/TableImporter.java:45: method does not override or implement a method from a supertype [javac] @Override [javac] ^ [javac] 5 errors