change virtualsystemIdentifier using WMI

balu T 41 Reputation points
2020-11-12T11:27:10.713+00:00

Hi,
how to change the VM GUID (VirtualSystemIdentifier/ConfigurationID) using WMI or powershell ?

https://learn.microsoft.com/en-us/windows/win32/hyperv_v2/msvm-virtualsystemsettingdata

Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
12,205 questions
Hyper-V
Hyper-V
A Windows technology providing a hypervisor-based virtualization solution enabling customers to consolidate workloads onto a single server.
2,560 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Mico Mi 1,921 Reputation points
    2020-11-13T08:25:28.76+00:00

    Hi baluT,
    Based on my experience, we cannot change the VM GUID by PowerShell or WMI. VM GUID is automatically generated after the VM is created.
    As a workaround, if you want to change it, you can create a new VM connected to the old VHD, and the VM GUID will be recreated.
    I did the test in my lab:
    This is the original GUID of VM 14

    39667-image.png
    And then I deleted the VM and created a new one attached to the old VHD 14.
    As you can see, the GUID of 14 has been recreated.
    39668-image.png
    Thanks for your time!

    Best Regards,

    Mico Mi

    -----------------------------

    If the Answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.