You can manage node labels in the Container Service console, including adding node labels in batches, filtering nodes by using a label, and deleting a node label quickly.

For how to use node labels to schedule pods to specified nodes, see Set node scheduling.

Prerequisite

You have successfully created a Kubernetes cluster. For more information, see Create a Kubernetes cluster.

Add node labels in batches

  1. Log on to the Container Service console.
  2. Click Kubernetes Clusters > Nodes in the left-side navigation pane.
  3. Select the cluster from the Clusters drop-down list and then click Label Management in the upper-right corner.


  4. Select one or more nodes by selecting the corresponding check boxes and then click Add Tag.


  5. Ener the name and value of the label in the displayed dialog box and then click OK.


    Nodes with the same label are displayed on the Label Management page.


Filter nodes by using a label

  1. Log on to the Container Service console.
  2. Click Kubernetes Clusters > Nodes in the left-side navigation pane.
  3. Select the cluster from the Clusters drop-down list and then click Label Management in the upper-right corner.


  4. Click the label at the right of a node to filter nodes by using the label. In this example, click group:worker.
    Nodes with the label group:worker are filtered.


Delete a node label

  1. Log on to the Container Service console.
  2. Click Kubernetes Clusters > Nodes in the left-side navigation pane.
  3. Select the cluster from the Clusters drop-down list and then click Label Management in the upper-right corner.


  4. Click the delete (x) button of a node label, for example, group:worker.


    Click Confirm in the displayed dialog box. The node label is deleted.