2 Replies Latest reply on Oct 1, 2018 2:48 AM by Gisslén

    After reboot custom action is not running until user logon when deploying Windows 10 1803

    Gisslén Rookie



      When we upgraded from Windows 10 1507 to 1709 we used a batch file in a custom action (after reboot) to change the default wallaper file. That way all users got our custom wallpaper at first logon.


      We are now trying to do the same thing when upgrading from 1709 to 1803, but the batch file that changes the wallpaper is not run until a user is logging on, and at that time the user have already gotten Windows default wallpaper. Is this by design? Shouldn't the batch file be run during reboot, before users can logon?


      Custom Actions:

      Push File: <filepath>\ChangeWallaper.bat

      Push File: <filepath>\img0.jpg (our custom wallpaper file)

      After reboot: call %PATHTOFIXES%ChangeWallpaper.bat


      All files are pushed out correctly and the batch file works, but it is just executed at the wrong time.


      The last 5 lines in STDeploy.log before user logon:

      2018-05-25T12:41:59.2986567Z 1bd4 I STPackageDeployer.cpp:478 Launching SafeReboot. deployerSpecifiedRebootRequired=true

      2018-05-25T12:41:59.2986567Z 1bd4 I STPackageDeployer.cpp:390 SafeReboot command line: '"C:\windows\ProPatches\Installation\InstallationSandbox#2018-05-25-T-12-09-18\SafeReboot.exe" -o 8 -requestor 1 -power 4'

      2018-05-25T12:41:59.4393167Z 1bd4 S DeployExeStates.cpp:409 Leaving STDeploy::CInitialExecutionPackageDeploy::DoStatefulRemediateActions.

      2018-05-25T12:41:59.4393167Z 1bd4 I STDeploy.cpp:365 Current remediation phase completed. Process exit code: 3010.

      2018-05-25T12:41:59.4393167Z 1bd4 S STDeploy.cpp:257 Leaving wmain.


      And the first 5 lines after user logon:

      2018-05-25T14:36:40.5522428Z 0fd8 S STDeploy.cpp:257 Entering wmain.

      2018-05-25T14:36:40.6710626Z 0fd8 I STDeploy.cpp:262 'C:\windows\ProPatches\Installation\InstallationSandbox#2018-05-25-T-12-09-18\STDeploy.exe' is starting, version: 9.3.2708.0.

      2018-05-25T14:36:40.8110531Z 0fd8 V DeployContext.cpp:259 STDeploy.exe command line args: 'package="C:\windows\ProPatches\Installation\InstallationSandbox#2018-05-25-T-12-09-18\deployPackage-16946.zip" "relaunchSandbox=C:\windows\ProPatches\Installation\InstallationSandbox#2018-05-25-T-12-09-18" "relaunchReason=afterPostDeploymentReboot=1"'

      2018-05-25T14:36:40.8110531Z 0fd8 S DeployExeStates.cpp:344 Entering STDeploy::CExtendedCmdLineHandlingPackageDeploy::ProcessExtendedCmdLineArguments.

      2018-05-25T14:36:40.8804006Z 0fd8 S DeployExeStates.cpp:344 Leaving STDeploy::CExtendedCmdLineHandlingPackageDeploy::ProcessExtendedCmdLineArguments.


      After a while the batch file is executed.

      2018-05-25T14:37:22.7928924Z 0fd8 I ChildProcess.cpp:114 Started C:\WINDOWS\sysnative\cmd.exe /U /Q /D /V:ON /C "call %PATHTOFIXES%ChangeWallpaper.bat"