The Deployment Bunny

OS Deployment, Virtualization, Microsoft based Infrastructure…

  • Archives

  • Meta

Archive for the ‘Windows Server 2012’ Category

PowerShell is King–Convert Windows Server Editions during OS Deployment (MDT/LiteTouch)

Posted by Mikael Nystrom on July 2, 2014

Yesterday I posted a simple UI based PowerShell script that allows the local administrator of the server to change the Windows Edition. That is is a nice to have function, but what if you would like to do that during the deployment of the server instead of after. This way you can have two task sequences, one for Standard and one for datacenter but just have one WIM file (also means one reference image). For the same reasons I mentioned in the previous post,  I have created some scripts for this.

You can read the previous post on the UI method here http://deploymentbunny.com/2014/07/01/powershell-is-kingconvert-windows-server-editions-using-a-ui-based-powershell-script/

All three options here are using the same base logic with the same kind of option. Instead of defining every different “upgrade” , I decided to have just 2, NEXT and TOP. When TOP is selected as an option it will upgrade to the TOP Edition, in other words Datacenter. When NEXT is selected, it will do the NEXT level. That means that a standard will be datacenter, unless it is a 2008 r2, then a standard will be enterprise. Evaluations will be the “same, so a standard evaluation, will be a standard . In a bit more detail, this is what the scripts actually do…

What kind of conversion can the scripts perform?

Source OS   UpgradeLevel Destination OS
Windows Server 2008 R2 Standard to NEXT Windows Server 2008 R2 Enterprise
Windows Server 2008 R2 Standard   TOP Windows Server 2008 R2 Datacenter
Windows Server 2008 R2 Enterprise   NEXT/TOP Windows Server 2008 R2 Datacenter
Windows Server 2012 Standard Evaluation   NEXT Windows Server 2012 Standard
Windows Server 2012 Standard Evaluation   TOP Windows Server 2012 Datacenter
Windows Server 2012 Standard   NEXT/TOP Windows Server 2012 Datacenter
Windows Server 2012 R2 Standard Evaluation   NEXT Windows Server 2012 R2 Standard
Windows Server 2012 R2 Standard Evaluation   TOP Windows Server 2012 R2 Datacenter
Windows Server 2012 R2 Standard   NEXT/TOP Windows Server 2012 R2 Datacenter

 

Option No:1 (VB Script as an Application)

The first option is to use a VBscript and run it as an application, that gives a great logging and integration with the Task Sequence in MDT. The script uses a Custom property called UpgradeLevel (which can be set to either NEXT or TOP) that you needs to be added to CustomSettings.ini

Step By Step, kind of…

Download Script from : http://1drv.ms/TBO9Zw

Add the Custom property UpgradeLevel.

image

Import the Application in the Deployment Workbench.

image

Modify the Task Sequence (add a Set Task Sequence Variable Step)

image

Modify the Task Sequence (Add the Application)

image

Deploy a Server and check the logfile.

image

Option No:2 (PowerShell Script as an Application)

The second option is to use a PowerShell script instead, still running as an application, I added some logic to discover the presence of a Task Sequence, that way logging can end up in the correct location

Step By Step, kind of…

Download Script from : http://1drv.ms/TBOgEn

Add the Custom property UpgradeLevel.

image

Import the Application in the Deployment Workbench

image
The command line is a bit long so here it is in text form
PowerShell.exe -ExecutionPolicy Bypass -File Upgrade-SKU.ps1 -UpgradeLevel %UPGRADELEVEL%

Modify the Task Sequence (add a Set Task Sequence Variable Step)

image

Modify the Task Sequence (Add the Application)

image

Deploy the server and check the logfile.

image

Option No:3 (PowerShell Script in TaskSequence)

The third option is to run it as a PowerShell task Sequence

Step By Step, kind of…

Download Script from :http://1drv.ms/1qjoOAk

Save the script in the scripts folder

Modify the Task Sequence (Run PowerShell script)

image

Modify the Task Sequence (Add a reboot Action)

image

Deploy a server and check the logfile.

image

/mike

Posted in MDT, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2 | Tagged: , , | Leave a Comment »

PowerShell is King–Convert Windows Server Editions using a UI based PowerShell script

Posted by Mikael Nystrom on July 1, 2014

If possible it is best practices to keep the number of images to a minimum. So, in my line of work I’m building reference images for both client and servers, many of the organization I work with are struggling with the fact that they need to have both old images and new images, both servers and clients and also both 32 and 64 bit. Add all that up you will realize that, hmm, lets see… that will be 9 images to maintain, no, wait, I missed the fact that we also have different editions. Servers have Standard and Datacenter edition, that is three more, or actually its 4 more since Windows Server 2008 R2 have Standard, Enterprise and Datacenter.

Download the script from http://1drv.ms/1lMpr4i

The solution

