Tag Archives: server 2012

Hyper-V Live Migration Error

A while back I encountered this error when trying to Live Migrate a VM from my Hyper-V 2012 Cluster to the new Hyper-V 2012 R2 Cluster.

You might  be asking why I was running Hyper-V 2012 in the first place…

I just happened to start upgrading our Hyper-V 2008 R2 Cluster after Windows Server 2012 was released, and then Windows Server 2012 R2 was released with some very much improved features. So I had a few VMs on the 2012 Cluster that needed to be moved to 2012 R2. It was a great time-saver to be able to Live Migrate from 2012 –> 2012 R2 (well, if I could get it working).

The error message when trying to LM a VM:

"The virtual machine cannot be moved to the destination computer. The hardware on the destination computer is not compatible with the hardware requirements of this virtual machine. Virtual machine migration failed at migration source."

I found this one fairly easily but it took a little bit of time.

When comparing my 2012 node to my 2012 R2 node I noticed that the Virtual Switches were named differently. Apparently for Live Migration this will cause an issue, at least in 2012 –> 2012 R2.

After renaming the Virtual Switches to match, the Live Migration completed successfully:

A Happy Live Migration
A Happy Live Migration

Renaming Windows Firewall Rules with PowerShell

I had some rules that were set by default that were not “user friendly” so I wanted to rename them in order to be able to tell what they were without having to query.

I can use Get-FirewallRule with some parameters to see the rules in question:

get-netfirewallrule -displaygroup "remote desktop" | format-table name, enabled -autosize
Use get-netfirewallrule to view the current firewall rules
Use get-netfirewallrule to view the current firewall rules

Then I Mark (right click, “Mark”, select and press the “Enter” key to copy to clipboard) the GUID and get the name of that rule to see what it is:

Get-NetFirewallRule -Name {4F5F06CB-CA8A-4676-BDB3-4BBBC8E95481}
Viewing the details of the firewall rule in question
Viewing the details of the firewall rule in question

Then I rename the rule using the Rename-FirewallRule cmdlet, and query again to see the change:

rename-netfirewallrule -name "{GUID}" -newname "New name of firewall rule"
get-netfirewallrule -displaygroup "remote desktop" | format-table name, enabled -autosize
Renaming the firewall rule to match the DisplayName attribute
Renaming the firewall rule to match the DisplayName attribute

As it turns out, these rules are duplicates of the ones above – the only difference that I found was that they apply to different profiles. The rules with “user friendly” names were for the “Public” Firewall Profile, whereas the GUID rules were for “Domain” and “Private” Firewall Profiles. This is the way the Remote Desktop rules are added when you configure Remote Administration with sconfig. This relates to my previous post on “Installation Configuration: Hyper-V Server 2012“.

Differences between the builtin rule and the rule created when using sconfig
Differences between the builtin rule and the rule created when using sconfig