How Site Recovery Manager Handles Storage DRS Tagging (2108196)
Site Recovery Manager tags datastores with replication status, consistency group, and protection group so Storage DRS can use the information to migrate the datastore correctly. When migrating datastores, Storage DRS considers the following conditions of the datastore:
- If the datastore is replicated or non-replicated
- If the datastore is part of a consistency group
- If the datastore is part of a protection group
Static TagsSite Recovery Manager creates the following tag categories automatically for the datastore status, consistency group and protection group:
The SRM-com.vmware.vcDr:::status tag category contains a replicatedtag to mark the datatstore if it is a replicated datastore.
Site Recovery Manager creates static tags and tag categories when you enable an array pair. If Site Recovery Manager detects static tags and tag categories already present in the system then it does not create these tags and tag categories. Site Recovery Manager never deletes static tags and tag categories. They remain in the system even after you uninstall Site Recovery Manager and you have to manually delete these tags and tag categories. If multiple instances of Site Recovery Manager link to the same vCenter Server, then all instances share these static tags and tag categories. Remove static tags and tag categories only if they are not used by any Site Recovery Manager instance.
Tag categories are single cardinality. You can create multiple tags of the same category, but you can attach only one tag of a given category to a datastore.
Site Recovery Manager creates tags to identify the consistency group
and protection group associated with a datastore. Site Recovery Manager creates these tags dynamically whenever it discovers new consistency groups or protection groups
and destroys them when the consistency group or
protection group no longer exists.
SRM-com.vmware.vcDr:::protectionGroup tag category contains tag names in the format of SRM-PG-xxxxx
You can enable Site Recovery Manager to create and attach tags and tag categories and repair missing or unwanted tags for Storage DRS compatibility by setting the appropriate values in Site Recovery Manager Advanced Settings.
|Setting Name||Description and Default Value|
|storage.enableSdrsStandardTagCategoryCreation||Enable this flag to allow Site Recovery Manager to automatically create static tag categories and replicatedtag needed for Storage DRS compatibility. The default value is true.|
Enable this flag to allow Site Recovery Manager to automatically create and attach tags on replicated or protected datastores for Storage DRS compatibility. Disabling this flag deletes all dynamic consistency group and protection group tags and breaks Storage DRS compatibility. Enabling this flag after disabling it requires a server restart to take effect. The default value is true.
Enable this flag to allow Site Recovery Manager to repair missing or unwanted tags on replicated or protected datastores for Storage DRS compatibility. The default value is true.
|storage.sdrsTaggingPollInterval||Periodic interval Site Recovery Manager uses to identify any missing statically or dynamically created tags and statically created tag categories. The default value is 50 seconds.|
If you set storage.enableSdrsStandardTagCategoryCreation and storage.enableSdrsTaggingRepair to true, then Site Recovery Manager automatically recreates any missing static tags and tag categories. If you set these settings to false, then Site Recovery Manager does not automatically create the static tags and tag categories. You have to create them manually to ensure Storage DRS interoperability.
Note that the tag and tag category names are case-sensitive so you must create tags and tag categories using the exact names and cardinality.
Verify Static Tags and Tag Categories
If you manually create the static tags and tag categories, verify that Site Recovery Manager automatically created and attached the dynamically created tags and also attached the replicatedtag to datastores.
- Restart Site Recovery Manager.
- Enable an array pair if it is not already enabled.
- Confirm the datastores discovered by Site Recovery Manager have the replicatedand SRM-CG-xxxxx tags.
- Create a protection group.
- Verify the datastore is part of the protection group and has the SRM-PG-xxxxx tag.
If you notice some tags are
missing, the static tag and tag categories were created incorrectly. Delete the manually created tags and categories and follow the steps to verify that Site Recovery Manager automatically created and attached the dynamically created tags correctly.
Tag and Tag Category Duplication
Site Recovery Manager enables Storage DRS compatibility by tagging replicated and protected datastores. Site Recovery Manager creates tags automatically in vCenter Server or you can create tags manually. Depending on the topology, vCenter Servers can replicate tags and tag categories between servers in a datacenter. Tags are usually replicated in federated SSO vCenter Server setups.
Tag categories required for Site Recovery Manager-Storage DRS compatibility are static which means their names are fixed. Tags required for compatibility are generally dynamic, except for the replicatedtag. Dynamic tag names are randomly generated based on an algorithm to make them unique. Examples of dynamic tag names are SRM-CG-2e435836a1c568851c4a0fdc40700c01 and SRM-PG-1626ccad7332d859c6b1b059acf908f9. All tags under consistencyGroup and protectionGroup categories are dynamic.
Static tags and tag categories
might become duplicated when two different vCenter Servers create them at
the same time, or if a delay in replication interval or temporary
failure occurs in one or more nodes. Dynamic tags are unique and do not get
Identify Duplicate Tags and Categories
Duplicate tags and tag categories might cause Storage DRS to provide incorrect recommendation or migrate datastores incorrectly so you must check for duplicates and remove them.
- In the vSphere Web Client, click Tags in the left panel.
- In the Items tab, click Categories to identify tag categories with duplicate names.
- In the Items tab, click Tags to identify tags with duplicate names.
Remove Duplicate Tags and Categories
- Disable the automatic mode in Storage DRS clusters that contain replicated or Site Recovery Manager-protected datastores in all relevant vCenter Servers.
- Do not accept any manual recommendations in these Storage DRS clusters.
- Shut down all Site Recovery Manager servers that have at least one array manager configured.
- Delete all duplicate Site Recovery Manager-Storage DRS static tag categories and verify only one instance of each is present.
- Delete all duplicate Site Recovery Manager-Storage DRS static tags and verify only one instance of each is present.
- [Optional] Manually create the static tags and categories. These are case-sensitive. Perform this step only if the static tags and categories were deleted accidentally.
- Allow 1-2 minutes for vCenter Server to replicate the tags and categories to all nodes.
- Start the Site Recovery Manager servers that were previously shut down.
- Verify that all replicated or protected datastores are tagged appropriately.
- Enable the automatic mode in Storage DRS clusters that contain replicated or Site Recovery Manager-protected datastores in all relevant vCenter Servers.
- Repeat the process if you find duplicated tags and categories.
Datastores Spanning Consistency Groups
Site Recovery Manager does not support datastores spanning consistency groups and cannot protect them. If Site Recovery Manager
detects a datastore across consistency groups, it attaches one consistency group tag and replicatedtag to the datastore
because the consistency group tag category is of single cardinality and only one tag can be attached to a datastore.
If Storage DRS tagging repair is enabled, at the periodic repair interval the repair logic detects the datastore is missing the tag associated with the other consistency group and replaces the existing tag with the missing consistency group tag. As a result, the consistency group tag switches between the two consistency groups.
Since Storage DRS relies on the consistency group and
replicated tags to calculate migration recommendations, it can
potentially allow migration of virtual machines from a datastore belonging to a
consistency group, CG1, to a datastore spanning multiple consistency
groups, CG1 and CG2. The migration might result in loss of protection and data loss. Make sure that
datastores spanning consistency groups are not part of the Site Recovery Manager inventory.
Verify Tagging After Upgrading Site Recovery Manager
To ensure datstores have the appropriate tags to support Storage DRS compatibility, after you upgrade Site Recovery Manager servers and fix the array manager credentials as instructed in the topic Configure and Verify the Upgraded Site Recovery Manager Installation in VMware Site Recovery Manager Installation and Configuration, you must restart the Site Recovery Manager server.
Alternatively, run discover devices on all the array pairs the upgraded Site Recovery Manager Server manages.