Deployment–Introducing PowerShell Deployment Toolkit

Deployment–Introducing PowerShell Deployment Toolkit

  • Comments 53
  • Likes

In this post, I want to provide an overview of the “PowerShell Deployment Toolkit”, or PDT. PDT is a set of scripts and knowledge that can be used to deploy… well, probably just about anything, but the samples we provide are for deployment of System Center 2012 SP1. There’s nothing to stop someone from modifying the XML files provided with PDT to deploy something else, but that’s not to say that would be the correct way to deploy other technologies.

Of course, System Center itself provides ways to deploy software or even complete services. Software distribution has been a core capability of Configuration Manager ever since I’ve been working with it – at least 17 years – and it’s certainly true that Configuration Manager has a very sophisticated and reliable way to distribute software to vast numbers of geographically distributed devices. Virtual Machine Manager includes a capability called Service Templates that allows for complete services to be deployed, including the virtualization resources to support those services. Service Templates also allow for servicing of those services.

PDT is absolutely not intended to replace any of those capabilities. Rather, PDT is intended to help solve the chicken and egg problem – I need System Center for all of those advanced software and service deployment capabilities, but without System Center already in place how do I deploy System Center? Internally at Microsoft, with every milestone during development – CTP, Beta, RC, RTM – we rebuild the SCDemo environment to allow our field to learn the new capabilities we are delivering. PDT is the automation we use to do those rebuilds very quickly – usually in 2-4 hours. Yes, just 2-4 hours to deploy all of System Center including SQL and all prerequisites in a highly available configuration including all of the automatable post-setup integration. We want to provide you with the same efficiency.

It is going to take a whole series of posts to explain all of the capabilities of PDT, so I’ll start in this post with a simple overview and sample deployment. PDT requires that the servers that System Center will be deployed to are already running, members of an Active Directory domain, and you have administrator permissions to those servers. They can be physical or virtual, and can even be on any virtualization platform – PDT doesn’t care. They just need to be running Windows Server – and in most cases, that can be either Windows Server 2012 or Windows Server 2008 R2. The only exceptions to this are that the server for the Virtual Machine Manager Management server must be Windows Server 2012, and the server for the Service Manager SharePoint Web Parts server must be Windows Server 2008 R2. You will also need all the software to be used in the deployment – System Center components, SQL Server, and prerequisite software – downloaded and available in a specific folder structure. Getting that part right is the subject of another post.

PDT is posted to the TechNet Gallery here.

PDT consists of 5 files:

  • Installer.ps1 is the PowerShell script that you run to actually perform the deployment. It should be run from a system that is not a target system for the deployment itself – it can even be run from a workstation.
  • Workflow.xml contains all the “knowledge” of how to deploy system center – we will look in more detail at the content of this file in later posts.
  • Variable.xml is the file that you modify to define your deployment.
  • Downloader.ps1 is a utility to allow you to obtain all the software required to deploy. Using this utility will be the topic of another post.
  • VMCreator.ps1 is a utility to quickly create domain joined VMs on which to deploy. Using this utility will be the topic of another post.

The only one of these files that you should modify is Variable.xml – the sample provided in the initial PDT post in the TechNet Gallery deploys a minimal installation of System Center 2012 SP1 with a single server per component (three for Service Manager), exactly the same way that Unified Installer did for System Center 2012, but with additional roles and integration completed.

Those of you brave enough to try this at this point, just edit Variable.xml replacing the “Variable” entries with appropriate values for your environment, and the “Role” entries with appropriate server names, then run Installer.ps1.  If there are roles you don’t want to deploy, just delete those entries from the “Roles” section.

Later posts in this blog will go into detail about how PDT works and how to customize it for your deployment needs.

Your comment has been posted.   Close
Thank you, your comment requires moderation so it may take a while to appear.   Close
Leave a Comment
  • The Mother of all Automation Tools is out ! I had the chance to share with my customer a real-time demo by @Rob himself from Texas, and frankly, this is IT ! :-) Outstanding job, Man.

  • Very cool stuff! - looking forward to trying it out in real life!

  • I'm really looking forward to further explanations of the tool. It seems like a huge time saver.

  • How to prepare the PDT's Env?

    Now I got error information as follows.


     Validating certificates for roles...

       Role: System Center 2012 SP1 Service Provider Foundation Server... Failed

    Validation failed

    Can you give some advice?

    Best Regards,


  • SPF requires a certificate for installation – you can create one with PowerShell New-SelfSignedCertificate, or you can remove the SPF server from the deployment by removing those lines from the <Roles> section of variable.xml

  • I have this error too, but the recommended fix is just part of catch 22's all around this particular deploy of the last vm.

    I've only minimally changed variable.xml by using my domain name and credentials except for

    the vhd file I changed to my Windows Server 2012 DataCenter I created with Convert-WindowsImage.ps1

    The first problem is that the scripts are set up to create 10 vm's and all with the one vhd file but the Installer.ps1 fails validation for windows version on the 10th vm (Server20).  It needs to be Windows Server 2008 R2.  I've resolved this by adding <VM Count="10"> section pointing to a vhd of the correct os.

    The second problem is that it now passes the OS validation but then fails the validation described above.. why?  Because Windows 2008 R2 doesn't have PKI.  Catch22 right there.

    What am I missing?  Seems maybe I have an environment problem somewhere or others would have seen this?

  • Which roles are failing validation?  SPF is the only one that requires a certificate, and it also requires Windows Server 2012.  The Service Manager SharePoint Web Parts Server is the only one that requires Windows Server 2008 R2 - so I suspect you have a bad combination.  Also, please try with version 2.4, there are more validations in there that might pinpoint the issue closer.

  • Server20 had a couple of validation fails(OS and RPC locater) that I had fixed and so the next failure I figured was the same server but was actually Server14.  I created the certificate on Server14 and validations are working now.  Thanks for the -ValidateOnly flag in v2.4  =)

  • Trying out the Downloader.PS1, it looks like the links to download the ISO's are invalid.  Getting a 403 forbidden.  Opened the Workflow.XML and located the URL's, pasted them into IE and getting "We are sorry, the page you requested cannot be found." page by Microsoft.

  • Matt - thanks for bringing this to our attention.  While we look into it, you can manually download from the eval link on, and extract the ISO to a folder WindowsServer2012 in your download location – the downloader will then skip attempting to download that item.

  • Hi Rob, great Tool ! For Next Release can you please integrate:

    SQL Management Console on each system

    Define SQL Server Service in Variable.xml (don't want to use the local system account)

    check for Server 2008 R2 and Powershell execution policy

  • Hi Boris

    You can add the SQL tools into any system you want.  So just put in the roles

       <Role Name="SQL Server 2012 Management Tools" Server="Server1" ></Role>

    So add that line to your variable.xml in for the servers that you wish to have the admin tools on or change to 2008 if you want those tools instead.


  • This is amazing! I'm getting ready to deploy OM12 I look forward to reading these to see how I can use them to deploy OM12.

  • I'm trying to get the Installer to run, I'm getting one error around System Center 2012 SP1 Management Packs - incorrect size for I've attempted the one that was downloaded, also grabbed a copy from two different versions of System Center ISO's that I have (2012, 2012SP1), same issue.

    Any suggestions on how to resolve this issue?

  • Hi Sky

    Microsoft updated the windows MP a couple of weeks ago.  As a result you will need to change the size in the workflow xml document.

    you will need to update it to be this.