Forum Discussion

stucci's avatar
stucci
Level 6
9 years ago

How I restore Hyper-v VM in a different location

Hi all, I do not understand how perform a restore of a VM Hyper-v in different Hyper-v server. I have two cluster "SYSCLUHVP01M" (source) and "SYSCLUHVP01S" (destination) and each cluster has 2...
  • Fabrice_P_'s avatar
    9 years ago

    Hello,

    Redirected restore of Hyper-V VM, using the GUI is completly broken/ineffective/half-implemented since years (HV customers really needs more love...). As shown in your screenshot, the restore path will include all the c\clusterstorage\etc.. crap.

    So, the only workaround is to use the command-line to perform the restore, using a "change file":

    nbrestorevm -vmhvnew -C [vm to restore] -R [path to the change file] -vmserver [any node of the target cluster]

    The change file must looks like:

    change /C/ClusterStorage/[myVM]/7BC92-8661-999925F01436.xml to /C/ClusterStorage/RestoredVMs/[myVM]/7BC92-8661-999925F01436.xml
    change /C/ClusterStorage/[myVM]/MyVM_C.vhd to /C/ClusterStorage/RestoredVMs/[myVM]/MyVM_C.vhd
    change /C/ClusterStorage/[myVM]/MyVM_E.vhd to /C/ClusterStorage/RestoredVMs/[myVM]/MyVM_E.vhd

    Basically one line per vm file, paths are in unix format.

    I personnaly use this command to generate a template file that I modify later to act as a change file:

    bplist -flops 33554432 -S [master server] -C [VM] -R 999 -t 29 -unix_files "/" > C:\Temp\MyChangeFile.txt

     

    I hope it helps.