Installing the IBM PowerVC Container Storage Interface driver on OpenShift Container Platform
Container Storage Interface driver (CSI) is a standard for providing storage functions to containers. PowerVC CSI pluggable driver interacts with PowerVC storage for operations such as create volumes, delete volumes, attach, or detach volumes.
- Node plug-in
- Controller plug-in
The Node plug-in is deployed as a DaemonSet and runs on the node where the volumes are
provisioned and consumed (worker node where application pods run). Controller plug-in provides the
functionality of volume management outside of worker node provision. This plug-in implements the CSI
controller service and sidecar containers like
external-attacher. External provisioner triggers create or delete volume operations
based on Persistent Volume Claims (PVC). External attacher watches volume attachment objects and
triggers volume attach (publish) or detach (unpublish) operations.
- OpenShift environment on top of PowerVC based IBM Power infrastructure with storage registered.
- Red Hat® OpenShift Container Platform version 4.11.0. See OCP life cycle dates before configuring.
Installing or configuring PowerVC CSI driver on Red Hat OpenShift Container Platform
Configure PowerVC CSI driver on Red Hat OpenShift Container Platform by using these steps:
Download these files from GitHub location:
List nodes and ensure that they are working.
# oc get nodes
Create a project.
oc create namespace <my-project-name>Switch to the project.
oc project <my-project-name>
- Add cluster roles for the
project admininstrator.Run this command to provide access to system service account for
oc adm policy add-cluster-role-to-user cluster-admin system:serviceaccount:openshift-infra:template-instance-controllerRun this command to provide access to system service account for
oc adm policy add-cluster-role-to-user cluster-admin system:serviceaccount:<projectname>:default
- Apply Security Context Constraints (SCC) template. Run oc apply -f <directory path>/scc.yaml to apply changes.
- Apply the following changes to template file:
OPENSTACK_CERT_DATA, add attribute value: "". Copy and paste the contents of
powervc.crtfile between the quotation marks.
DRIVER_VOLUME_TYPE, add attribute value: "". Enter the name or UUID of the storage template between the quotation marks.To apply changes, run:
oc apply -f <directory path>/ibm-powervc-csi-driver-template.yaml
secretfile with your PowerVC username and password encrypted in base 64 format.Use the following command to get base64 encrypted format:
base64 <<< <enter-your-powervc-username>
base64 <<< <enter-your-powervc-password>Use the following command to apply this secret file into OpenShift:
oc apply -f <directory path>/secret.yaml
- Validate using oc process --parameters ibm-powervc-csi command and make sure all the parameters and default values are returned.
- Process the template file.
- Run oc process ibm-powervc-csi -p OPENSTACK_IP_OR_HOSTNAME=<ip or hostname> -p OPENSTACK_CRED_SECRET_NAME=my-secret > <a>.yaml command to create <a>.yaml consisting of all artifacts.
- Use PowerVC IP address and the
secret that you created in step 7 in case you already renamed it from
- Install all OpenShift artifacts.
# oc apply -f a.yaml
- Run the following command and wait until all CSI nodes are published.
# oc get csinodes
The list must at least show the worker node.
- Run commands such as oc get pods, oc logs <plugin> -c <container> to ensure that there are no errors in the output.