Tagging Storage Gateway resources
In Storage Gateway, you can use tags to manage your resources. Tags let you add metadata to your resources and categorize your resources to make them easier to manage. Each tag consists of a key-value pair, which you define. You can add tags to gateways, volumes, and virtual tapes. You can search and filter these resources based on the tags you add.
As an example, you can use tags to identify Storage Gateway resources used by each department
in your organization. You might tag gateways and volumes used by your accounting department
like this: (key=department
and value=accounting
). You can then
filter with this tag to identify all gateways and volumes used by your accounting department
and use the information to determine cost. For more information, see Using Cost Allocation Tags and Working with Tag
Editor.
If you archive a virtual tape that is tagged, the tape maintains its tags in the archive. Similarly, if you retrieve a tape from the archive to another gateway, the tags are maintained in the new gateway.
For File Gateway, you can use tags to control access to resources. For information about how to do this, see Using tags to control access to your gateway and resources.
Tags don’t have any semantic meaning but rather are interpreted as strings of characters.
The following restrictions apply to tags:
-
Tag keys and values are case-sensitive.
-
The maximum number of tags for each resource is 50.
-
Tag keys cannot begin with
aws:
. This prefix is reserved for Amazon use. -
Valid characters for the key property are UTF-8 letters and numbers, space, and special characters + - = . _ : / and @.
Working with tags
You can work with tags by using the Storage Gateway console, the Storage Gateway API, or the Storage Gateway Command Line Interface (CLI). The following procedures show you how to add, edit, and delete a tag on the console.
To add a tag
Open the Storage Gateway console at https://console.amazonaws.cn/storagegateway/home
. -
In the navigation pane, choose the resource you want to tag.
For example, to tag a gateway, choose Gateways, and then choose the gateway you want to tag from the list of gateways.
-
Choose Tags, and then choose Add/edit tags.
-
In the Add/edit tags dialog box, choose Create tag.
-
Type a key for Key and a value for Value. For example, you can type
Department
for the key andAccounting
for the value.Note
You can leave the Value box blank.
-
Choose Create Tag to add more tags. You can add multiple tags to a resource.
-
When you’re done adding tags, choose Save.
To edit a tag
Open the Storage Gateway console at https://console.amazonaws.cn/storagegateway/home
. -
Choose the resource whose tag you want to edit.
-
Choose Tags to open the Add/edit tags dialog box.
-
Choose the pencil icon next to the tag you want to edit, and then edit the tag.
-
When you’re done editing the tag, choose Save.
To delete a tag
Open the Storage Gateway console at https://console.amazonaws.cn/storagegateway/home
. -
Choose the resource whose tag you want to delete.
-
Choose Tags, and then choose Add/edit tags to open the Add/edit tags dialog box.
-
Choose the X icon next to the tag you want to delete, and then choose Save.