-
×InformationNeed Windows 11 help?Check documents on compatibility, FAQs, upgrade information and available fixes.
Windows 11 Support Center. -
-
×InformationNeed Windows 11 help?Check documents on compatibility, FAQs, upgrade information and available fixes.
Windows 11 Support Center. -
- HP Community
- Desktops
- Business PCs, Workstations and Point of Sale Systems
- t520 thin client HPDM task to run Windows update

Create an account on the HP Community to personalize your profile and ask a question
08-10-2017 08:10 AM
Hi,
We are trying to push an update to Windows 10 IoT thin clients to resolve a memory leak in the UWF.
We could reimage the entire fleet, but given some small tweaks on a user by user basis for things such as handedness (lefty or righty), this is less than desirable.
I am trying to create a task sequence to deploy and install the update automatically. I have the sequence to the point where it runs a script to run the .msu installer, but the task now fails with error 14004022.
I think this is because the agent doesn't return a successful result of the script, which contains this command:
c:\kb3205436.msu /quiet /norestart
I have put the /norestart as suggested in the HPDM documentation, as otherwise the machine will reboot and not return a script result. I know the update has finished installing, as if I reboot the device, it finishes configuring the update.
I need to know how to get the command to return a successful result to the HPDM agent, so that the next task in the sequence can trigger and run.
Thanks
James
Solved! Go to Solution.
Accepted Solutions
08-14-2017 07:24 PM - edited 08-14-2017 07:28 PM
You're right, by default HPDM returns "successful" only when the return code is 0.
Use the script below to let DM task accept the customized return code:
Install.exe
IF %ERRORLEVEL% EQU <customized success return code> GOTO END
If %ERRORLEVEL% EQU 0 GOTO END
:END
Check the white paper - Troubleshooting_Guide_CommandLine_Task_WES for more details. You can access the paper by clicking the help menu on HPDM Console.
My opinions are my own, and do not express those of HPI.
**Click the White Thumbs Up Button on the right to say Thanks**
08-14-2017 07:24 PM - edited 08-14-2017 07:28 PM
You're right, by default HPDM returns "successful" only when the return code is 0.
Use the script below to let DM task accept the customized return code:
Install.exe
IF %ERRORLEVEL% EQU <customized success return code> GOTO END
If %ERRORLEVEL% EQU 0 GOTO END
:END
Check the white paper - Troubleshooting_Guide_CommandLine_Task_WES for more details. You can access the paper by clicking the help menu on HPDM Console.
My opinions are my own, and do not express those of HPI.
**Click the White Thumbs Up Button on the right to say Thanks**
08-15-2017 02:53 AM
Hi Chen,
How do we know what the customised error code is going to be?
Given that our script contains only a single command, which is this:
c:\kb3205436.msu /quiet /norestart
We do not specify our own return code, as we are expecting this command to complete and return a normal return code of 0.
Do we need to run the script and output the error code to a text file to determine what results the script completes with?
Many thanks
James
08-15-2017 02:58 AM
It was mentioned in the white paper:
- Create a batch script that contains the command line and add the tag (echo %ERRORLEVEL%) in the last line. Run the batch script to see the return code of the command.
If that is MSI from microsoft, usually the return is 3130. You'd better double confirm it before finalziing your script.
My opinions are my own, and do not express those of HPI.
**Click the White Thumbs Up Button on the right to say Thanks**
08-15-2017 03:14 AM
I see.
I have recreated the script directly on the thin client as c:\test.bat
It contains 3 lines:
C:\kb3205346.msu /quiet /norestart
echo %ERRORLEVEL%
pause
Hopefully this will mean I can get the error code once the installer completes, and combine that with your original suggestion to get a successful return result when issuing the command via HPDM.
Cheers
James