Deleting a cluster network
Contact your IBM Support representative if you are interested in getting early access to this offering. It is currently available for early access users of the gx3d-160x1792x8h100
virtual server instance profiles in the us-east
region.
You can delete a cluster network interface after all instances attached to it are deleted.
Before you begin
Review Planning considerations and Known issues and limitations.
You can delete a cluster network with the UI, CLI, API, or Terraform.
Deleting a cluster network in the UI
To delete a cluster network in the IBM Cloud console, follow these steps:
-
From your browser, open the IBM Cloud console and log in to your account.
-
Select the Navigation Menu , then click Infrastructure > Cluster networks.
-
In the Cluster networks for VPC table, locate the cluster network interface that you want to delete, then click Delete in the Actions menu .
Alternatively, you can Delete a cluster network from the Actions menu on the cluster network's details page.
Deleting a cluster network in the CLI
To delete a cluster network in the CLI, follow these steps:
-
Log in to your account with the CLI. After you enter the password, the system prompts for the account and region that you want to use:
ibmcloud login --sso
-
Enable the following feature flag:
export IBMCLOUD_IS_FEATURE_CLUSTER_NETWORK=true
-
To delete one or more cluster networks, enter the following command:
ibmcloud is cluster-network-delete (CLUSTER_NETWORK1 CLUSTER_NETWORK2...) [--output JSON] [-f, --force] [-q, --quiet]
Where:
CLUSTER_NETWORK1 CLUSTER_NETWORK2
- IDs or names of the cluster networks, separated by a space.
-output
- Specify output format, only JSON is supported. One of:
JSON
. -force, -f
- Force the operation without confirmation.
-q, --quiet
- Suppress verbose output.
Command example
To delete cluster network cli-cn-1
. You are prompted for confirmation. This action cannot be undone.
ibmcloud is cluster-network-delete cli-cn-1
Deleting a cluster network with the API
To delete a cluster network with the API, follow these steps:
-
Set up your API environment with the right variables.
-
Store any additional variables to be used in the API commands; for example:
version
(string): The API version, in formatYYYY-MM-DD
. -
When all variables are initiated, run the following command delete the cluster network:
curl -X DELETE "$vpc_api_endpoint/v1/cluster_networks/$cluster_network_id?version=$tomorrow&generation=2&maturity=development" -H "Authorization: Bearer $iam_token"
To view the complete set of cluster network APIs, see the VPC API reference.
Deleting a cluster network with Terraform
Terraform will support this feature after it reaches General Availability (GA) and is officially released.
Use the terraform destroy
command to delete a cluster network. The following example deletes ibm_is_cluster_network
.
terraform destroy --target ibm_is_cluster_network
You can also delete a resource that was created with a .tf file. For example, if you created a cluster with the following .tf file (terraform apply -auto-approve
), you can delete it using terraform destroy auto-approve
.
// Provision is_cluster_network resource instance
resource "ibm_is_cluster_network" "is_cluster_network_instance" {
name = var.is_cluster_network_name // change to update
profile = "h100"
resource_group = "fee82deba12e4c0fb69c3b09d1f12345"
subnet_prefixes {
cidr = "10.0.0.0/24"
}
vpc = "r006-4727d842-f94f-4a2d-824a-9bc9b02c523b"
zone = "us-south-1"
}