1 2 Previous Next 15 Replies Latest reply on Oct 26, 2012 4:48 PM by JSMCPN

    Computername during OSD deployment

    Rookie

      As above I would like to ask how I go about being prompted during OSD to manually enter a hostname for the PC. I have tried other suggestions like removing the <ComputerName>%COMPUTERNAME%</ComputerName> in the xml file, but it still autocompletes it, without prompting? I use simple OSD and none of this provisioning, so if its possible that would be great, unless it might mean that the only way is to use provisioning! Thanks in advance.

        • 1. Re: Computername during OSD deployment
          EMiranda Expert

          are you taking the whole line out? or just the %COMPUTERNAME% part.

           

          i take the whole line out from < to >  and it prompts me.

          • 2. Re: Computername during OSD deployment
            Rookie

            I took whole line out. It went between

            <component name="Micr...

            <component name="Micr..

            but it still auto assigned computername?

             

            - <settings pass="specialize">

              <component name="Microsoft-Windows-Shell-Setup" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" processorArchitecture="x86" />

            - <component name="Microsoft-Windows-UnattendedJoin" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" processorArchitecture="x86">

            - <Identification>

            - <Credentials>

              <Domain>TPMDE</Domain>

              <Username>administrator</Username>

              <Password>***********</Password>

              </Credentials>

              <JoinDomain>*******/JoinDomain>

              </Identification>

            • 3. Re: Computername during OSD deployment
              MrGadget Expert

              First of all you didn't say what OS you were imaging so I will assume Windows 7 and there seems to be a difference between imaging XP and windows 7.

              After some exhaustive research it seemed like those that were imaging xp could take out the line and it would prompt for a name.

              I found a article that said in Windows 7 nothing you can do with the computername line in the specialize section of the unattend file would get it to prompt for a name.

               

              Unfortunately this only may answer the why can't I but not the how to. I am still searching for a answer myself. WE (OSD) image then on boot up add the name and join it to the domain.

              • 4. Re: Computername during OSD deployment
                EMiranda Expert

                The OP posted examples from a XML and syntax from a Windows 7 sysprep file (windows xp uses an .ini / .inf sysprep)   So it was safe to assume huge OP was referring to Windows 7. I can assure you that you can prompt a computer name from a windows 7 sysprep process, we do it all the time where I work. I will post my sysprep and screen capture of what the computer prompt screen looks like on Monday morning when I get into the office and try my best to help you out. Have a good weekend!

                • 5. Re: Computername during OSD deployment
                  Frank Wils ITSMMVPGroup

                  You can also add a step in the WindowsPE phase of Provisioning after deploying the image to have a vbscript generate a popup that prompts for a computername and replaces a variable in the unattand.xml. That way you can also use the Provisioning variable of the Computername as known in LANDesk on the command line and only pop up when no known name exists.

                   

                  If you arent good in scripting, let me know and i can send you an example.

                   

                  Frank

                  • 6. Re: Computername during OSD deployment
                    EMiranda Expert
                     <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                                <CopyProfile>true</CopyProfile>
                                <ProductKey>12345-12345-12345-12345-12345</ProductKey>
                                <RegisteredOrganization>Company Name</RegisteredOrganization>
                                <RegisteredOwner>Company Name</RegisteredOwner>
                                <ShowWindowsLive>false</ShowWindowsLive>
                                <ComputerName>%COMPUTERNAME%</ComputerName>
                                <TimeZone>Eastern Standard Time</TimeZone>
                            </component>
                    
                    
                    

                     

                     

                    Above is an example of my sysprep .xml file.  The following will NOT prompt for the computer name because the <ComputerName> Tags are in place.  In this case LANDesk will use tokreplw to inject the value of the computer name to replace %COMPUTERNAME% variable.

                     

                    <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">  
                                <CopyProfile>true</CopyProfile>
                                <ProductKey>12345-12345-12345-12345-12345</ProductKey>
                                <RegisteredOrganization>Company Name</RegisteredOrganization>
                                <RegisteredOwner>Company Name</RegisteredOwner>
                                <ShowWindowsLive>false</ShowWindowsLive>
                                <TimeZone>Eastern Standard Time</TimeZone>
                            </component>
                    
                    

                     

                    Above i completly omitted the <ComputerName> tag from the .xml (you have to do this manually.  I use Notepad++ or you can just use normal Notepad).

                     

                    When this is done, sysprep has no way to process the ComputerName tag and will prompt a screen just like this:

                     

                    Imageprocessnew6.jpg

                     

                    Hope this info helps!  and as stated before i post this you can always write a prompt script to prompt for a ComputerName input and pass those values into your sysprep.

                    • 7. Re: Computername during OSD deployment
                      EMiranda Expert

                      It is also just as important to know what sysprep .xml you are modifing.  LANDesk likes to make copies, so you may be modifying one, but LANDesk is using a different un-modified one. Make sure the one you are modifying is the correct one!  you can verify afterwards by looking at the sysprep file that was processed by sysprep and that is always going to be stored here - c:\windows\panther\unattend.xml

                      • 8. Re: Computername during OSD deployment
                        Rookie

                        Hi EMiranda, thanks for the screenshots, however when i look at my xml file, i notice that command line is in slightly different section, to yours in the settings pass specialize section? Do you know which settings pass your lines arew from? References to product key in my file appears in the oobe pass section.

                        Thanks

                         

                        - <settings pass="specialize">

                        - <component name="Microsoft-Windows-Shell-Setup" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" processorArchitecture="x86">

                        <ComputerName>%COMPUTERNAME%</ComputerName>

                        </component>

                        - <component name="Microsoft-Windows-UnattendedJoin" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" processorArchitecture="x86">

                        - <Identification>

                        - <Credentials>

                        <Domain>TPMDE</Domain>

                        <Username>administrator</Username>

                        • 9. Re: Computername during OSD deployment
                          JSMCPN Expert

                          I've written an AutoIT/VBscript just for this purpose!  It provies the best of both worlds - you let LANDesk inject a computer name, but have a chance to override during a Provisioning template.

                           

                          1 - In WinPE, Provisioning action launches script and waits a configurable number of seconds before moving on.

                          1.png

                          2 - Supply a computer name

                          2.png

                          3 - Script checks the hostname length and illegal characters

                          3.png

                          4 - Once validated, script displays old name and new name.

                          4.png

                          Unattend XML before:

                          5.png

                          6.png

                          Unattend XML after!

                          7.png

                          • 10. Re: Computername during OSD deployment
                            Tracy Expert

                            Hey Jesse.. How about attaching your super sweet utility. I'd like to give it a try.

                             

                            -Tracy

                            • 11. Re: Computername during OSD deployment
                              Specialist

                              I'd like to get my hands on this script as well...

                               

                              Dave

                              • 12. Re: Computername during OSD deployment
                                JSMCPN Expert

                                Stay tuned.  I'll upload IF I can.

                                • 13. Re: Computername during OSD deployment
                                  psythian Apprentice

                                  Jesse, is there anyway I can test out that Script? Does it prompt at the Console or at the imaging workstation?

                                  • 14. Re: Computername during OSD deployment
                                    JSMCPN Expert

                                    Yep.  I am working on some enhancements and when the new version is ready I'll post it on the Community.

                                     

                                    New version will allow you to specify any Unattend XML path and filename.  Previously it was hard coded to look for C:\Unattend.xml but now the syntax will be:

                                     

                                    CompName.exe 500 "C:\Path\To Anything\YouWant.xml"

                                     

                                    compname2.jpg

                                    1 2 Previous Next