All Products
Search
Document Center

Tair:Manage tags

Last Updated:Nov 09, 2023

If you have a large number of instances, you can create multiple tags and add different tags to different instances to classify and filter instances by tag.

Usage notes

  • A tag consists of a key-value pair. Each key must be unique for an Alibaba Cloud account in a region. This constraint does not apply to key values.

    Note

    A key can have zero to multiple values.

  • You can edit tags for a maximum of 50 instances at a time.

  • You can add up to 20 tags to an instance.

  • You can add or remove up to 20 tags at a time.

Create tags

  1. Log on to the Tair console and go to the Instances page. In the top navigation bar, select the region in which the instance that you want to manage resides.

  2. Perform one of the following steps to create a tag for one or more instances:

    • Create tags for a single instance

      Find the instance for which you want to add tags. In the Tag column corresponding to the instance, click Edit Tags.

    • Create tags for multiple instances

      Select the instances and click Edit Tags below the instance list.

  3. In the dialog box that appears, click Create.

    Note

    If you have created tags, click Available Tags to add the tags to one or more instances.

  4. Set the key and value of a tag and then click OK.

  5. Repeat Step 4 and Step 5 to create all the tags. Then click OK in the lower-right corner of the dialog box.

    Note

    After you create tags for an instance, you can add the tags to other instances.

Filter instances by tag

  1. Log on to the Tair console and go to the Instances page. In the top navigation bar, select the region in which the instance that you want to manage resides.

  2. On the Instances page, select the tag key and tag value, and click Search.

    Note
    • After you create a tag or update an existing tag, you must refresh the page to view the updated tag list.

    • To clear a filter condition, click the 删除 icon next to the selected tag.

View the tags that are added to an instance

  1. Log on to the Tair console and go to the Instances page. In the top navigation bar, select the region in which the instance that you want to manage resides.

  2. On the Instances page, find the instance and view its tags in the Tag column of the instance.

Remove or delete tags

  1. Log on to the Tair console and go to the Instances page. In the top navigation bar, select the region in which the instance that you want to manage resides.

  2. In the Tag column corresponding to the instance from which you want to remove tags, choose 编辑标签按钮 > Edit.

  3. In the dialog box that appears, click the 删除 icon next to the tag that you want to remove.

    Note
    • You can remove up to 20 tags at a time.

    • If you remove a tag from all instances to which the tag is added, the tag is automatically deleted.

    • If you remove a tag from an instance, the normal operation of the instance is not affected. After all tags of an instance are removed, the instance cannot be filtered by tag.

  4. Click OK.

Related operations

Operation

Description

TagResources

Adds tags to one or more Tair instances.

ListTagResources

Queries the tags that are added to a Tair instance.

UntagResources

Removes tags from a Tair instance.