This documentation is for the most recent version of Anthos clusters on Azure, released on August 29. See the Release notes for more information.
Stay organized with collections Save and categorize content based on your preferences.

Delete a node pool

This page shows you how to delete node pools in Anthos clusters on Azure.

Delete a node pool

To delete a node pool, run the following command:

  1. Get a list of your node pools:

    gcloud container azure node-pools list \
      --cluster CLUSTER_NAME \
      --location GOOGLE_CLOUD_LOCATION
    

    Replace the following:

    • CLUSTER_NAME: the name of the cluster that the node pool is attached to
    • GOOGLE_CLOUD_LOCATION: the Google Cloud location hosting the node pool
  2. For each of your node pools, delete it with the following command:

    gcloud container azure node-pools delete NODE_POOL_NAME \
       --cluster CLUSTER_NAME \
       --location GOOGLE_CLOUD_LOCATION
    

    Replace the following:

    • NODE_POOL_NAME: the name of the node pool to delete
    • CLUSTER_NAME
    • GOOGLE_CLOUD_LOCATION

How Anthos clusters on Azure protects workloads during node pool deletion

During node pool deletion, Anthos clusters on Azure performs graceful shut down on each node without honoring PodDisruptionBudget. It takes the following steps:

  1. Disable cluster autoscaler if it was enabled.
  2. Set up a deadline for the draining process. After this deadline, even if there are still Pod objects existing, Anthos clusters on Azure stops draining and proceeds to deleting underlying virtual machines. The default deadline is 5 minutes. For every 10 more nodes, 5 more minutes is added.
  3. Cordon all the nodes in the node pool.
  4. Before deadline is met, delete Pod objects in the node pool with best efforts.
  5. Delete all the underlying compute resources.

What's next