Jump to content


  • 0
xstatic411

Task Sequence not renaming PC

Question

I am running into issues naming the workstation during my task sequence using the OSDComputername collection variable. I am prompted to define the OSDComputername variable before the task sequence kicks off but it doesn't appear to be passing through. Any help would be greatly appreciated. Let me know what other information would be helpful in locating the problem.

 

I attempted to follow http://www.windows-noob.com/forums/index.php?/topic/569-how-can-i-deploy-windows-xp-sp3-using-sccm-2007-sp1-part-1/ as closing as possibe.

 

See attached image for screen shots of Task Sequence, OSDComputerName Variable and SMSTS log file

 

Here is my Unattend.txt:

 

 

;SetupMgrTag
[Data]
AutoPartition=1
MsDosInitiated="0"
UnattendedInstall="Yes"
[unattended]
UnattendMode=FullUnattended
OemSkipEula=Yes
OemPreinstall=No
TargetPath=\WINDOWS
[GuiUnattended]
AdminPassword=0d805d535f585b992eb5aab0d86ed91e1df416cc8ead7d8199dd37515074da8a
EncryptedAdminPassword=Yes
OEMSkipRegional=1
TimeZone=20
OemSkipWelcome=1
[userData]
ProductKey=XXXXX-XXXXX-XXXXX-XXXXX-XXXXX
FullName="Company Name"
OrgName="Company Name"
ComputerName=
[identification]
JoinWorkgroup=WORKGROUP
[Networking]
InstallDefaultComponents=Yes

Share this post


Link to post
Share on other sites

4 answers to this question

Recommended Posts

  • 0

Thanks for pointing that out. I have removed the Unattend.txt and re ran the task sequence. It is still not pulling the name that i defined in the OSDComputername. I followed the advice found on another forum that suggested I create a Task Sequence Variable names OSDComputerName and setting the value as %_SMSTSMachineName%. However this doesnt appear to correct the problem.

Share this post


Link to post
Share on other sites

  • 0

Naming Computers is really for unknown computers (Out of box PCs). The variable OSDComputerName should be set at the collection level on the unknown computer collection. Follow this guide and you should be fine.

 

If you do not want to add unknown computer support to your enviornment another work around would be to use computer association from here. Once imported into SCCM.... they are named but obviously they are not on the domain yet. Simply add these imported computers to a baremetal collection and push your Task sequence out to them via PXE. Have them join the domain from the network settings task of your task sequence and thats it. They are pre-named via the import and on the domain via the OSD deployment. (bit long winded way of doing it but should work)

 

OR

 

use this script:

 

Dim sNewComputerName, oTaskSequence, sTSMachineName, bPromptName
Set oTaskSequence = CreateObject ("Microsoft.SMS.TSEnvironment")
' Get the name the computer is set to receive and truncate to first 6 letters
sTSMachineName = lcase(oTaskSequence("_SMSTSMachineName"))
If left(sTSMachineName,6) = "minint" Then
bPromptName = True
ElseIf sTSMachineName = "minwinpc" Then
bPromptName = True
Else
bPromptName = False
End If
' Note: The wscript.echo commands are logged in SMSTS.log for troubleshooting. They are not displayed to the end user.
If bPromptName = True Then
wscript.echo "Detected that the computer name is scheduled to receive a random value. Prompting user to input a standard name."
sNewComputerName = InputBox ("Please enter a standard computer name to continue.", "Computer Name", , 30,30)
oTaskSequence("OSDComputerName") = UCase(sNewComputerName)
wscript.echo "Set Task Sequence variable OSDComputerName to: " & sNewComputerName
Else
wscript.echo "Computer set to receive a standard name, continuing as is."
End If

 

create a package out of it and place a run command line task directly after partion disk. The command will be whatever you wish to name the script i:e promptforsystemname.vbs and also associate the package with the run command line step. The outcome will be directly after the partioning of the disk you will be prompted to add your PC name and continue. Thats it. I's not a ZTI installation......if you want this you could integrate MDT into SCCM and this gives you added functionality one been a type of autonaming......it can be configured to automatically name machines to the ASSET TAGs of the systems see this

 

Rocket Man

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...


×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.