I mentioned before that the boot image creation process used by the Deployment Workbench is significantly enhanced in MDT 2010 Beta 2, but didn’t really talk too much about how the process works behind the scenes. Now, this is template-based, with XML files that specify exactly what should be included in each boot image that we generate:
When you perform the “Update Deployment Share” process, the Deployment Workbench will take these XML files (located in C:\Program Files\Microsoft Deployment Toolkit\Templates), add some additional items to them (e.g. settings you specified on the deployment share properties such as optional components to add, settings like RAMdisk size, etc.), and then use that to build the new boot image. (As mentioned in the previous article , the process is optimized to only do the minimum amount of work – it does this by comparing the new XML file against the one generated the last time the boot image was generated. It then figures out what needs to be done based on the difference between the two.)
So what if you want to add your own files into our boot images? Just modify the template to tell us where to get them and where to put them in the image and the “Update Deployment Share” process will take care of it.
That’s fine for simple additions like adding files, but what if you want to do something more substantial? That’s where exit scripts come in. (I call this the “Johan feature”.) You’ll notice that the existing templates specify a sample exit:
<!-- Exits -->
When the “Update Deployment Share” process runs, this exit script will be called multiple times for each phase of the process, allowing you to make customizations to the process. Variables will be passed along so that you know where everything is located, what is currently going on, etc. The phases:
In each of the phases, various environment variables are defined:
The “C:\Program Files\Microsoft Deployment Toolkit\Samples” directory does contain the UpdateExit.vbs script described above, which demonstrates all the variables I described.
There is one bug in MDT 2010 Beta 2 that I have to point out though: the “STAGE” variable is always set to “WIM”, so it’s kind of hard to figure out which phase you are currently in. That’s been fixed for the released version of MDT 2010.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.