Assign a new tag during volume creation
You can create a new object tag when you want to assign one or more tags to new objects that are tiered from a new volume you create. You can use tags to help you classify and sort tiering objects for easier data management. Beginning with ONTAP 9.8, you can use System Manager to create object tags.
You can set tags only on FabricPool volumes attached to StorageGRID. These tags are retained during a volume move.
-
A maximum of 4 tags per volume is allowed.
-
In the CLI, each object tag must be a key-value pair separated by an equal sign (
""
). -
In the CLI, multiple tags must be separated by a comma (
""
). -
Each tag value can contain a maximum of 127 characters.
-
Each tag key must start with either an alphabetic character or an underscore.
Keys must contain only alphanumeric characters and underscores, and the maximum number of characters allowed is 127.
Procedure
You can assign object tags with ONTAP System Manager or the ONTAP CLI.
-
Navigate to Storage > Tiers.
-
Locate a storage tier with volumes you want to tag.
-
Click the Volumes tab.
-
Locate the volume you want to tag and in the Object Tags column select Click to enter tags.
-
Enter a key and value.
-
Click Apply.
-
Use the
volume create
command with the-tiering-object-tags
option to create a new volume with the specified tags. You can specify multiple tags in comma-separated pairs:volume create [ -vserver <vserver name> ] -volume <volume_name> -tiering-object-tags <key1=value1> [ ,<key2=value2>,<key3=value3>,<key4=value4> ]
The following example creates a volume named fp_volume1 with three object tags.
vol create -volume fp_volume1 -vserver vs0 -tiering-object-tags project=fabricpool,type=abc,content=data