Upgrade Portworx on Kubernetes using the Operator
If you’re using the Portworx Operator, you can upgrade or change your Portworx version at any time by modifying the StorageCluster
spec.
Prerequisites
- You must already be running Portworx through the Operator, this method will not work for other Portworx deployments
Upgrade Portworx
Enter the
kubectl edit
command to modify your storage cluster:kubectl edit -n kube-system <storagecluster_name>
Change the
spec.image
value to the version you want to update Portworx to:apiVersion: core.libopenstorage.org/v1 kind: StorageCluster metadata: name: portworx namespace: kube-system spec: image: portworx/oci-monitor:<your_desired_version>
Upgrade Portworx components
In addition to managing a Portworx cluster, the Operator also manages the following other components in the Portworx platform:
- Stork
- Autopilot
- Lighthouse
For simplicity, the Portworx Operator handles the component upgrades without user intervention. When Portworx upgrades, the Operator upgrades the installed components to the recommended version as well.
The Portworx Operator refers to the release manifest to determine which recommended component version to install for a given Portworx version. This release manifest is regularly updated for every Portworx release.
Force upgrade Stork
To override the operator selected Stork image, edit the StorageCluster
object and
modify the spec.stork.image
field, entering your desired Stork version
apiVersion: core.libopenstorage.org/v1
kind: StorageCluster
metadata:
name: portworx
namespace: kube-system
spec:
stork:
enabled: true
image: openstorage/stork:<your_desired_stork_version>
Force upgrade Autopilot
To override the operator selected Autopilot image, edit the StorageCluster
object and
modify the spec.autopilot.image
field, entering your desired Autopilot version
apiVersion: core.libopenstorage.org/v1
kind: StorageCluster
metadata:
name: portworx
namespace: kube-system
spec:
autopilot:
enabled: true
image: portworx/autopilot:<your_desired_autopilot_version>
Force upgrade Lighthouse
To override the operator selected Lighthouse image, edit the StorageCluster
object and
modify the spec.userInterface.image
field, entering your desired Lighthouse version
apiVersion: core.libopenstorage.org/v1
kind: StorageCluster
metadata:
name: portworx
namespace: kube-system
spec:
userInterface:
enabled: true
image: portworx/px-lighthouse:<your_desired_lighthouse_version>