How to find the Duplicate VM UUID’s

I recently came across an issue with the VMware SRM where there was a VM having the same UUID in both the primary and recovery site. This VM was a clone from the primary site and was never powered on the recovery site but was rather cloned to template and was used for new builds, over time, everyone forgot about the cloned VM and we recently started seeing issues with the recovery plan. We were unable to test and cleanup the recovery plan. We started seeing the below PANIC message in the SRM logs.

Panic: VERIFY d:/build/ob/bora-3037005/srm/src/recovery/settings/vmRecoverySettingsRepository.cpp:1291

This is a known issue in SRM 6.1 and KB related to this can be found here. The KB does not provide a way to look for the duplicate UUID’s so here is what we used to find the VM UUIDs on both Primary and Recovery vCenter servers.

Run the below code to get the VM’s and their UUIDs in a csv, once you have the csv, its very easy to identify the duplicates. Once you have the VM identified, Shutdown the VM, browse to the VM datastore and backup the vmx file of the VM and edit the value for uuid.bios and re upload to the datastore and power on the VM. Just to make sure it does conflict with the other VMs again, verify the UUID you used is not present in the csv file.

Here are step by step instructions on editing the vmx files Link1 Link2

$vmlist =get-vm | sort name 

forEach ($vm in $vmList) {
       $vmName=$vm | %{(Get-View $_.Id).Name}
       $vmUuid=$vm | %{(Get-View $_.Id).config.UUID}
       echo "$vmName,$vmUuid" | Out-File -Append <path to csv>

Here is the sample output from my lab


Hope this was informative and useful. Thanks!


Part 17 – Running a Recovery

Finally, we have arrived to a point where we can run the Recovery. SRM migrates all the VMs in the recovery plan to the recovery site. SRM attempts to shutdown the VMs at the Protected Site. Not everyone in the organization are allowed to run recovery as it alters the entire environment in many cases and reversing things is time consuming and needs effort. Continue reading

#run-recovery, #srm-6-1

Part 16 – Cleanup after testing a Recovery Plan

It is important to clean up after testing the recovery plan; failing to clean up the recovery plan bars us to test or run the recovery plan again. Cleanup does the following things.

  • Powers off the recovered VMs
  • Replaces recovered VMs with place holder VMs and preservs the configuration information.
  • Cleansup the replicated storage snapshots that the recovered VMs used during the test.

Continue reading

#cleanup, #test-recovery-plan

Part 15 – Test a Recovery Plan

Now that we have the recovery plan configured according to our needs, its time we test the recovery plan. When you test a recovery plan, SRM uses the test network to test the VMs in the plan and also no VMs on the Protected Site are powered off unlike when the actual recovery plan is run. Remember that, if a recovery plan requires to suspend or power off any VM on the recovery site, testing the recovery plan also suspends the VMs and no other changes are made to the production environment during the test recovery. Continue reading

#srm-6-1, #test-recovery-plan, #timeout, #vmware-tools-heartbeat

Part 14 – Configuring a Recovery Plan

Creating a Recovery Plan is a very good thing but how do make it work the way we want it to? Well, every Recovery Plan has to be configured for the fact that, virtual machines depend on other machines in many ways, for example, the DB server has to powered on first for the app server and web server to connect to it and in some cases, we want to run some start-up scripts so that the machine can become available to users. All such things have to be fed to the recovery plan. So let’s see how that is done. Continue reading

#ip-costomization, #recovery-plan, #recovery-steps, #srm-6-1

Part 13 – Creating a Recovery Plan

We have come a long way in settings up things and working on SRM related stuff. We have almost reached the last steps in enabling a Disaster Recovery Solution for VMs. Now that we have Protection Groups created and verified all the required VMs are being replicated as expected, our next step would be to create a Recovery Plan so that the Protection Groups can be made use of. A Recovery Plan controls every step of the recovery process, including the order in which the VMs have to be powered on, networks to be used, and other stuff related to virtual machines to be protected. Continue reading

#recovery-plan, #srm-6-1

Part 12 – Creating Protection Group

As discussed in our previous post, Protection Groups are a collection of virtual machines that are protected together. Protection Groups can be created based on the type of replication they have ie whether it is Array Based or vSphere Replication or Storage Policy Based. A Recovery Plan can include Protection Groups from Array Based Replication or vSphere Based Replication but a Storage Policy Based Protection Group cannot be included in the same Recovery Plan as Array or vSphere Replication Protection Group. Continue reading

#placeholder-virtual-machines, #protection-groups, #srm-6-1