End to End Automation with MDT Managing your reference images. Fred om Daniel
Sr. Infrastructure Engineer MNSCUG, President FredBainbridge.com 15+ years experience. Minneapolis, Minnesota Fred Bainbridge
Technology Architect Co-founder LouSMUG.org 10+ years experience Louisville, KY Daniel Ratliff
Get Involved (Keep the internet awesome) Join or Start your local user group. Participate in forums Technet MyItForum Etc Keep a blog.
What this is not - How to build a reference image. A ConfigMgr OSD deep dive. See: Hacking the Task Sequence How to write PowerShell Learn PowerShell in a Month of Lunches
What this is - Solving a business problem. Automating the reference image creation..…and all that other crap. Utilizing simple PowerShell to make life easier.
Why MDT? - Simple PowerShell friendly Free It just works!
Defining the Business Problem What is impacted? Build Time, accuracy, etc. Why is this needed? Security Requirements, Lifecycle, etc. What is the $ Metric? Hours / Month? Hours / Build? etc.
Getting Starting Identify what you need to automate. ( ) There is more than just the OS image. Example Crap - Setup a virtual machine Stage the device in WDS Start the reference image build Update a pilot or production task sequence Update Azure image Clean up Log your actions
Technical Lab Details Hyper-V VMs Server1 MDT 2013 WDS w/ PXE - Respond only to known hosts - Not AD integrated Server 2 DHCP, DNS [TSID] – VM for the reference build. - Pre determined MAC address.
MDT Details Full CustomSettings.iniCustomSettings.ini Monitoring must be enabled. The task sequence ID will match the VM name.
Demo Automate!
MDT Image automation with Orchestrator Built off Fred’s scripts Same LAB setup Uses SCOrch for all automation Uses PowerShell for all runbook steps Leverages PowerShell 2.0 for native compatibility Modified to function with SCOrch Reference scripts included for testing Single runbook for simplicity’s sake Nothing left behind except captured.wim
MDT Details – CustomSettings.ini Slightly modified CustomSettings.ini.wim is timestamped (TSID_MMDDYYYY.wim) Runbook parameter must match MAC Runbook parameter must match Task Sequence ID
SCOrch Details – Runbook All steps return Result variable: Success or Fail Only continue on Success Easily modified for value adds Send an on success/fail? Add.wim to deployment task sequence? Required parameters MDT server MDT deployment share MDT task sequence ID WDS server Hyper-V server Hyper-V switch name Hyper-V VM root path Hyper-V VM MAC address
SCOrch Details – Runbook
Demo Automate with SCOrch!
Other ways to Automate SMA Azure Automation Service Manager (any Service Management Tool) Mostly Automated
Phase 2 / The next level Incident / Request Management This one matters the most. Self Service Portal SharePoint/Collaboration Notifications Test Builds Scheduling Logic
Discussion - Who said it? “Building golden images is a bad practice – stop now” -Jeffrey Snover
References PS Module and Example Scripts Credentials Invoke-Command command-example Johan PowerShell Function Outline (ctrl+j)
References continued Johan Arwidmark - Building references images like a boss! ng-reference-images-like-a-boss ng-reference-images-like-a-boss Ryan Andorfer - MMS Future of SCOrch Hey Scripting Guy! – Use PowerShell to automate MDT 12/31/learn-how-to-use-powershell-to-automate-mdt- deployment.aspx 12/31/learn-how-to-use-powershell-to-automate-mdt- deployment.aspx
Evaluations: Please provide session feedback by clicking the EVAL button in the scheduler app (also download slides). One lucky winner will receive a free ticket to the next MMS! Session Title: Automating End to End Image Creation with MDT and PowerShell Discuss… Ask your questions-real world answers! Plenty of time to engage, share knowledge. SPONSORS