I’ve spent the last 3 weeks working on a boot wizard for my OSD deployments. Special thanks goes to Maik Koster for putting up with my stupid questions and to Todd Hemsell for adding his 2 cents whenever needed.
This was the Goal:
Create a wizard that would allow the following:
- Enter computer name
- Select OU for machine to be added to
- Select what image to apply to the system
OSD with MDT integration is great but it falls short when it comes to the things that are built in for the SCCM admin.
All of the things listed above work great if you are using lite touch in MDT but if you are using SCCM you are not given the same lite touch options because 90% of what you are doing in SCCM can be configured without the need of any interaction from an admin or end user. But the problem comes in when you have multiple images to choose from as I do and the default OU is locked. So if you are just doing a refresh on a machine you simply add the machine to the correct collection and SCCM does the rest. But if you are building a new machine from bare metal or if you are reimaging a machine and the 3 variable i listed have changed then that is when you need some customization. Technically you can also define the OU in SCCM, the problem comes in when you have lots of OU’s that means that you would need another advertisement for each image and each OU. In my case that would come out to 44 different choices. I don't want that many choices let alone have to give that many.
I will say that the MDT team provided great help in getting this working so thank you to Michael Niehaus.
In MS’s defense they provide what people ask for and most of the code that I used was cut and pasted from the code provided by MDT with little to no tweaking. So i am defiantly not badmouthing anybody here just saying that there are some short comings when it comes to the MDT/OSD lite touch integration. Zero touch is great, just not always practical.
Create our own webservice or use one that someone already has in place, no need to reinvent the wheel.
then create a wizard to do what we need. This is a scalable solution that you can add to if needed. Suggestion would be to add additional application chooses. I prefer to have a helpdesk ticket for anything that is not part of the standard image so we can track deployments but it is all based on what you need.
Things you will need:
MDT Wizard Editor
Maik’s Deployment Web service
Maik’s Custom Boot Wizard
Some knowledge of XML and VBSCRIPTING or just copy what I provide attached and edit for your environment.
Todd’s write up: (Very Helpful)
Microsoft deployment toolkit wizard editor : part 1 : introduction
Microsoft deployment toolkit wizard editor : part 2 : global settings and custom initialization and validation scripts.
Microsoft deployment toolkit wizard editor : part 3 : panes can be a pain, or how to bring external data into your wizard.
Microsoft Deployment Toolkit Wizard Editor : Part 4 : What my face looked like when I first tried to decipher the HTML in the HTML Tab!
Maik’s Write up: (Very Helpful)
Create your own MDT Webservice - Part 1
Create your own MDT Webservice - Part 2
A Webservice for OSD and MDT Deployments
Ok so lets break down what was done:
Enter Computer Name
This is very simple i just used the template pane provided with MDT
Now this got tricky. MDT provides a way to select OU’s (which i could not get working and was not dynamic).
The goal was to create a pane that would connect to my SCCM server and import an XML file on the fly. This isn’t a true dynamic pane but it will allow you to create a list and edit that list without having to mount your boot WIM and make changes every time you are asked to add a new OU to the list (this is what MS wanted you to do). You could make it a true dynamic solution by creating a table and adding the OU’s to it then have the wizard connect to a webservice and retrieve the information. I found this solution to be easier.
The provided files will do all this for you. You just need to set them up.
This panel will create a connection to the path that you provide to the DomainOU.XML file and it will import the XML then convert it to Radio buttons that you can select. It will then convert your selection to the MDT variable needed when the machine is added to the domain. If the machine is already in the domain and you are simply refreshing the machine then it will remain in its existing OU. Maik provides a webservice that will move the machine to a different OU but i am not using it with this.
Select what image to apply to the system
This panel was created by MaiK. I simply used his webservice and the panel he provided. If you want more info on this read though the links I provided above.
You will need to edit the following files for your environment
- ZTIMediaHook.wsf -- Default SiteCode if needed
- SCCM_Bootstrap.ini – Server name where Maik’s web service is running or if you wrote your own
- CustomBootWizard.vbs – Variables at the top of the script
- CustomBootWizard.xml – should have to do anything with this one but it is where the pane’s are if you want to change any of the text
- DomainOUs.xml – Edit for your OU’s, be sure to use the format provided. then place this on a share on your SCCM server.
Hope this helps others.
If you find a better way to do the OU and would like to share please feel free to contact me and I will review it :-)
Chris Stauffer <><