Replace a AD DC without gui and using PowerShell Direct

So in my home lab I had a DC going out of time (it was a technical preview of 2016) and needed to be replaced and I wanted to do it the right way and not login to the console/gui on the actual DC to it once during the removal and deploy of a new one!

So firstly I had to decommission it as a DC and then I created a new image from the media

After this I started the new DC-VM, to use the PowerShell Direct I had to activate the “Guest Service Interface”. one cool thing is when using PowerShell direct I can set the IP address on the NIC within the VM without getting disconnected as I would have been otherwise if using a ordinary powershell remoting session!

When the DCPromo was successfull I could check on the node that it was replicating okay

Looking at the deployment of Azurestack it is during the process utilizing PowerShell Direct and it is a killer feature 😀

Happy PowerShelling!

Updating Pester module to 4.0.2

I was going to do some Operational Testing development in an environment and did see that the new Pester 4.0.2 RC had been released on the PowerShell Gallery!

Woop Niiice, but ey I had already on my newly provisioned Windows Server 2016 the version 3.4.0 of the module and when trying to install from the gallery it complains about the catalog signing..

I wanted to uninstall the 3.4.0 but that one had not been installed with the PowerShell Get so I could not use the Uninstall-Module -Name Pester

So I used the Remove-Item instead, looking at the module base path I could use that one for removal of the folder and files of the 3.4.0 module and then install the 4.0.2

Now back to creating some lovely test files but this time with the 4.0.2 RC version 🙂

VMM 2012 R2 support for Windows Server 2016 guest OS

So I am working on a customer and their path of upgrading to 2016 versions. The first step was to make sure that the VMM 2012 R2 server was updated to latest UR and that I can deploy guest vm´s with 2016.

After the update of VMM to UR11 I checked the list of OS,

screen-shot-2016-11-25-at-11-00-48

So to be able to see the 2016 as a guest OS i have to add a hotfix and that took some time but what ever you do, do not cancel but wait and wait and wait and the never ending progress bar will eventually go away 😉 . And yes you have to add one hotfix for the console and one for the vmm server!

screen-shot-2016-11-25-at-11-33-19

And once that is applied,

screen-shot-2016-11-25-at-11-43-52

Good luck in your upgrading story !

 

 

Installing System Center VMM 2016 and SQL 2016 on Windows Server 2016 Core

I am a firm believer that Servers should not be used for the wrong things and thus I have now installed the new System Center VMM 2016 on a Windows Server 2016 Core.

In my home lab I do not have so many hosts so I have used the opportunity to install the SQL 2016 on the same core instance.

As I am installing the SQL on the same machine I had to enable the .net 3.5/2.0 feature on this server and yes I know and can´t agree more, please remove this requirement dear SQL team and move to the future!

screen-shot-2016-10-14-at-13-53-46

SQL 2016 does not support installing via the wizard on server core so I used the command line way (by the way based on this information req page it is not supported on Windows 2016 core yet 😉 )

Although it is not supported with the wizard for sql install on core it do show some progress through a graphical dialog…

screen-shot-2016-10-14-at-14-07-10

So once that was up and running I installed the ADK for windows 10, and I used the one for Windows 10 1607.

And then I could start the VMM install. And yes there is a command line way of installing the VMM but this time I wanted to see if I could use the wizard in core!

screen-shot-2016-10-14-at-14-26-54

During the installation the wizard complained about my memory that I had assigned to the VM that I was installing on and I could with the superduperfeature in 2016 add more to the running VM without doing any stop and start!

screen-shot-2016-10-14-at-14-44-54
screen-shot-2016-10-14-at-14-45-14

After that I had no more issues and the installation completed successfully!

screen-shot-2016-10-14-at-15-01-15

Well once installed I had to do some patching as at the same time VMM 2016 was released Microsoft also announced the availability of CU1 🙂 and trying to use the short cut from the installation dialog fails on a Server core as those GUI parts are not present! I can though use the Sconfig and the “Download and install updates” option to get the updates I want…

screen-shot-2016-10-16-at-23-21-27

Happy playing!

Going from Windows Server 2016 Eval to GA license

Today You might have seen that Windows Server was released and available from Volume center and MSDN etc.

