Skip to main content
Loading
Version: Operator 3.3.1

Uninstall the Aerospike Kubernetes Operator

Overview

This page explains how to uninstall the Aerospike Kubernetes Operator (AKO) from your cluster, including the cleanup of Custom Resource Definitions (CRDs), Custom Resources (CRs) and Role-Based Access Control (RBAC) resources.

Run the following commands to find the names of resources in your deployment. Replace NAMESPACE with the name of your namespace.

# List subscriptions
kubectl get subscription -n NAMESPACE | grep aerospike

# List CSVs
kubectl get csv -n NAMESPACE | grep aerospike

# List Helm releases
helm list -n NAMESPACE | grep aerospike

This section describes how to remove the AerospikeCluster CRs, CRDs and all related resources, including Aerospike cluster data. Skip this step for uninstalling only the AKO. Uninstall AKO.

  1. Remove the CRDs created by the AKO. This step automatically deletes the corresponding AerospikeCluster CR files in the Kubernetes cluster.

    kubectl delete crd aerospikeclusters.asdb.aerospike.com
  2. Remove serviceaccount.

    kubectl -n NAMESPACE delete serviceaccount aerospike-operator-controller-manager
  3. Use one of the following commands to remove rolebinding or clusterrolebinding depending on which binding was created.

    note

    Not all AKO deployments include the same bindings. This step may not apply to your deployment.

    kubectl -n NAMESPACE delete rolebinding AEROSPIKE_CLUSTER
    kubectl delete clusterrolebinding AEROSPIKE_CLUSTER
  4. Remove ClusterRole.

    kubectl delete clusterrole aerospike-cluster

Uninstall AKO

This section describes how to uninstall the AKO.

OLM-based uninstall

If the AKO was installed with OLM, run the following commands.

  1. Delete subscription.

    kubectl delete subscription SUBSCRIPTION -n NAMESPACE
  2. Delete CSV.

    kubectl delete csv CSV -n NAMESPACE

Helm-based uninstall

If the AKO was installed using Helm, uninstall it with the following command.

helm uninstall RELEASE -n NAMESPACE