Star

v2.0恢复后空间不可用

  • nebula 版本:v2.0 每日更新版本
  • 部署方式(分布式 / 单机 / Docker / DBaaS):单机
  • 硬件信息
    • 磁盘( 必须为 SSD ,不支持 HDD)ssd
    • CPU、内存信息:
  • 问题的具体描述
    1、备份nba空间,备份成功
    image

2、删除nba space
drop space nba;

3、恢复nba space

 ./bin/br restore full --config "/bdp/nebula-storage/util/br/restore_example.yaml"
{"level":"info","ts":1609812299.1739905,"caller":"cmd/validate.go:33","msg":"checking ssh","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812300.0977652,"caller":"storage/storage.go:31","msg":"parsed external storage","schema":"local","path":"/bdp/store/1"}
{"level":"info","ts":1609812300.7537525,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"ls /bdp/store/1/BACKUP_2021_01_04_15_41_50","user":"root"}
{"level":"info","ts":1609812300.7590177,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"meta\nstorage\n"}
{"level":"info","ts":1609812300.7687109,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"ls /bdp/store/1/BACKUP_2021_01_04_15_41_50","user":"root"}
{"level":"info","ts":1609812300.7739003,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"meta\nstorage\n"}
{"level":"info","ts":1609812300.7739537,"caller":"restore/restore.go:74","msg":"download metafile","cmd":["cp","/bdp/store/1/BACKUP_2021_01_04_15_41_50/BACKUP_2021_01_04_15_41_50.meta","/tmp/"]}
{"level":"info","ts":1609812301.4447951,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service stop metad","user":"root"}
{"level":"info","ts":1609812301.4636831,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service stop storaged","user":"root"}
{"level":"info","ts":1609812301.484679,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"[INFO] Stopping nebula-metad...\n[INFO] Done\n"}
{"level":"info","ts":1609812301.5019202,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"[INFO] Stopping nebula-storaged...\n[INFO] Done\n"}
{"level":"info","ts":1609812302.1988132,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"rm -rf /bdp/nebula2a/data/meta/nebula && mkdir -p /bdp/nebula2a/data/meta/nebula","user":"root"}
{"level":"info","ts":1609812302.199632,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"rm -rf /bdp/nebula2a/data/storage/nebula && mkdir -p /bdp/nebula2a/data/storage/nebula","user":"root"}
{"level":"info","ts":1609812302.2081704,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812302.2086444,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812302.2087433,"caller":"restore/restore.go:134","msg":"download","ip":"192.168.96.96:9779","storage":"192.168.96.96:9779"}
{"level":"info","ts":1609812302.8588479,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cp -rf /bdp/store/1/BACKUP_2021_01_04_15_41_50/storage/192.168.96.96:9779/2  /bdp/nebula2a/data/storage/nebula","user":"root"}
{"level":"info","ts":1609812302.864976,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812302.888807,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cp -rf /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__tags__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__parts__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__edges__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__spaces__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__configs__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__users__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__index__.sst  /bdp/nebula2a/data/meta","user":"root"}
{"level":"info","ts":1609812302.8946345,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812303.5468817,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service start metad &>/dev/null &","user":"root"}
{"level":"info","ts":1609812303.601369,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812306.601594,"caller":"restore/restore.go:202","msg":"restoreMeta"}
{"level":"info","ts":1609812306.601657,"caller":"restore/restore.go:222","msg":"will restore meta","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812306.6016912,"caller":"metaclient/meta.go:45","msg":"start open meta","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812306.69836,"caller":"restore/restore.go:196","msg":"restore succeeded","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812307.3897452,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service start storaged &>/dev/null &","user":"root"}
{"level":"info","ts":1609812307.447032,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812307.4471204,"caller":"restore/restore.go:387","msg":"restore meta successed"}
[root@w540 br]# ./bin/br restore full --config "/bdp/nebula-storage/util/br/restore_example.yaml"
{"level":"info","ts":1609812620.5656583,"caller":"cmd/validate.go:33","msg":"checking ssh","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812621.2610388,"caller":"storage/storage.go:31","msg":"parsed external storage","schema":"local","path":"/bdp/store/1"}
{"level":"info","ts":1609812621.945749,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"ls /bdp/store/1/BACKUP_2021_01_04_15_41_50","user":"root"}
{"level":"info","ts":1609812621.9466693,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"ls /bdp/store/1/BACKUP_2021_01_04_15_41_50","user":"root"}
{"level":"info","ts":1609812621.9513764,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"meta\nstorage\n"}
{"level":"info","ts":1609812621.9521048,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"meta\nstorage\n"}
{"level":"info","ts":1609812621.952138,"caller":"restore/restore.go:74","msg":"download metafile","cmd":["cp","/bdp/store/1/BACKUP_2021_01_04_15_41_50/BACKUP_2021_01_04_15_41_50.meta","/tmp/"]}
{"level":"info","ts":1609812622.6538396,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service stop metad","user":"root"}
{"level":"info","ts":1609812622.657724,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service stop storaged","user":"root"}
{"level":"info","ts":1609812622.6953456,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"[INFO] Stopping nebula-metad...\n[INFO] Done\n"}
{"level":"info","ts":1609812622.6980357,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"[INFO] Stopping nebula-storaged...\n[INFO] Done\n"}
{"level":"info","ts":1609812623.3417807,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"rm -rf /bdp/nebula2a/data/meta/nebula && mkdir -p /bdp/nebula2a/data/meta/nebula","user":"root"}
{"level":"info","ts":1609812623.3496106,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812623.3927145,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"rm -rf /bdp/nebula2a/data/storage/nebula && mkdir -p /bdp/nebula2a/data/storage/nebula","user":"root"}
{"level":"info","ts":1609812623.4001293,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812623.400272,"caller":"restore/restore.go:134","msg":"download","ip":"192.168.96.96:9779","storage":"192.168.96.96:9779"}
{"level":"info","ts":1609812624.0718265,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cp -rf /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__tags__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__parts__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__edges__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__spaces__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__configs__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__users__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__index__.sst  /bdp/nebula2a/data/meta","user":"root"}
{"level":"info","ts":1609812624.07784,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812624.0977654,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cp -rf /bdp/store/1/BACKUP_2021_01_04_15_41_50/storage/192.168.96.96:9779/2  /bdp/nebula2a/data/storage/nebula","user":"root"}
{"level":"info","ts":1609812624.1038244,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812624.7636588,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service start metad &>/dev/null &","user":"root"}
{"level":"info","ts":1609812624.822099,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812627.8223186,"caller":"restore/restore.go:202","msg":"restoreMeta"}
{"level":"info","ts":1609812627.8223805,"caller":"restore/restore.go:222","msg":"will restore meta","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812627.8224342,"caller":"metaclient/meta.go:45","msg":"start open meta","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812627.9198298,"caller":"restore/restore.go:196","msg":"restore succeeded","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812628.6288114,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service start storaged &>/dev/null &","user":"root"}
{"level":"info","ts":1609812628.684087,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812628.6841218,"caller":"restore/restore.go:387","msg":"restore meta successed"}
[root@w540 br]# ./bin/br restore full --config "/bdp/nebula-storage/util/br/restore_example.yaml"
{"level":"info","ts":1609812717.0944374,"caller":"cmd/validate.go:33","msg":"checking ssh","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812717.7927878,"caller":"storage/storage.go:31","msg":"parsed external storage","schema":"local","path":"/bdp/store/1"}
{"level":"info","ts":1609812718.4778388,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"ls /bdp/store/1/BACKUP_2021_01_04_15_41_50","user":"root"}
{"level":"info","ts":1609812718.4832888,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"meta\nstorage\n"}
{"level":"info","ts":1609812718.4835353,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"ls /bdp/store/1/BACKUP_2021_01_04_15_41_50","user":"root"}
{"level":"info","ts":1609812718.4887514,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"meta\nstorage\n"}
{"level":"info","ts":1609812718.4887872,"caller":"restore/restore.go:74","msg":"download metafile","cmd":["cp","/bdp/store/1/BACKUP_2021_01_04_15_41_50/BACKUP_2021_01_04_15_41_50.meta","/tmp/"]}
{"level":"info","ts":1609812719.1838658,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service stop metad","user":"root"}
{"level":"info","ts":1609812719.1876397,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service stop storaged","user":"root"}
{"level":"info","ts":1609812719.223257,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"[INFO] Stopping nebula-metad...\n[INFO] Done\n"}
{"level":"info","ts":1609812719.229569,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":"[INFO] Stopping nebula-storaged...\n[INFO] Done\n"}
{"level":"info","ts":1609812719.8647532,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"rm -rf /bdp/nebula2a/data/meta/nebula && mkdir -p /bdp/nebula2a/data/meta/nebula","user":"root"}
{"level":"info","ts":1609812719.8720145,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812719.893792,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"rm -rf /bdp/nebula2a/data/storage/nebula && mkdir -p /bdp/nebula2a/data/storage/nebula","user":"root"}
{"level":"info","ts":1609812719.900308,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812719.9004512,"caller":"restore/restore.go:134","msg":"download","ip":"192.168.96.96:9779","storage":"192.168.96.96:9779"}
{"level":"info","ts":1609812720.5958445,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cp -rf /bdp/store/1/BACKUP_2021_01_04_15_41_50/storage/192.168.96.96:9779/2  /bdp/nebula2a/data/storage/nebula","user":"root"}
{"level":"info","ts":1609812720.5958445,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cp -rf /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__tags__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__parts__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__edges__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__spaces__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__configs__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__users__.sst /bdp/store/1/BACKUP_2021_01_04_15_41_50/meta/__index__.sst  /bdp/nebula2a/data/meta","user":"root"}
{"level":"info","ts":1609812720.602166,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812720.6023831,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812721.2748141,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service start metad &>/dev/null &","user":"root"}
{"level":"info","ts":1609812721.326476,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812724.32671,"caller":"restore/restore.go:202","msg":"restoreMeta"}
{"level":"info","ts":1609812724.3267767,"caller":"restore/restore.go:222","msg":"will restore meta","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812724.3268266,"caller":"metaclient/meta.go:45","msg":"start open meta","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812724.4218354,"caller":"restore/restore.go:196","msg":"restore succeeded","addr":"192.168.96.96:9559"}
{"level":"info","ts":1609812725.0968437,"caller":"ssh/ssh.go:57","msg":"ssh will exec","addr":"192.168.96.96","cmd":"cd /bdp/nebula2a/ && scripts/nebula.service start storaged &>/dev/null &","user":"root"}
{"level":"info","ts":1609812725.1543677,"caller":"ssh/ssh.go:66","msg":"Command execution completed","result":""}
{"level":"info","ts":1609812725.1544354,"caller":"restore/restore.go:387","msg":"restore meta successed"}

4、使用nba空间,提示找不到空间。
image

你好,这里graph和meta之间会有个同步时间差,这里建议您可以重启下graph.

有时候备份恢复成功后,出现类似下面的错误

你意思是这里show stats统计有错误是吧? 这里是个bug,已经在这个commit修复(https://github.com/vesoft-inc/nebula-storage/commit/258909bdb50b7b025e1c43bfa3d6a30862f39289) ,后续版本就会有这个修复了 。

1赞

浙ICP备20010487号