cancel
Showing results for 
Search instead for 
Did you mean: 

BE 2012: How to restore a VHD file?

MIXIT
Level 6
Partner Accredited

I'm in the unfortunate situation of possibly having to restore a VM ina  Hyper-V host.  The VM is currently BSOD'ing and troubleshooting hjas been a problem, so one option I am considering is just restoring the VHD file.  However I do not want to overwrite the VM (VHD + vm info) so I want to restore the VHD file to a seperate location, then tell Hyper-V Manager to point to that VHD file just so I can boot it and see if it works.  If so I would then shut the virtual machine down, move the newly restored VHD file over to the proper locationi where I store VHD's on this server, and reconfig Hyper-V Manager to now point to that , renaming and moving the old (BSOD'ing) VHD file elsewhere for a bit. 

I assume this is straightforward, yet when I click on my backup job (there is just one, and it covers the entire machine, VM's included) and hit the Restore button to start the wizard for that, and then the files & folders selection options, I don't see what I think I should.  As I browse the Resources View and drill down into the directory structure where the file should be, I don't see it.  I see only folderse at all levels, never a file on the right-side pane.  Am I missing something?  Is there some kind of limited view?  Do restores that relate to even just the raw VHD file itself somehow get masked or something so I can't simply restore just the file and have to do the whole VM or something? 

Thanks for your help. 

1 ACCEPTED SOLUTION

Accepted Solutions

MIXIT
Level 6
Partner Accredited

Hi again!  REspectfully, I had to clear the Mark as Solution status on pkh's post. 

I found that it seems I can indeed restore just the VHD file.  But I need your advice before trying it.  Here's what I've done:

 

  1. Backup and Restore tab
  2. Servers view where it shows 5 servers (one is the Hyper-V host, 4 are the VM guests)
  3. Highlight the physical host server, click Restore button at top
  4. Wizard pops up, I am presented with four options.  The last option is Microsoft Hyper-V data
  5. Selecting this I am then given a dialog asking: which virtual machine or virtiual disks do you want to restore? - the default is the Resrouces view and let's me drill downt the hierarchy all the way to where the vhd file itself is located.  I see it, and can put a checkmark in it. 
  6. When I click Next, I am given the choice of restoring to original location, or to a different location.  I now pick different location. 

 

Here's where I get confused.  Attached to this post is a screenshot of the scrreen I am at.  I am not sure what to fill in for the Server Name, Drive (which oddly has no Browse button), and Server Path. 

My goal is just to point the file and restore it to a folder on the server someplace, not to rename it, nor register it with Hyper-V.  I'd rather just swap the vhd file manually so I can test between the problem VHD file and the resetored one.  There is no Help button on this wizard screen oddly.  Also I removed the checkmark from the Register the virtual machine. 

 

It keeps mentioning virtual machien but I think this is just inaccurate text labels on the screen, as all I've done in this restore process is pick the actual VHD file, not the full VM with environment files. 

Here's the screenshot:

 

BE2012RestoreWizard.jpg

 

 

View solution in original post

12 REPLIES 12

pkh
Moderator
Moderator
   VIP    Certified
VHD is automatically excluded from normal backups. To do what you want, you need to restore the entire VM. You can restore the VM to another name

VJware
Level 6
Employee Accredited Certified

If the backup was made to disk or if it is duplicated from tape to disk, an IMG directory on the disk storage containing the .vhd file will be present.

You can try importing this .vhd, however consistency is not guaranteed. Preferred restore method is as suggested above.

MIXIT
Level 6
Partner Accredited

Thanks guys.  Very odd to me that .vhd files aren't simply restorable but I'm glad to know the method preferred.  In BE if I highlight the backup job I think in the servers view or something, I hit the Search button at the top.  I put in the filename, and it finds 407 instances of the file but only in the BE temp folder, under a subfolder called Deltas I think it was.  I didn't do anything with those since instead of x:\TEMP, the actual vhd is found within x:\Hyper-V\VMs or what not. 

 

Anyway, ok so I will look at the full VM restore.  Since this is an AD server and there are two AD servers in this domain, does restoring one AD server to itself 2 days old cause problems?  Nothing new was done so I'm not worried about data/users, etc being lost, but will the server restore and not cause problems with AD overall? 

 

Thank you guys. 

MIXIT
Level 6
Partner Accredited

No disk-based backups unfortunately, just your everyday LTO tape drive :(

MIXIT
Level 6
Partner Accredited

Hi again!  REspectfully, I had to clear the Mark as Solution status on pkh's post. 

I found that it seems I can indeed restore just the VHD file.  But I need your advice before trying it.  Here's what I've done:

 

  1. Backup and Restore tab
  2. Servers view where it shows 5 servers (one is the Hyper-V host, 4 are the VM guests)
  3. Highlight the physical host server, click Restore button at top
  4. Wizard pops up, I am presented with four options.  The last option is Microsoft Hyper-V data
  5. Selecting this I am then given a dialog asking: which virtual machine or virtiual disks do you want to restore? - the default is the Resrouces view and let's me drill downt the hierarchy all the way to where the vhd file itself is located.  I see it, and can put a checkmark in it. 
  6. When I click Next, I am given the choice of restoring to original location, or to a different location.  I now pick different location. 

 

Here's where I get confused.  Attached to this post is a screenshot of the scrreen I am at.  I am not sure what to fill in for the Server Name, Drive (which oddly has no Browse button), and Server Path. 

My goal is just to point the file and restore it to a folder on the server someplace, not to rename it, nor register it with Hyper-V.  I'd rather just swap the vhd file manually so I can test between the problem VHD file and the resetored one.  There is no Help button on this wizard screen oddly.  Also I removed the checkmark from the Register the virtual machine. 

 

It keeps mentioning virtual machien but I think this is just inaccurate text labels on the screen, as all I've done in this restore process is pick the actual VHD file, not the full VM with environment files. 

Here's the screenshot:

 

BE2012RestoreWizard.jpg

 

 

LegAEI
Level 5

If you select register virtual machine, the process will error out. Just choose a directory to restore your file to and it will restore there.

MIXIT
Level 6
Partner Accredited

Process completed, file restored.  Curious but why would the Register virtual machine feature  error out?  Is that something Symantec needs to fix? 

maurijo
Level 6
Partner Accredited

In any case I think you did make a mistake the first time you tryed it. Are you sure that you selected the hyper-v host machine and then clicked restore ? I think you selected the hyper-v guest you wanted to restore and then clicked restore so that would be why it was not showing Hyper-v data first time.

It's like wanting to do a single item restore on a vmware machine but you select the vcenter or esx instead. Doing this it will not show you single files but only entire VMs.

 

Correct me if I am wrong, I don't have any experience restoring Hyper-v.

LegAEI
Level 5

The VHD file is just a file, there isn't any metadata to register with the server. If you wanted to mount the VHD you would go through disk management in the operating system.

If you used the agent for hyper-v to do the backup, then you would have all the metadata, and thus could register the VM with the hyper-v host.

MIXIT
Level 6
Partner Accredited

Understood.  Yeah I do have the agent licensed.  Biut in this case it appears the old VHD file itself was somehow partially corrupt.  I need to make a new post on this actually so somebody can get their Mark as Solution bonus. 

MIXIT
Level 6
Partner Accredited

No problem.  I know on my first try whatever I did was definitely wrong, but in my post with the screenshot, that's the process to get the VHD file restored.  Confirmed it as well by actually doing it successfully. 

maurijo
Level 6
Partner Accredited

Good that you got it working. Please mark a solution so that other people who have this problem can see the solution easier.