none
Script to merge a differencing disk into a new parent

    Pertanyaan

  • Can somebody help me with a script (ideally powershell) to merge a differencing disk into a new parent disk?

    I've been trying

    ..

    $ims = get-wmiobject -namespace root\virtualization -class Msvm_ImageManagementService

    $ims.mergevirtualharddisk(<"path to diff disk">,<"path to new parent">)

    and keep getting errors like

    'The system failed to merge 'path to diff disk'. Error Code: 2424869

    and

    Failed to open attachment 'path to diff disk'. Error: 'One or more arguments are invalid'

    Host is 2008 R2 SP1

    TIA

    18 Juni 2012 7:26

Jawaban

  • Hi,

    General speaking, it is recommended that you delete the snapshots in Hyper-V Manager console and then let the system merge the snapshots automatically while the virtual machines is power off.

    By the way, according to the description, it seems that you want to write script. As we mainly focus on the Hyper-V question about Windows Server system and here is not the best support resource for script writing, it is recommend you to get further support in the corresponding community so that you can get the most qualified pool of respondents. Thanks for your understanding.
     
    For your convenience, I have list the related link as followed.

    The Official Scripting Guys Forum
    http://social.technet.microsoft.com/Forums/en-US/ITCG/threads

     

    18 Juni 2012 13:05