1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/installation-uninstall-clouds.adoc

75 lines
2.9 KiB
Plaintext

// Module included in the following assemblies:
//
// * installing/installing_aws/uninstalling-cluster-aws.adoc
// * installing/installing_azure/uninstalling-cluster-azure.adoc
// * installing/installing_azure/uninstalling-cluster-azure-stack-hub.adoc
// * installing/installing_gcp/uninstalling-cluster-gcp.adoc
// * installing/installing_osp/uninstalling-cluster-openstack.adoc
// * installing/installing_rhv/uninstalling-cluster-rhv.adoc
// * installing/installing_vmc/uninstalling-cluster-vmc.adoc
// * installing/installing_vsphere/uninstalling-cluster-vsphere-installer-provisioned.adoc
ifeval::["{context}" == "uninstalling-cluster-aws"]
:aws:
endif::[]
ifeval::["{context}" == "uninstalling-cluster-gcp"]
:gcp:
endif::[]
:_content-type: PROCEDURE
[id="installation-uninstall-clouds_{context}"]
= Removing a cluster that uses installer-provisioned infrastructure
You can remove a cluster that uses installer-provisioned infrastructure from your cloud.
ifdef::aws[]
[NOTE]
====
If you deployed your cluster to the AWS C2S Secret Region, the installation program does not support destroying the cluster; you must manually remove the cluster resources.
====
endif::aws[]
[NOTE]
====
After uninstallation, check your cloud provider for any resources not removed properly, especially with User Provisioned Infrastructure (UPI) clusters. There might be resources that the installer did not create or that the installer is unable to access.
ifdef::gcp[]
For example, some Google Cloud resources require link:https://cloud.google.com/iam/docs/overview#concepts_related_to_access_management[IAM permissions] in shared VPC host projects, or there might be unused link:https://cloud.google.com/sdk/gcloud/reference/compute/health-checks/delete[health checks that must be deleted].
endif::gcp[]
====
.Prerequisites
* Have a copy of the installation program that you used to deploy the cluster.
* Have the files that the installation program generated when you created your
cluster.
.Procedure
. From the directory that contains the installation program on the computer that you used to install the cluster, run the following command:
+
[source,terminal]
----
$ ./openshift-install destroy cluster \
--dir <installation_directory> --log-level info <1> <2>
----
<1> For `<installation_directory>`, specify the path to the directory that you
stored the installation files in.
<2> To view different details, specify `warn`, `debug`, or `error` instead of `info`.
+
[NOTE]
====
You must specify the directory that contains the cluster definition files for
your cluster. The installation program requires the `metadata.json` file in this
directory to delete the cluster.
====
. Optional: Delete the `<installation_directory>` directory and the
{product-title} installation program.
ifeval::["{context}" == "uninstalling-cluster-aws"]
:!aws:
endif::[]
ifeval::["{context}" == "uninstalling-cluster-gcp"]
:!gcp:
endif::[]