Currently we are working at a customer to set up a new environment.
To make this as easy as possible we are using the Microsoft Deployment Tool (MDT)
This will make it very easy to install computers with a new OS and the correct drivers.
However when the targeted computer uses the special characters like “/” in the WMI hostname, MDT runs into problems as the MDT workbench doesn’t allow special characters like “/”
In the environment the problem was caused by an Onyx ZEUS-247S PC with the WMI hostname of: ZEUS-197/227/247.
There are 2 ways to solve this.
The quick and dirty way, and the proper and nice way.
First the quick and dirty one. When there is only one model that uses the “/” it can be solved as following:
Go to the MDT server and hunt down the ZTIgather.wsf file (Deployment folder and then in the script folder). Once found open this file and go to “’Get the UUID from the Win32_ComputerSystemProduct class”. Underneath this part add the following line:
If sModel = “Original WMI hostname” then
sModel = “Folder name as used in MDT workbench”
Once this is done the computer will work with MDT.
As said before this is the quick and dirty way and I wouldn’t advice it, unless there is a really good reason. The reason for not using this is if Microsoft updates the script with a Windows Update the changes are discarded.
Ok now for the proper solution.
The best way of course is when in the future al “/” are converted automatically so they work with MDT.
First go to the MDT server and open the Script folder (under Deployment folder)
Here we create a new .wsf file that we are going to edit.
(in my case I was very lucky that Ingmar Verheij already made a file that I could adjust)
Basically in this file should be entered the following.
<script language=”VBScript” src=”ZTIUtility.vbs”/>
<script language=”VBScript” src=”ZTIConfigFile.vbs”/>
Dim oOperatingSystem, oOperatingSystems
On Error Resume Next
iRetVal = ZTIProcess
On Error Goto 0
(The following part is the important part which is going to solve our problem)
Dim sOSenable, sOSGUID, sName, sImageFile, sPlatform, sModel, sModelReplaced
oLogging.CreateEntry “Before value: ‘” & oEnvironment.Item(“Model”), LogTypeInfo
oEnvironment.Item(“Model”) = Replace(oEnvironment.Item(“Model”),”/”,”_”)
oLogging.CreateEntry “After value: ‘” & oEnvironment.Item(“Model”), LogTypeInfo
What happens is that when the hostname contains a “/” it should be replaced with a “_”
”_” Is accepted by MDT so the computers with “/” in it can be installed with MDT
However there is one final step to be made.
For this we need to open the DeploymentWorkbench
Go to Task Sequences and open the specific job u want to solve
There u go to Task sequence and make a new job. (make sure u put this job above Configure Out-of-Box Drivers Model!!)
The reason why it needs to be above that job is because when the “Configure Out-of-Box Drivers Model” job starts the computer starts looking at its designated folder for its drivers.
Make sure it runs the correct script.
Once this is done MDT should now work with hostname’s containing “/”
One point of notice from now on if a computers hostname is for example “Computer/1/2/3”
It should be in MDT referred as “Computer_1_2_3”