欢迎投稿

今日深度:

HBase 备份及恢复,

HBase 备份及恢复,


注意事项:1.HBase版本需要保持一致,否则数据无法恢复


本方案使用export及import方法,还有其他方法可以实现,暂不涉及。

1.备份,以表为单位进行导出

./bin/hbase org.apache.hadoop.hbase.mapreduce.Export $table_name $dst_path

2.恢复

在新集群创建表,可以用describe从源集群获取表schema

describe $table_name

导入数据

./bin/hbase org.apache.hadoop.hbase.mapreduce.Import $table_name $dst_path

www.htsjk.Com true http://www.htsjk.com/hbase/40276.html NewsArticle HBase 备份及恢复, 注意事项:1.HBase版本需要保持一致,否则数据无法恢复 本方案使用export及import方法,还有其他方法可以实现,暂不涉及。 1.备份,以表为单位进行导出 ./bin/hbase or...
相关文章
    暂无相关文章
评论暂时关闭