This section describes uninstallation procedures for Eclipse Che installed on OpenShift. The uninstallation process leads to a complete removal of Che-related user data. The appropriate uninstallation method depends on what method was used to install the Che instance.

Uninstalling Che after OperatorHub installation

Users have two options for uninstalling Che from an OpenShift cluster. The following sections describe both of these methods:

  • Using the OpenShift Administrator Perspective web UI

  • Using oc commands from the terminal

Uninstalling Che using the OpenShift web console

This section describes how to uninstall Che from a cluster using the OpenShift Administrator Perspective main menu.

Prerequsities
  • Che was installed on an OpenShift cluster using OperatorHub.

Procedure: deleting the Che deployment
  1. Open the OpenShift web console.

  2. Navigate to the Operators > Installed Operators section.

  3. Click Eclipse Che in the list of installed operators.

  4. Navigate to the Eclipse Che Cluster tab.

  5. In the row that displays information about the specific Che cluster, delete the Che Cluster deployment using the drop-down menu illustrated as three horizontal dots () situated on the right side of the screen.

  6. Alternatively, delete the Che deployment by clicking the displayed Eclipse Che Cluster, eclipse-che, and select the Delete cluster option in the Actions drop-down menu on the top right.

Procedure: deleting the Che Operator
  1. Open the OpenShift web console.

  2. Navigate to the Operators > Installed Operators section in OpenShift Developer Perspective.

  3. In the row that displays information about the specific Eclipse Che Operator, uninstall the Che Operator using the drop-down menu illustrated as three horizontal dots () situated on the right side of the screen.

  4. Accept the selected option, Also completely remove the Operator from the selected namespace.

  5. Alternatively, uninstall the Eclipse Che Operator by clicking the displayed Eclipse Che Operator, Eclipse Che, followed by selecting the Uninstall Operator option in the Actions drop-down menu on the top right.

Uninstalling Che using oc commands

This section provides instructions on how to uninstall a Che instance using oc commands.

Prerequisites
  • Che was installed on an OpenShift cluster using OperatorHub.

  • OpenShift command-line tools (oc) are installed on the local workstation.

Procedure

The following procedure provides command-line outputs as examples. Note that output in the user terminal may differ.

To uninstall a Che instance from a cluster:

  1. Sign in to the cluster:

    $ oc login -u <username> -p <password> <cluster_URL>
  2. Switch to the project where the Che instance is deployed:

    $ oc project <che_project>
  3. Obtain the Che cluster name. The following shows a cluster named eclipse-che:

    $ oc get checluster
    NAME          AGE
    eclipse-che   27m
  4. Delete the Che cluster:

    $ oc delete checluster eclipse-che
    checluster.org.eclipse.che "eclipse-che" deleted
  5. Obtain the name of the Che cluster service version (CSV) module. The following detects a CSV module named eclipse-che.v7.3.0:

    $ oc get csv
    NAME                 DISPLAY       VERSION   REPLACES             PHASE
    eclipse-che.v7.3.0   Eclipse Che   7.3.0     eclipse-che.v6.x.0   Succeeded
  6. Delete the Che CSV:

    $ oc delete csv eclipse-che.v7.3.0
    clusterserviceversion.operators.coreos.com "eclipse-che.v7.3.0" deleted

Uninstalling Che after chectl installation

This section describes how to uninstall an instance of Eclipse Che that was installed using the chectl tool.

  • For Che installed using the chectl server:start command and the -n argument (custom namespace specified), use the -n argument also to uninstall the Che instance.

  • For installations that did not use the -n argument, the created namespace is named che by default.

Prerequisites
  • Che was installed on an OpenShift cluster using chectl.

  • OpenShift command-line tools (oc) and chectl are installed on the local workstation.

  • The user is logged in a Che cluster using oc.

Procedure
  1. Stop the Eclipse Che Server:

    $ chectl server:stop
  2. Obtain the name of the Che namespace:

    $ oc get checluster --all-namespaces -o=jsonpath="{.items[*].metadata.namespace}"
  3. Remove Che from the cluster:

    $ chectl server:delete -n <namespace>

    This removes all Che installations from the cluster.

Tags: