Volume Expansion

Expand the capacity of dynamically provisioned volumes to meet the growing storage needs of your environment.

To enable the expansion of a volume, you must set the allowVolumeExpansion parameter to true in the StorageClass.

Example of StorageClass:
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: ibm-spectrum-scale-csi-fileset-expansion
provisioner: spectrumscale.csi.ibm.com
parameters:
  volBackendFs: gpfs0
  clusterId: "17797813605352210071"
reclaimPolicy: Delete
allowVolumeExpansion: true
To expand volumes where volume expansion is enabled, edit the size of the PVC.
The following example illustrates how to use the patch command to expand a volume to 2Gi:
kubectl patch pvc scale-pvc  -p '{"spec":{"resources":{"requests":{"storage":"2Gi"}}}}'
If the volume is created using IBM Storage Scale Container Storage Interface driver 2.3.0 or earlier, the "allowVolumeExpansion" is unset in StorageClass. You must patch the storage class as given below, before PVC expansion.
kubectl patch storageclass ibm-spectrum-scale-csi-fileset  -p '{"allowVolumeExpansion": true}'
Available: Volume expansion is supported only for dynamically provisioned volumes (with or without consistency group).
Restriction: Volume shrinking is not supported.