Skip to main content
Version: 3.1

Uninstall Portworx

If you're using the Portworx Operator, you can uninstall Portworx by adding a delete strategy to your StorageCluster object, then deleting it. When uninstalling, you may choose to either keep the the data on your drives, or wipe them completely:

  • Uninstall: will remove your cluster objects, Portworx systemctl service, /etc/pwx and /opt/pwx directories, and all traces of Portworx on the nodes. The drives will not be formatted and none the Portworx Metadata in the KVDB will be deleted. You may need to Uninstall Portworx if you installed Portworx in the wrong namespace.
  • Uninstall and wipe: will remove all of the resources listed in the "Uninstall" procedure, and also removes (formats) all data from your disks permanently, including the Portworx metadata. You may want to perform an uninstall and wipe when you decommission a cluster.

Prerequisites

  • You must already be running Portworx through the Operator, this method will not work for other Portworx deployments

Uninstall Portworx

  1. Enter the oc get command to display the name of your Portworx storage cluster and specify your namespace:

    oc get -n portworx storagecluster <storagecluster-name>
  2. Enter the oc edit command to modify your storage cluster and specify your namespace:

    oc edit -n portworx storagecluster <storagecluster-name>
  3. Modify your StorageCluster object, adding the deleteStrategy field with either the Uninstall or UninstallAndWipe type:

    • Uninstall Portworx only:

      apiVersion: core.libopenstorage.org/v1
      kind: StorageCluster
      metadata:
      name: portworx
      namespace: portworx
      spec:
      deleteStrategy:
      type: Uninstall
    • Uninstall Portworx and wipe all drives:

      note

      Wipe operations remove all data from your disks permanently including the Portworx metadata, use caution when applying the DeleteStrategy spec.

      apiVersion: core.libopenstorage.org/v1
      kind: StorageCluster
      metadata:
      name: portworx
      namespace: portworx
      spec:
      deleteStrategy:
      type: UninstallAndWipe
  4. Enter the oc delete command, specifying the name of your StorageCluster object and specify your namespace:

    oc delete StorageCluster <your-storagecluster-name> -n portworx
    note

    This operation can take several minutes to complete.

  5. Delete the operator:

    oc delete deployment -n <namespace> portworx-operator
Was this page helpful?