Perform an uninstallation#
Introduction#
The following instructions describe how to perform an uninstallation of Aspen Mesh. Perform the tasks in order.
When to perform an uninstallation#
Perform an uninstallation when either of the following is true:
You no longer want to use Aspen Mesh on your cluster.
You want to temporarily uninstall Aspen Mesh so you can perform a clean installation.
You don’t need to perform an uninstallation if you want to perform an upgrade.
Uninstall the control plane and gateway components#
Did you previously install the Istio egress gateway?
Yes:
Uninstall the Istio egress gateway:
$ helm uninstall istio-egress --namespace <egressNamespaceName>
Go to step 2.
No:
Go to step 2.
Uninstall the Istio ingress gateway:
$ helm uninstall istio-ingress --namespace <ingressNamespaceName>
Uninstall the Istio control plane:
$ helm uninstall istiod --namespace istio-system
(OpenShift only) Uninstall the Istio CNI plugin#
Important
Perform this task only if Aspen Mesh is installed in an OpenShift cluster.
In each namespace that has an
istio-cninetwork-attachment definition, delete theistio-cninetwork-attachment definition:$ kubectl delete network-attachment-definition istio-cni --namespace <namespaceName>
In each namespace in which both the
anyuidandprivilegedsecurity context constraints (SCCs) were added to all service accounts to allow sidecar injection (this excludes theistio-systemnamespace), remove those SCCs:$ oc adm policy remove-scc-from-group anyuid "system:serviceaccounts:<namespaceName>" $ oc adm policy remove-scc-from-group privileged "system:serviceaccounts:<namespaceName>"
In the
istio-systemnamespace, remove theanyuidSCC:$ oc adm policy remove-scc-from-group anyuid "system:serviceaccounts:istio-system"
Uninstall the Istio CNI plugin:
$ helm uninstall istio-cni --namespace kube-system
Uninstall the control-plane dependencies#
Uninstall the cluster-wide objects used by the Istio control plane in the
istio-systemnamespace:$ helm uninstall istio-base --namespace istio-system
Delete the
istio-systemnamespace:$ kubectl delete namespace istio-system
Note
If you previously plugged in CA certificates, deleting the
istio-systemnamespace will delete thecacertscertificate secret in theistio-systemnamespace.
Delete the Istio CRDs#
List all remaining custom Istio objects:
$ kubectl get istio-io --all-namespaces
Note
At this point, all custom Istio objects (objects based on the Istio CRDs) that were created during a clean installation or an upgrade of Aspen Mesh have already been deleted. Therefore, this command lists only any custom Istio objects that were not created during a clean installation or an upgrade of Aspen Mesh.
Are there any remaining custom Istio objects?
Yes:
If there’s a possibility you’ll need to re-create these remaining custom Istio objects later (for example, after performing a clean installation of Aspen Mesh), make sure you have a manifest for each one.
Go to step 3.
No:
Go to step 3.
Delete the Istio CRDs:
$ kubectl get crds --output name | grep 'istio.io' | xargs kubectl delete
Note
Helm does not delete or upgrade CRDs. If you don’t delete the Istio CRDs and then later perform a clean installation of Aspen Mesh, the clean installation will not upgrade (or downgrade) the versions of the Istio CRDs.