Creating Hyper-V 12 R2 Cluster from Windows Server 12/VMM

I got a question about an error that occured when creating a Hyper-V 2012 R2 cluster from VMM 2012 R2 and the errorlog stated the following:

“Error (25325) The cluster creation failed because of the following error: An error occurred while performing the operation.. “

In the troubleshooting I found that the VMM 2012 R2 was running on a Windows Server 2012 Standard (which is fully supported). But as VMM uses the failover cluster cmdlets from the OS where installed it fails creating the R2 cluster as it is not supported to manage Windows 2012 R2 from a Windows 2012.

looking at the technet article regarding Server Manager it has a good table about support:

Screen Shot 2014-01-10 at 13.53.35


I have done some upgrades from VMM 2012 SP1 to 2012 R2 and have always in that process changed the operating system first to the latest version so this issue has not appeared for me before.

Testing to create a Hyper-V 2012 R2 cluster from a windows 2012 failover cluster manager gives the following error :

Screen Shot 2014-01-10 at 14.12.35

New version of Convert-WindowsImage.ps1 that support Gen2

So I noticed that the awesome Convert-WindowsImage.ps1 PowerShell script has been updated to version 6.3 and published during the Christmas holidays. The script is maintained by Microsoft Consulting Services and was originally created by Mike Kolitz.

I really like this script and have used it alot when creating new VM´s and I have been awaiting an update to support the Generation 2 VM´s with UEFI boot.

Here you can see that I have added the parameter -VHDPartitionStyle GPT to use for the generation 2 VM

Screen Shot 2013-12-30 at 21.59.28

You can find the script here.


Make running VM highly available in VMM 2012 R2

So I was helping a customer to migrate a VMware VM to their Hyper-V environment that is managed with System Center VMM, As I described in an earlier post I had some things that I did not like in the built-in v2v conversion that is part of the VMM.

In this migration I used Double-Take Move and this is a really nice software from Vision Solutions that allows you to migrate a running VM and will only get a few minutes downtime during the failover :-). The great thing is that the VM is replicated to the hyper-v host directly and you get a synthetic NIC and also a VHDx virtual disk.

There are though some small things that need to be considered and Double-Take does not do the whole part when used separately, when using it with Vision Solutions system center integration toolkit we can automate these things too, but for migrating just a few VM´s that is a bit of overkill. So what do we need to take care of,

  • DT does not set VLAN on the nic for the migrated VM, that can be done during the replication in VMM when the newly provisioned VM appears there and set the right vm network and bandwidth etc.
  • DT does not make the VM highly available during the migration, it can be deployed on the Clusterstorage volume though.
  • DT does not remove VMware tools during the migration so that has to be cleaned up after.
  • DT does not update/install the Hyper-V integration components.

So now to the main focus for this article, when the VM has been migrated to Hyper-V, how do I configure it to be highly available? When looking in the properties of the VM on VMM that option is greyed out

Screen Shot 2013-12-20 at 12.56.41

And trying to add it through the PowerShell cmdlets in VMM gives the following error message:

Screen Shot 2013-12-20 at 14.50.46

So the way to do it is with the Hyper-V and failover cluster cmdlets instead:

Screen Shot 2013-12-20 at 14.58.34

And then when refreshing the VM in VMM you can see that it is now highly available 🙂

Screen Shot 2013-12-20 at 14.21.48

The workaround option that is available in VMM to be able to make the VM highly available is to do a Live Storage migration to another CSV Volume/SMB share and in the wizard check the box for making it highly available but that involves file copying and goes painfully slower than the Add-VMToCluster on the running VM that already resides on a shared storage volume.

Screen Shot 2013-12-20 at 15.36.05

And this also (at least in my test environment) creates a copy cluster resource that has to be cleaned up manually cause the real one is running..

Screen Shot 2013-12-20 at 15.53.40

Passed exam 74-409 today!

Today I was in the mood to take a Microsoft exam and as MSFT so generously gives a cert voucher for free it was not so much to argue about 🙂

I already have the MCSE : Private Cloud

But now it was time for Microsoft Certified Specialist: Server Virtualization with Hyper-V and System Center (exam nr 74-409) and this exam reflects and measures the latest releases from Microsoft in Windows Server 2012 R2 Hyper-V and System Center 2012 R2.

The skills being measured can be found here.

I have some knowledge in the subject and have done some implementations before and also had the previous title MCITP: Virtualization Administrator so I thought it should not be too hard, as always some questions have to be read more than once before choosing the right answer.

I used Marius collection of study tips and also the Microsoft Virtual Academy that with registration gives you the free voucher

Good luck in your free tryout 🙂



Password dump from a Hyper-V Virtual Machine´s memory

So earlier this week the twitter flow went bananas when Remko did a blog about how to extract the password in clear text from a VMware vmem file with the add-on from Benjamin, Mimikatz that extends the windebug.

I wanted to test if it works also in Hyper-V and it is not so much difference, the main difference is how to create the dump file and here I use the vm2dmp (thanks to Yusuf for supplying me with a vm2dmp.exe that works with 2012!!) with the right switches, in this case the VM is in saved state but you can also use snapshots or just the vsv and bin file.

Screen Shot 2013-11-29 at 16.33.16

And then when importing the dump into the windbg I can with the commands get the password for the user that was logged in on the Win 7 VM

Screen Shot 2013-11-29 at 15.26.19

I have tested this on a Windows 7 virtual machine and also on a Windows Server 2012 R2 virtual machine both running on Hyper-V 2012. This highlights the importance once more that it is crucial to make sure that only the right people have access to the virtualization hosts and the storage where the VM´s resides!

