Search

Chapter 8. Uninstalling Red Hat OpenShift Data Science self-managed

download PDF

This section shows how to use the OpenShift command-line interface (CLI) to uninstall the Red Hat OpenShift Data Science Operator and any OpenShift Data Science components installed and managed by the Operator.

Note

Using the CLI is the recommended way to uninstall the Operator. Depending on your version of OpenShift Container Platform, using the web console to perform the uninstallation might not prompt you to uninstall all associated components. This could leave your cluster in an unclear state.

8.1. Uninstalling Red Hat OpenShift Data Science self-managed by using the CLI

The following procedure shows how to use the OpenShift command-line interface (CLI) to uninstall the Red Hat OpenShift Data Science Operator and any OpenShift Data Science components installed and managed by the Operator.

Prerequisites

  • You have cluster administrator privileges for your OpenShift Container Platform cluster.
  • You have downloaded and installed the OpenShift command-line interface (CLI). See Installing the OpenShift CLI.
  • You have backed up the persistent disks or volumes used by your persistent volume claims (PVCs).

Procedure

  1. Open a new terminal window.
  2. In the OpenShift command-line interface (CLI), log in to your OpenShift Container Platform cluster as a cluster administrator, as shown in the following example:

    $ oc login <openshift_cluster_url> -u system:admin
  3. Create a ConfigMap object for deletion of the Red Hat OpenShift Data Science Operator.

    $ oc create configmap delete-self-managed-odh -n redhat-ods-operator
  4. To delete the rhods-operator, set the addon-managed-odh-delete label to true.

    $ oc label configmap/delete-self-managed-odh api.openshift.com/addon-managed-odh-delete=true -n redhat-ods-operator
  5. When all objects associated with the Operator are removed, delete the redhat-ods-operator project.

    1. Set an environment variable for the redhat-ods-applications project.

      $ PROJECT_NAME=redhat-ods-applications
    2. Wait until the redhat-ods-applications project has been deleted.

      $ while oc get project $PROJECT_NAME &> /dev/null; do
      echo "The $PROJECT_NAME project still exists"
      sleep 1
      done
      echo "The $PROJECT_NAME project no longer exists"

      When the redhat-ods-applications project has been deleted, you see the following output.

      The redhat-ods-applications project no longer exists
    3. When the redhat-ods-applications project has been deleted, delete the redhat-ods-operator project.

      $ oc delete namespace redhat-ods-operator

Verification

  • Confirm that the rhods-operator subscription no longer exists.

    $ oc get subscriptions --all-namespaces | grep rhods-operator
  • Confirm that the following projects no longer exist.

    • redhat-ods-applications
    • redhat-ods-monitoring
    • redhat-ods-operator
    • rhods-notebooks

      $ oc get namespaces | grep -e redhat-ods* -e rhods*
      Note

      The rhods-notebooks project was created only if you installed the workbenches component of OpenShift Data Science. See Installing and managing Red Hat OpenShift Data Science components.

Red Hat logoGithubRedditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.