Cloud Enterprise Network (CEN) supports tag management. You can use tags to categorize and identify resources within CEN, which simplifies resource search and aggregation. This topic uses a CEN instance as an example to describe how to manage and use tags. The process is similar for other CEN resources.
Tag overview
Usage
As the number of your instances grows, management can become more difficult. Grouping instances by tags helps you find and filter them.
A tag is a label that you assign to an instance. Each tag is a key-value pair. The following rules apply to tags:
-
Each tag key must be unique to an instance.
-
A tag key is required, but a tag value is optional and can be an empty string.
-
Tags must be attached to an instance. A tag cannot exist independently.
-
Tags for different resource types are not interchangeable.
For example, a tag that you add to a CEN instance cannot be attached to a transit router instance.
-
You can modify the key and value of a tag, or remove a tag from an instance at any time.
-
If you delete an instance, all tags attached to the instance are also deleted. This action does not affect tags attached to other instances.
-
You can attach a maximum of 20 tags to an instance. This quota cannot be increased.
Supported resource types
You can add tags to the following resources: CEN instances, bandwidth plan instances, transit router instances, VPC connections, VBR connections, VPN connections, inter-region connections, route tables of Enterprise Edition transit routers, flow log instances, and multicast domain instances.
-
You cannot add tags to transit router instances in Cloud Connect Network (CCN) regions.
-
You cannot add tags to VPC connections, VBR connections, and inter-region connections that are attached to a Basic Edition transit router.
Add tags
Log on to the CEN console.
-
On the CEN Instance page, add tags to one or more CEN instances as follows:
-
Add tags to a single CEN instance
-
In the Tag column of the target CEN instance, click the
icon, and then click Bind or Edit. -
In the Edit Tags dialog box, add one or more tags, and then click OK.
Parameter
Description
Tag key
The key of the tag.
The key must be 1 to 64 characters long and cannot start with
aliyunoracs:. It cannot containhttp://orhttps://.Tag value
The value of the tag.
The value can be up to 128 characters long. An empty string is permitted. The value cannot start with
aliyunoracs:. It cannot containhttp://orhttps://.
-
-
Add tags to multiple CEN instances
-
Select the check boxes of the target CEN instances. In the lower-left corner of the page, choose .
-
In the Edit Tags dialog box, specify the Tag key and Tag value, and then click OK.
-
After you add the tags, you can hover over the
icon in the Tag column of the target CEN instance to view its tags. -
Filter by tag
After you add tags to CEN instances, you can use them to quickly filter those instances.
Log on to the CEN console.
-
On the CEN Instance page, click Tag Filtering.
-
In the Tag Filtering dialog box, select the tags by which you want to filter.
In the left pane, select a tag key, such as project. In the right pane, select the corresponding tag values, such as project1 or project2, to filter the instances. Click Tag Management at the bottom of the page to open the tag management page.
Edit tags
After you add tags to a CEN instance, you can add more tags to the instance, or modify or delete existing tags.
Log on to the CEN console.
-
On the CEN Instance page, edit the tags of CEN instances as follows:
-
Edit the tags of a single CEN instance
-
In the Tag column of the target CEN instance, click the
icon, and then click Edit. -
In the Edit Tags dialog box, add, modify, or delete tags as needed, and then click OK.
-
Add tags: Add new tags to the list.
-
Modify tags: Change the key or value of an existing tag.
-
Delete tags: Click the
icon next to a tag to remove it.
-
-
-
Modify the tags of multiple CEN instances
-
Select the check boxes of the target CEN instances. In the lower-left corner of the page, choose .
-
In the Edit Tags dialog box, modify the tags of the CEN instances, and then click OK.
-
If you enter a new tag key, a new tag is added to the selected CEN instances.
-
If you enter an existing tag key with a new value, the value for that tag is updated on the selected instances.
-
-
-
Remove tags from multiple CEN instances
-
Select the check boxes of the target CEN instances. In the lower-left corner of the page, choose .
-
In the Unbind tags dialog box, select the target tags, and then click Unbind.
-
-
API reference
-
TagResources: Attaches tags to specified resources.
-
UntagResources: Unbinds tags from specified resources.
-
ListTagResources: Queries the list of tags that are attached to CEN resources.