| Summary: | [DOCS] document manual reclaiming of persistent volumes | ||
|---|---|---|---|
| Product: | OpenShift Container Platform | Reporter: | Evgheni Dereveanchin <ederevea> |
| Component: | Documentation | Assignee: | Traci Morrison <tmorriso> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Qin Ping <piqin> |
| Severity: | low | Docs Contact: | Vikram Goyal <vigoyal> |
| Priority: | unspecified | ||
| Version: | 3.1.0 | CC: | aos-bugs, bchilds, dmoessne, ederevea, jokerman, mmccomas, piqin |
| Target Milestone: | --- | Flags: | dmoessne:
needinfo?
(bchilds) |
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| URL: | https://access.redhat.com/documentation/en/openshift-enterprise/version-3.1/installation-and-configuration/#nfs-reclaiming-resources | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2018-03-06 18:49:21 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
|
Description
Evgheni Dereveanchin
2016-03-10 14:47:52 UTC
@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:
apiVersion: v1
kind: PersistentVolume
metadata:
name: nfs1
spec:
capacity:
storage: 1Mi
accessModes:
- ReadWriteMany
nfs:
server: 192.168.1.1
path: "/"
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:
apiVersion: v1
kind: PersistentVolume
metadata:
name: nfs2
spec:
capacity:
storage: 1Mi
accessModes:
- ReadWriteMany
nfs:
server: 192.168.1.1
path: "/"
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. https://github.com/openshift/openshift-docs/pull/7179 Links to updated content: 3.1: https://docs.openshift.com/enterprise/3.1/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources 3.2: https://docs.openshift.com/enterprise/3.2/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources 3.3: https://docs.openshift.com/container-platform/3.3/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources 3.4: https://docs.openshift.com/container-platform/3.4/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources 3.5: https://docs.openshift.com/container-platform/3.5/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources 3.6: https://docs.openshift.com/container-platform/3.6/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources 3.7: https://docs.openshift.com/container-platform/3.7/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources 3.9: https://docs.openshift.com/container-platform/3.9/install_config/persistent_storage/persistent_storage_nfs.html#nfs-reclaiming-resources |