This topic describes how to view the full restoration progress and results in database tables.
View the restoration progress and results in database tables
After the restoration starts, run the following commands to view the restoration progress:
View the restoration progress of the root table
obclient> SELECT svr_ip,role, is_restore, COUNT(*) FROM __all_root_table as a, (SELECT value FROM __all_restore_info WHERE name='<target tenant name>') AS b WHERE a.tenant_id=b.value GROUP BY role, is_restore, svr_ip ORDER BY svr_ip, is_restore;View the restoration progress of the meta table
obclient> SELECT svr_ip,role, is_restore, COUNT(*) FROM __all_virtual_meta_table AS a, (SELECT value FROM __all_restore_info WHERE name='<target tenant name>') AS b WHERE a.tenant_id=b.value GROUP BY role, is_restore, svr_ip ORDER BY svr_ip, is_restore;or
obclient> SELECT svr_ip, is_restore, COUNT(*) FROM __all_virtual_partition_store_info WHERE tenant_id=<target tenant ID> GROUP BY svr_ip,is_restore ORDER BY svr_ip, is_restore;In the view:
is_restoreindicates the restoration status of a partition. When the value is0, the data in the partition has been restored.roleindicates the role of the restored replica:1: indicates a leader.
2: indicates a follower.
3: indicates a leader in restoration.
After the restoration is completed, run the following commands to view the restoration results and history:
View the restoration results
obclient> SELECT * FROM __all_restore_info;View the restoration history
obclient> SELECT * FROM __all_restore_history;