Navigation

    • Register
    • Login
    • Search
    • Recent
    • Popular

    creating base image

    Support
    2
    13
    875
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • T
      tomas.hook @theopenem_admin last edited by

      @theopenem_admin Thank you for explanation.
      Finally, I put that time server settings into unatended.xml file for sysprep. That works for me just fine.
      For info how to call cmd script from sysprep:

      <settings pass="specialize">
      		<component name="Microsoft-Windows-Deployment" 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">
                  <RunSynchronous>
                      <RunSynchronousCommand wcm:action="add">
                          <Order>1</Order>
                          <Path>c:\Windows\system32\cmd.exe /c c:\intel\synctime.cmd</Path>
                      </RunSynchronousCommand>
                  </RunSynchronous>
              </component>
          </settings>
      

      Tomas

      1 Reply Last reply Reply Quote 0
      • T
        tomas.hook @theopenem_admin last edited by tomas.hook

        @theopenem_admin - I made many of reinstallation and tests, but the file "setupcompletecmd_complete" is never created on my machines. (image_prepped is present after imaging).

        So, if I do "domain join" policy with condition on "setupcompletecmd_complete" policies are not started

        • if I login under admin I don't see that file (policies never run and sysprep looks finished)

        and in opposite if I do test on "image_prepped" computer is joined to domain, and other following policies apply (include collect inventory), and finally "Image Prep Cleanup"

        • so hard to say if "setupcompletecmd_complete" is present

        Other observation is: file c:\Windows\System32\Sysprep\Sysprep_succeeded.tag was created.

        Tomas

        1 Reply Last reply Reply Quote 0
        • T
          theopenem_admin last edited by

          What's in your setup complete template?

          T 1 Reply Last reply Reply Quote 0
          • T
            tomas.hook @theopenem_admin last edited by

            @theopenem_admin it's default (Toec Image Prep without server access because time server is not setup yet, but during sysprep later):

            mkdir "%ProgramFiles%\Toec"
            net stop toec /y >> "%ProgramFiles%\Toec\setupcomplete.log"
            powercfg.exe /h off >> "%ProgramFiles%\Toec\setupcomplete.log"
            copy NUL "%ProgramFiles%\Toec\setupcompletecmd_complete" >> "%ProgramFiles%\Toec\setupcomplete.log"
            del /Q /F c:\windows\system32\sysprep\unattend.xml >> "%ProgramFiles%\Toec\setupcomplete.log" 
            del /Q /F c:\windows\panther\unattend.xml >> "%ProgramFiles%\Toec\setupcomplete.log"
            
            REM ####### Driver install ###########
            PowerShell ^
            $Drivers = Get-ChildItem "C:\drivers" -Recurse -Filter "*.inf" ;^
            ForEach($Driver in $Drivers) {;^
            $args = \"/add-driver $($Driver.FullName) /install \";^
            $p = (Start-Process -FilePath pnputil.exe -ArgumentList $args -NoNewWindow -Passthru);^
            Wait-Process -Id $p.Id -Timeout 10 >> "%ProgramFiles%\Toec\setupcomplete.log";^
            };^
            %End PowerShell%
            
            net start toec /y
            
            

            Tomas

            T 1 Reply Last reply Reply Quote 0
            • T
              tomas.hook @tomas.hook last edited by

              @tomas-hook Just to be clear - I run "Toec Image Prep" without server connection. Simillar to older version when this feature was not present.

              1 Reply Last reply Reply Quote 0
              • T
                theopenem_admin last edited by

                It should be created from this line.

                copy NUL "%ProgramFiles%\Toec\setupcompletecmd_complete"

                I wonder if your setupcomplete.cmd isn't running for some reason. After you deploy the image, does the file exist at C:\Windows\Setup\scripts

                T 1 Reply Last reply Reply Quote 0
                • T
                  tomas.hook @theopenem_admin last edited by

                  @theopenem_admin said in creating base image:

                  After you deploy the image, does the file exist at C:\Windows\Setup\scripts

                  Well, I was not sure either, because:

                  • I never saw "%Program Files%\Toec\setupcomplete.log" file.
                  • c:\windows\panter\unattend.xml exists.
                  • c:\windows\system32\sysprep\unattend.xml exists.

                  File "c:\windows\setup\scripts\setupcomplete" exists on my deployed machine.

                  1 Reply Last reply Reply Quote 0
                  • T
                    theopenem_admin last edited by

                    It sounds like it's not running then, but I'm not sure why. Windows should run that file automatically if it exists in that location. I've never seen it not run.

                    T 1 Reply Last reply Reply Quote 0
                    • T
                      tomas.hook @theopenem_admin last edited by

                      @theopenem_admin There is exception for this script, and unfortunately I used installation file that match with exception.

                      Documentation:

                      %WINDIR%\Setup\Scripts\SetupComplete.cmd: This script runs with local system permissions and starts immediately after the user sees the desktop. This setting is disabled when using OEM product keys, except on Enterprise editions and Windows Server operating systems.

                      Setupact.log from ../Panther/UnattendGC

                      2022-08-10 18_02_21-TheOpenEM-TEST-step-by-stepWimage06 on esxi2.olcc.state.or.us.png

                      1 Reply Last reply Reply Quote 0
                      • T
                        theopenem_admin last edited by

                        Hmm, I never knew that setup complete would not run with an OEM license. I guess you would just need to change your policies a little to work with your setup.

                        1 Reply Last reply Reply Quote 0