LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1485|回复: 0

OceanBase数据库

[复制链接]
发表于 2024-1-5 22:42:08 | 显示全部楼层 |阅读模式
原理介绍:

https://www.oceanbase.com/docs/e ... n-10000000000355061

OceanBase 数据库物理备份的架构如下图所示





备份示例:

https://www.oceanbase.com/docs/e ... n-10000000000357859

# 发起全量备份

obclient> ALTER SYSTEM BACKUP DATABASE;

# 发起增量备份

obclient> ALTER SYSTEM BACKUP INCREMENTAL DATABASE;


恢复示例:

https://www.oceanbase.com/docs/e ... n-10000000000355919

# 全量恢复

obclient> ALTER SYSTEM RESTORE <dest_tenant_name> FROM <source_tenant_name> at 'uri' UNTIL 'timestamp' WITH 'restore_option';

# 表级别恢复

obclient> ALTER SYSTEM RESTORE <table_name_list> FOR <dest_tenant_name>  FROM <source_tenant_name> AT 'uri'  UNTIL 'timestamp' WITH 'restore_option' ;
obclient> ALTER SYSTEM RESTORE `crm`.`sales`, `crm`.`products`, `hr`.`employees` FOR new_tenant1 FROM tenant1 AT 'oss://antsys-oceanbasebackup/backup_rd/?host=cn-hangzhou-alipay-b.oss-cdn.aliyun-inc.com&access_id=xxx&access_key=xxx' UNTIL '2021-02-28 08:59:45' WITH 'backup_cluster_name=ob20daily.backup&backup_cluster_id=1&pool_list=restore_pool';

# 查看正在备份的任务

obclient> SELECT * FROM oceanbase.CDB_OB_BACKUP_PROGRESS;

# 查看备份任务的历史

obclient> SELECT * FROM oceanbase.CDB_OB_BACKUP_SET_FILES;

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?注册

x
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表