Purpose
You can use this statement to cancel an ongoing backup cleanup job.
If you want to only cancel an ongoing backup cleanup job, you can execute the CANCEL DELETE BACKUP statement. If you want to cancel an ongoing backup cleanup job and make sure that it will not be scheduled again, you must execute the DROP DELETE BACKUP POLICY statement to drop the backup cleanup strategy and then execute the CANCEL DELETE BACKUP statement to cancel the job. For more information about the DROP DELETE BACKUP POLICY statement, see DELETE BACKUP POLICY.
Required privileges
Only the root user of the sys tenant (root@sys) or the administrator user of a user tenant can execute this statement.
- The default administrator user in MySQL mode is
root. - The default administrator user in Oracle mode is
SYS.
Syntax
ALTER SYSTEM CANCEL DELETE BACKUP [TENANT [=] {tenant_name[, tenant_name]...} ];
Parameters
| Parameter | Description |
|---|---|
| tenant_name | The name of the tenant for which you want to cancel the ongoing backup cleanup job. This parameter is used in the sys tenant. If you specify multiple tenants, separate the tenant names with commas (,). If you do not specify this parameter in the sys tenant, the ongoing backup cleanup jobs of all user tenants are canceled.
NoticeWhen you execute this statement in the |
Examples
In the
systenant, drop the cleanup strategydefaultfor themysql_tenanttenant.obclient [oceanbase]> ALTER SYSTEM DROP DELETE BACKUP POLICY 'default' TENANT = mysql_tenant;In the
systenant, cancel the ongoing backup cleanup jobs of themysql_tenantandoracle_tenanttenants.obclient [oceanbase]> ALTER SYSTEM CANCEL DELETE BACKUP TENANT mysql_tenant, oracle_tenant;In the
oracle_tenanttenant, cancel the ongoing backup cleanup job of the current tenant.obclient [SYS]> ALTER SYSTEM CANCEL DELETE BACKUP;