Upgrade PX-CSI in Airgapped Clusters
In an internet-connected Kubernetes cluster, PX-CSI automatically fetches the necessary resources for installation. However, in an airgapped environment, you must manually pre-stage these resources to ensure a successful installation.
If you do not pre-stage the required resources before upgrading PX-CSI or Kubernetes in an airgapped cluster, your pods may enter crash loops, leading to service disruptions.
Follow this guide to download updated container images, pre-stage them within the airgapped cluster, and proceed with the PX-CSI upgrade.
Prerequisites
Ensure the following prerequisites are met:
-
Your Kubernetes cluster meets the Portworx system requirements.
-
All Portworx Pods are in a
Runningstate.Check the cluster status using the following command:
kubectl get pods -n <portworx>
Get updated container images
-
Set an environment variable for the Kubernetes version in use:
KBVER=$(kubectl version | awk -F'[v+_-]' '/Server/ {print $3}') -
Define an environment variable for the latest PX-CSI major version:
PXVER=<px-csi-version> # example: 25.8.0noteTo find the latest PX-CSI version, refer to the Portworx Release Notes.
-
On an internet-connected host with the same architecture and OS version as your Kubernetes nodes, download the airgapped installation bootstrap script:
curl -o px-ag-install.sh -L "https://install.portworx.com/$PXVER/air-gapped?kbver=$KBVER" -
Pull the container images required for the specified versions:
sh px-ag-install.sh pull -
Log in to your private container registry:
docker login <your-private-registry> -
Push the container images to the private registry. Do not include
http://in the registry path:sh px-ag-install.sh push <your-registry-path>Example:
sh px-ag-install.sh push myregistry.net:5443To push images to a specific repository (as defined in your
StorageCluster):sh px-ag-install.sh push myregistry.net:5443/px-images
Create a version manifest ConfigMap for PX-CSI
-
Download the PX-CSI version manifest:
curl -o versions.yaml "https://install.portworx.com/$PXVER/version?kbver=$KBVER" -
Update the
px-versionsConfigMap:kubectl -n <px-namespace> delete configmap px-versions
kubectl -n <px-namespace> create configmap px-versions --from-file=versions.yaml
Upgrade PX-CSI installation
Follow the instructions in the Upgrade Portworx CSI guide to update the PX-CSI StorageCluster specification.