-
Notifications
You must be signed in to change notification settings - Fork 1.9k
WIP: ocprhv-66-master new section for persistent storage CSI - RHV #28872
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
90 changes: 90 additions & 0 deletions
90
modules/persistent-storage-csi-ovirt-dynamic-provisioning.adoc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,90 @@ | ||
| // Module included in the following assemblies: | ||
| // | ||
| // * storage/container_storage_interface/persistent-storage-csi-rhv.adoc | ||
|
|
||
| [id="persistent-storage-csi-ovirt-dynamic-provisioning_{context}"] | ||
| = Dynamically provisioning {rh-virtualization} CSI volumes | ||
|
|
||
| {product-title} installs a StorageClass for each available oVirt share type. | ||
|
|
||
| The YAML files that are created are completely decoupled from {rh-virtualization} and from its Container Storage Interface (CSI) plug-in. | ||
| //As an application developer, you can dynamically provision ReadWriteMany (RWX) storage and deploy Pods with applications that safely consume the storage using YAML manifests. You can also provision other access modes, such as ReadWriteOnce (RWO). | ||
|
|
||
| You can use the same Pod and persistent volume claim (PVC) definitions on-premise that you use with {product-title} on AWS, GCP, Azure, and other platforms, with the exception of the storage class reference in the PVC definition. | ||
|
|
||
| .Prerequisites | ||
|
|
||
| * {rh-ATTRIBUTE?} is deployed with appropriate {rh-virtualization} share infrastructure so that it can be used to dynamically provision and mount volumes in {product-title}. | ||
|
|
||
| .Procedure (UI) | ||
|
|
||
| To dynamically create an {rh-virtualization} CSI volume using the web console: | ||
|
|
||
| . In the {product-title} console, click *Storage* → *Persistent Volume Claims*. | ||
|
|
||
| . In the persistent volume claims overview, click *Create Persistent Volume Claim*. | ||
|
|
||
| . Define the required options on the resulting page. | ||
|
|
||
| .. Select the appropriate StorageClass. | ||
|
|
||
| .. Enter a unique name for the storage claim. | ||
|
|
||
| .. Select the access mode to specify read and write access for the PVC you are creating. | ||
| + | ||
| [IMPORTANT] | ||
| ==== | ||
| // * Use RWO_?? if you want the persistent volume (PV) that fulfills this PVC to be mounted to multiple Pods on multiple nodes in the cluster. | ||
|
|
||
| * Use RWO mode if you want to prevent additional Pods from being dynamically provisioned. | ||
| ==== | ||
|
|
||
| . Define the size of the storage claim. | ||
|
|
||
| . Click *Create* to create the PersistentVolumeClaim and generate a PersistentVolume. | ||
|
|
||
| .Procedure (CLI) | ||
|
|
||
| To dynamically create a {rh-virtualization} CSI volume using the command-line interface (CLI): | ||
|
|
||
| . Create and save a file with the PersistentVolumeClaim object described by the following YAML: | ||
|
|
||
| + | ||
| .pvc-ovirt.yaml | ||
| [source,yaml] | ||
| ---- | ||
| apiVersion: v1 | ||
| kind: PersistentVolumeClaim | ||
| metadata: | ||
| name: pvc-ovirt | ||
| spec: | ||
| accessModes: <1> | ||
| - ReadWriteMany | ||
| resources: | ||
| requests: | ||
| storage: 10Gi | ||
| storageClassName: csi-ovirt-gold <2> | ||
| ---- | ||
| + | ||
| <1> Use ReadWriteOnce (RWO) mode to prevent additional Pods from being dynamically provisioned. | ||
| <2> The name of the storage class that provisions the storage back end. oVirt StorageClasses are provisioned by the Operator and have the `csi-ovirt-` prefix. | ||
| + | ||
| . Create the object you saved in the previous step by running the following command: | ||
| + | ||
| [source,terminal] | ||
| ---- | ||
| $ oc create -f pvc-ovirt.yaml | ||
| ---- | ||
| + | ||
| A new PVC is created. | ||
|
|
||
| . To verify that the volume was created and is ready, run the following command: | ||
| + | ||
| [source,terminal] | ||
| ---- | ||
| $ oc get pvc pvc-ovirt | ||
| ---- | ||
| + | ||
| The `pvc-ovirt` shows that it is `Bound`. | ||
|
|
||
| You can now use the new PVC to configure a Pod. | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does "oVirt share type" means ?
The storage class is created by the operator and its in the OCP cluster