When deploying Hyper-V servers using MDT 2010 Zero Touch Roles and Features and ConfigMgr 2007 SP2, you quickly realize that the Hyper-V installation reboots the task sequence during the process and never processes the rest of it. This also requires you do to some additional housecleaning afterwards…
But what if you want to do things in the task sequence after the step that installs Hyper-V, or want to avoid the housecleaning?
Well, simply create a separate operating system image package where Hyper-V is enabled offline already.
1. Create a copy of your Windows Server 2008 R2 image Custom Image
2. Mount the image using imagex
ImageX /mountrw W2K8R2-001.wim 1 D:\Mount
3. Inject Hyper-V using Dism
dism /image:d:\mount /Enable-Feature /FeatureName:Microsoft-Hyper-V
dism /image:d:\mount /Enable-Feature /FeatureName:Microsoft-Hyper-V-Management-Clients
4. Commit the changes
ImageX /unmount /commit D:\mount
5. Update the distribution point