Since it is possible to upgrade every Windows Server edition (Windows Server 2008 R2 and above) to a higher edition (and that includes evaluation editions to) by changing the product key using DISM.exe it is possible to create reference images with the lowest SKU(Edition) that your organization needs and upgrade during the deployment or as this blog post is about, after the OS has been deployed. Internally for us this is great since we are running many proof of concept, labs, tests and such and many cases. I gave up telling/explaining for our internal staff on how to do this, ending up with a script that is “user-friendly”.

To be able to change edition, you need to have a product key, and what we do is that we change to the KMS client key, so yes it needs to be activated after it has been modified. You can find all these product keys at TechNet here: http://technet.microsoft.com/en-us/library/jj612867.aspx

What kind of conversion can the script perform?

Windows Server 2008 R2 Standard to Windows Server 2008 R2 Enterprise
Windows Server 2008 R2 Standard to Windows Server 2008 R2 Datacenter
Windows Server 2008 R2 Enterprise to Windows Server 2008 R2 Datacenter
Windows Server 2012 Standard Evaluation to Windows Server 2012 Standard
Windows Server 2012 Standard Evaluation to Windows Server 2012 Datacenter
Windows Server 2012 Standard to Windows Server 2012 Datacenter
Windows Server 2012 R2 Standard Evaluation to Windows Server 2012 R2 Standard
Windows Server 2012 R2 Standard Evaluation to Windows Server 2012 R2 Datacenter
Windows Server 2012 R2 Standard to Windows Server 2012 R2 Datacenter

How to use?

Execute the script from an elevated command prompt and select upgrade type.

image
Changing from Windows Server 2008 R2.

image
Changed from Windows Server 2008 R2.

image
Changing from Windows Server 2012 R2 Standard Evaluation.

image
Changing from Windows Server 2012 Standard.

Posted in PowerShell, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2 | Tagged: , , , | 1 Comment »

Recording – Windows Azure Virtual Machine

Posted by Mikael Nystrom on February 2, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

 

/mike

Posted in Recording, System Center 2012, Windows Server 2012 | Tagged: | Leave a Comment »

Recording – System Center 2012 – Operations Manager

Posted by Mikael Nystrom on February 1, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

 

/mike

Posted in Recording, System Center 2012, Windows Server 2012 | Tagged: | Leave a Comment »

Recording – System Center 2012 – Orchestrator

Posted by Mikael Nystrom on January 31, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

“Mikael Nyström, expert inom setup & deployment och konsult på TrueSec, lär dig att konfigurera Orchestrator – så automatisterar och optimerar du flödet i ditt datacenter. “

/mike

Posted in Recording, System Center 2012, Windows Server 2012 | Tagged: | 1 Comment »

Recording – System Center 2012–DPM

Posted by Mikael Nystrom on January 30, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

“Mikael Nyström, expert inom setup & deployment och konsult på TrueSec, lär dig mer om Data Protection Manager – konfigurera säker och stabil backup och dataskydd i ditt datacenter. “

 

/mike

Posted in Recording, System Center 2012, Windows Server 2012 | Tagged: | Leave a Comment »

Recording–Hybrid Cloud

Posted by Mikael Nystrom on January 29, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

“Mikael Nyström, expert inom setup & deployment och konsult på TrueSec, lär dig mer om hybridmoln i Windows Server 2012 – så kombinerar du Windows Azure och det privata molnet i Windows Server 2012. “

 

/mike

Posted in Azure, Recording, System Center 2012, Windows Server 2012 | Tagged: | Leave a Comment »

Recording–Private Cloud

Posted by Mikael Nystrom on January 28, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

“Mikael Nyström, expert inom setup & deployment och konsult på TrueSec, ger dig en introduktion till privata moln i Windows Server 2012. Så konfigurerar du infrastrukturen och hanterar virtuella maskiner. “

 

/mike

Posted in Recording, System Center 2012, Windows Server 2012 | Tagged: | Leave a Comment »

Recording–Windows Server 2012 Hyper-V

Posted by Mikael Nystrom on January 27, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

“Mikael Nyström, expert inom setup & deployment och konsult på TrueSec, lär dig att konfigurera Hyper-V och upptäcka alla fördelar med att köra virtuella maskiner i Windows Server 2012. “

/mike

Posted in Hyper-V, Recording, Windows Server 2012 | Tagged: | Leave a Comment »

Recording–Windows Server 2012 Fjärråtkomst

Posted by Mikael Nystrom on January 26, 2014

(In Swedish)

För Microsofts räkning så spelade jag in en serie korta filmer, varsågod.

“Mikael Nyström, expert inom setup & deployment och konsult på TrueSec, lär dig att konfigurera fjärråtkomst i Windows Server 2012 och upptäcka nya, förbättrade funktioner i Direct och Remote Access. “’’

 

/mike

Posted in Recording, Windows Server 2012 | Tagged: | Leave a Comment »

 
Follow

Get every new post delivered to your Inbox.

Join 3,711 other followers