A couple of weeks ago I wrote “3 Easy Steps to Migrate to Hyper-V 2012 R2” talking about how to migrate VM’s from Windows Server 2008 R2 to Windows Server 2012 R2. Since then I keep hearing the same question over and over again.

Question: When you migrate VMs from Hyper-V in Windows Server 2008 R2 to Hyper V in Windows Server 2012 R2 can you also automate conversion from vhd to vhdx? And can it be done with minimum interruption to the operation of the workload of the VM?

Answer: YES!

Our friends Aidan Finn and Didier Von Hoye are using a really cool PowerShell script to automate the entire process. The only challenge here is how to accomplish the virtual disk conversion without interrupting the operation of the workload on the VM. The solution is really simple. Last year Veeam Backup & Replication V7 introduced the Virtual Lab functionality for Hyper-V which is the perfect fit for this situation.

Virtual lab provides a mechanism to construct an exact duplicate of your Hyper-V environment (exact right down to the IP addresses of the VMs) and run it in an isolated stub network attached to your production network. Once the lab is in place you can now do all kinds of cool testing and development stuff, including but not limited to migrating from vhd to vhdx files, without having to shut down the production VMs. If you are not familiar with the Veeam virtual lab – you should take the time to give it a look. This is made for a backup recovery verification technique by going through the restore process on a scheduled basis, but also as a good mechanism to test changes such as Windows Update or Domain Schema changes. The figure below shows two VMs in a Veeam Virtual Lab:

Conversion from vhd to vhdx

Once the conversion from vhd to vhdx is complete you can execute a controlled migration or just run a VM recovery to get the VM’s into the production environment. You will still need to shut down the old .vhd based VM’s before recovering the vhdx versions but there will be minimum interruption of the infrastructure workloads. It’s a great solution!

Once again Microsoft (with 2 awesome MVP’s) and Veeam working together to make things better in your virtual environment! Have you gone about converting to vhdx files yet? If so, what tips can you share about the process? If not, does this help you get there? Share your comments below.

See also: PowerShell scripting course
PowerShell guide for beginners in PDF format

GD Star Rating
loading...
VHD to VHDX Conversion Made Easy with PowerShell, 4.5 out of 5 based on 4 ratings

View posts related to category:

    Veeam Availability Suite — Download free 30-day trial

    • Adam

      How does this conversion account for the activity on the live VM in the production environment while doing the conversion? At what stage does it sync the changes from production to the VM Lab?

      GD Star Rating
      loading...
      • Andrew Zhelezko

        As far as I understand, it doesn’t make any sync between the production VM and VM in Virtual Lab. Script shuts down all VMs, performs disks conversion and reconfiguration and turns VMs on if required. With Virtual Lab you can test Veeam backups in automatic mode and see if they are recoverable.

        GD Star Rating
        loading...
        • Adam

          Ahhh so this still doesn’t give you a “live” conversion from VHD to VHDX, you still have to shutdown your live VM. This just tests if you can do it before hand. If only there is a way to live migrate from a vhd to vhdx with no/or as little as possible downtime.

          GD Star Rating
          loading...
          • Andrew Zhelezko

            Yes, no “live” conversion indeed. Anyway, what are the features of VHDX you want that badly? And why isn’t it possible to you to schedule a maintenance window at some point?

            GD Star Rating
            loading...
    Chris Henley
    Author: Chris Henley
    Chris Henley is a Microsoft IT Professional Evangelist at Veeam focused on Technologies related to Windows Server and Hyper V. He is a published author and a regular speaker and presenter at user groups and major technology conferences around the world. He is fun and... 

    Published: March 25, 2014