Red Hat Bugzilla – Bug 1316593
[DOCS] document manual reclaiming of persistent volumes
Last modified: 2018-02-20 11:13:47 EST
Section Number and Name:
13.2. PERSISTENT STORAGE USING NFS
13.2.3. Reclaiming Resources
Describe the issue:
by default, persistent volumes are set to Retain, so after the PVC is removed the PV goes into a Released state. However there is no information on how to manually recycle the PV and mark it as Available
Suggestions for improvement:
document the steps to move a PV from Released back to the Available state.
this also needs to be covered for PV types other than NFS
@Traci - please liaise with the storage team to figure out:
1. How to do this for other storage types as well.
2. Whether the same steps apply to 3.1 + all versions. This is important to get right because the same steps may not apply in the new versions.
Brad, can you provide the note that we need to include for customers?
@Vikram - the team discussed this on the call today, and determined that we can include a note that applies to 3.1 + all versions. Once I have the note, I will edit the content and create a pull request.
@traci - The note should be something like:
"Once claim to a PV is released (ie. PVC deleted) the PV object should not be re-used. Instead, a new PV should be created with the same basic volume details as the original.
Example. Admin creates PV named nfs1:
User creates PVC1 which binds to nfs1. User then deletes PVC1 releasing claim to nfs1 causing nfs1 to show "Released" status. If the admin wishes to make the same NFS share available, she should create a new PV with the same NFS server details, but a different PV name:
Deleting the original PV and re-creating it with the same name is discouraged as bad practice. Attempting to manually change the status of a PV from Released to Available will cause errors and potential data loss.
Adding to my comment, we should also include a blurb about recycle:
"A PV with retention policy of Recycle will scrub (rm -rf) the data and mark it as Available.. The Recycle retention policy is deprecated in future versions and should be avoided..."
I believe we already mention the recycler deprecation in 3.6+ docs.
Thanks Traci and Bradley!
Work in progress: https://github.com/openshift/openshift-docs/pull/7179
Also, we need to be more specific when saying future versions:
"A PV with retention policy of `Recycle` will scrub (`rm -rf`) the data and mark it as `Available` for claim. The `Recycle` retention policy is deprecated in future versions and should be avoided."
Is it correct to say "The `Recycle` retention policy is deprecated after version 3.7."?
(In reply to Bradley Childs from comment #4)
> Deleting the original PV and re-creating it with the same name is
> discouraged as bad practice. Attempting to manually change the status of a
> PV from Released to Available will cause errors and potential data loss.
May I kindly ask why this is discouraged, are there any technical details against this, and what would be potential issues if still done ?
Hi Brad, can you follow up on Daniel's question? See Comment 9. Thanks.
Can you follow up on Daniel's question? See Comment 9. Thanks.
Add a comment in PR: https://github.com/openshift/openshift-docs/pull/7179 and still a comment is not fixed.
Changes made to the PR, please review.