Skip to main content
Version: release-0.9

Delete an ApeCloud MySQL Cluster

Termination policy

note

The termination policy determines how a cluster is deleted.

terminationPolicyDeleting Operation
DoNotTerminateDoNotTerminate blocks delete operation.
HaltHalt deletes Cluster resources like Pods and Services but retains Persistent Volume Claims (PVCs), allowing for data preservation while stopping other operations. Halt policy is deprecated in v0.9.1 and will have same meaning as DoNotTerminate.
DeleteDelete extends the Halt policy by also removing PVCs, leading to a thorough cleanup while removing all persistent data.
WipeOutWipeOut deletes all Cluster resources, including volume snapshots and backups in external storage. This results in complete data removal and should be used cautiously, especially in non-production environments, to avoid irreversible data loss.

To check the termination policy, execute the following command.

kbcli cluster list -n demo
>
NAME NAMESPACE CLUSTER-DEFINITION VERSION TERMINATION-POLICY STATUS CREATED-TIME
mycluster demo apecloud-mysql ac-mysql-8.0.30 Delete Running Sep 19,2024 16:01 UTC+0800

Step

Run the command below to delete a specified cluster.

kbcli cluster delete mycluster -n demo