Bug in VMM 2012 SP1 disconnect VM nic after cold migration?

Yesterday I was at a customer and working on configure their off site Hyper-V cluster. I was setting up live migration settings to be able to do shared nothing live migrate the VM´s between the data centers. I was  setting up kerberos authentication and also delegation in the active directory but did not think of the 10 hours (600 minutes) time that a kerberos ticket could live and got some errors regarding constrained delegation, as it says if reading a bit more carefully in this technet page on how to configure live migration outside of clusters  :”A new kerboros ticket has been issued. “, I did not think of this at first and checked the hosts settings and the active directory objects twice 😛 but it did not work and I did not think of the time….  If you want to purge the kerberos tickets you can use the klist command line tool.

Well during the error search I had to test to do a cold migration from SC VMM between the clusters and that looked like no problem at all. It should also be said that both clusters was configured with the same logical network, vm networks, logical switch and uplink so it was the same conf! SC VMM have been updated with the latest CU 4.

When the VM had been migrated i started it and tried to ping the IP address but got no response.. strange I thought, looked in VMM on the properties on the VM and it said that the network card was connected:

Screen Shot 2013-11-08 at 14.42.38

But still inside the VM it said not connected,

Screen Shot 2013-11-09 at 08.33.35

And then going into the Hyper-V manager and looking at the VM´s properties from there I could also see that it was not connected. I did a VM refresh also in VMM but it did not change the connection status on the VM object to reflect the status as the screen dump below from the properties in the Hyper-v Manager:

Screen Shot 2013-11-08 at 14.42.09

Once I connected it to the (logical) virtual switch on the host with Hyper-V Manager it started to respond to ping of course.

I will continue to exam this further and maybe it has been fixed in the VMM 2012 R2.


New free Windows Server 2012 R2 book released

Today Microsoft Press released a free book about the features in Windows Server 2012 R2 written by Mitch Tulloch and the Windows Server Team. The book goes through the new features in the latest release and gives you as an IT PRO an oversight and quickly get familiar with the different areas of improvement from the 2012 to R2.

Screen Shot 2013-11-08 at 19.16.00

The book can be downloaded at this link 

The book starts with the Cloud OS vision that is all about mobility and that microsoft already with the 2012 release described, the possibility to move between the different clouds.

Screen Shot 2013-11-08 at 19.15.41

Convert to generation 2 on a VM in Hyper-V 2012 R2 with Powershell

I have done blog posts about why you should create your new VM´s with Windows Server 2012 instead of 2008 R2 or older even if you were not able to create them with the generation 2 at that time as the Windows 2012 R2 was not released back then.

I also did a blog post how to use a third party product to do the migration from generation 1 to 2 with Double Take Move software.

Now I found John Howards script that he has made public that does the migration from generation 1 to 2 🙂 He also has a blog series about generation 2 VM´s that is definitely worth the time to check out.

I got an error when running it though and it seems that it does not work so good with the partition on the gen 1 virtual disk..  It appears that when I have created my virtual machine with the Convert-WindowsImage.ps1 script that only creates one partition the row in the script that checks for $partitions.length fails and I could not get it to continue but when I commented that away I got my first conversion on the way 🙂

Screen Shot 2013-10-30 at 20.40.59

And here you can se in the PowerShell ISE my alteration  🙂

Screen Shot 2013-10-30 at 22.15.58

Now I am sure that John and his team will work and distribute new versions with correct error checking and I am truly glad that they have released this so I could test it right now anyway 🙂 !!

Here is my VM in generation 1

Screen Shot 2013-10-30 at 21.50.07

And here is the converted VM,

Screen Shot 2013-10-30 at 22.21.34

And here you can see that during the conversion that I have two disks attached to my server and that the one at the bottom has got some new partitions for the gen 2 UEFI boot process

Screen Shot 2013-10-30 at 22.15.03

Happy converting and making generation 2 VM´s your standard in Hyper-V

SC VMM 2012 SP1 UR4 – fixes the Cluster resource bug

I have on my blog done a post about how the VMM 2012 Sp1 not updated the cluster resource when doing Live Storage migration from one CSV volume to another in a Hyper-V cluster and now in the Update Release 4 of VMM 2012 SP1 they have finally fixed it!

Here you can see the Issue 13 that has been fixed

Screen Shot 2013-10-29 at 23.08.44

Also as in Issue 15 there was stuff left after a canceled or failed migration

Screen Shot 2013-10-29 at 23.09.00

One thing that could have been a wish was that they in this UR would have added the Windows 2012 R2 as an operating system, you can run Windows 2012 R2 as virtual machines in your 2012 Hyper-V but not assign the right OS on the properties on the VMM 2012 Sp1 🙁


In Hyper-V this does not have an impact for the successful boot as in VMware VM´s where you set the best matching OS for the boot process to work flawlessly. In Hyper-V it uses the same BIOS for all your VM´s and this list is something for VMM and the database.

Strange Creation Date on Hyper-V 2012 R2 VM

I have some VM´s on my new Windows 2012 R2 host that have a strange creation date on the properties.

The VM´s have been created on different times and it was a customer that noticed it.

quite fun as there was not computers or even Hyper-V invented in the 17 century or was it? 😉

Here is my lab/demo VMM 2012 R2 virtual machine and as you can see it is created the 1 of january 1601



and here is the other virtual machine, a windows 8 template

Screen Shot 2013-10-29 at 21.59.33


I have not been able to reproduce it now with either PowerShell or via the GUI, If you have seen the same issue please comment the post 🙂