I have a kubernetes cluster on the eks of aws. I use aws-ebs as the Provisioner of StorageClass, and the ReclaimPolicy is set to Retain. I install the application with helm. When I delete the application, the pvc is deleted, but the pv still exists. The status is Released. I can see that the aws-ebs volume is still in the aws console. Now I want to create a new application and still use the original data. I think there are two ways to do it
- Manually create a pvc to bind this pv to make pv work again, but the StorageClass cannot be used
- Re-create a new PV to bind aws-ebs and then create a new PVC through this PV, it seems that StorageClass cannot be used
But I don’t know how to change it, can I ask for help? thanks in advance
The ReclaimPolicy: Retain means that:
Here you can find an example showing step by step how to manually reuse a PV after PVC was deleted the way that the data will not be lost.