I had previously reinstalled my Hyper-V node at home with a new 2016 eval media and now I wanted to activate it with a license to not have it time out in 170 days

Going into the control panel and trying to change keys was not the way to do it!

screen-shot-2016-10-12-at-22-20-05
screen-shot-2016-10-12-at-22-22-51

Reading about how to do it in 2012 R2 gives a hint that I should use DISM to set the new key instead

screen-shot-2016-10-12-at-22-46-12

And then after two reboots I log in and can verify that my license have been applied 🙂

screen-shot-2016-10-12-at-22-51-16

And if you wonder about 2016 KMS keys you can find them on technet on this link!

Windows Server 2016 is now available on Azure

So the day has come when Windows Server have arrived at Microsoft Azure and you can start deploying your new workloads.

You either find the different flavours from the portal or from PowerShell

screen-shot-2016-10-12-at-15-37-58

And the command for finding them with PowerShell AzureRM module is

and running it looks like this:

screen-shot-2016-10-12-at-16-12-07

Good luck in deploying!

 

AzureStack TP2 – deploy experience

During Ignite 2016 in Atlanta, Microsoft announced the technical preview 2 of AzureStack and finally now this friday I got my hardware available (the dang server was not responding on the ILO port and I had to go to the datacenter to give it a kung-fu-devops-kick) so I could deploy the new bits.

First things first! Read the documentation about how to proceed and you will more likely succeed in your deployment!

The download for AzureStack is 20 GB so if you have a slow internet connection it will take some time!

Before getting started i suggest you to run the pre-check script that can tell you if there is some immediate issues,

screen-shot-2016-10-07-at-23-53-16

And then you can unpack and follow the instructions to prepare to vhd-boot into the cloudbuilder disk with the next script:

screen-shot-2016-10-08-at-15-28-55

Once rebooted you want to make sure that you only have one nic enabled and then kick of the deployment which will take about 2-3 hours if you have a decent hardware like me 😛

screen-shot-2016-10-08-at-15-59-48

As you can see the install process uses both desired state and powershell direct (which is a lovely feature in Hyper-V 2016)

screen-shot-2016-10-08-at-17-01-47

And if you are patient and then log in as a azurestack\AzureStackAdmin on the physical machine you will see the status of the deployment. Do not log in as a local user on the server and try to start the deployment again!

Hopefully you will end up with the same result as me:

screen-shot-2016-10-08-at-18-26-54

And then you can log in to the VM MAS-CON01 to connect to the portal,

screen-shot-2016-10-08-at-18-34-31

Maybe I was lucky but I believe that the Stack-Team has done some serious work since TP1 and the deployment process have been thoroughly developed, tested and works really good now.

Good luck in your deployment of Azurestack TP2!

 

Upgrade to Windows Server 2016 TP5 – Live migrate from TP4

So the day have come when finally the new TP5 bits have been released! And I of course downloaded and wanted to test to upgrade one of my hyper-v servers in my home lab.

Screen Shot 2016-04-27 at 21.53.33

Once installed I tried to migrate a VM from the hyper-v manager at the new TP5 node, I had of course set up kerberos and delegation before but still it gave me an error. To see if it was just in the GUI or also in PowerShell I tried the same move and got the same issue

Screen Shot 2016-04-27 at 23.26.57

So powershell remoting to the rescue to test that I could live migrate my VM´s from the TP4 to the TP5 and that worked nicely. I will dig some more into if there is an issue with the AD objects or what causes this and do an update if I find anything…

Screen Shot 2016-04-27 at 23.27.44

happy testing!

 

Configure VM Network settings from the host using Hyper-V 2016

Today I used Ravikanth script for configuring an VM´s NIC settings from the host and can confirm that it works nicely also on a Hyper-V Host with 2016 TP4 and a full-GUI VM and also with VM´s running Nanoserver 🙂

There is a cmdlet in the Hyper-V PowerShell module that is named: Set-VMNetworkAdapterFailoverConfiguration although that configures only the nic for the Hyper-V replicated VM and cannot be used on a ordinary vm. So using the function from Ravi I set the VM´s configuration using the Hyper-V WMI virtualization namespace.

Screen Shot 2016-03-01 at 14.53.00

And trying to set it on a Nano server also works nicely

Screen Shot 2016-03-01 at 15.19.58