Delete Persistent Volumes

This section explains how to delete a Persistent Volume.

The default reclaim policy for storage classes in KubeSphere is Delete, meaning that by default, the system automatically deletes the Persistent Volume after the Persistent Volume Claim is deleted. If you create a storage class with a reclaim policy of Retain using command-line tools, there may be situations where the Persistent Volume Claim is deleted, but the Persistent Volume is not. For more information, refer to the Kubernetes Documentation.

Warning

Deleting a Persistent Volume is irreversible, and the backend storage area corresponding to the Persistent Volume will also be deleted. Please proceed with caution to avoid data loss.

Prerequisites

  • You should join a cluster and have the Persistent Volume Claim Management permission within the cluster. For more information, refer to “Cluster Members” and “Cluster Roles”.

  • The status of the Persistent Volume is Available, Released, or Failed.

  • Please backup data in the backend storage area in advance to avoid data loss.

Steps

  1. Log in to the KubeSphere web console with a user who has the Persistent Volume Claim Management permission, and access your cluster.

  2. Click Storage > Persistent Volume Claims in the left navigation pane.

  3. On the Persistent Volume Claims page, click Persistent Volume to open the list of Persistent Volumes.

  4. Click more on the right of the Persistent Volume you want to delete, then choose Delete from the dropdown list.

  5. In the Delete Persistent Volume dialog, enter the name of the Persistent Volume, then click OK.