How to run a pre and post script for Windows update procedures

Hi,

For patch management, the only option is to create a windows patch procedure. However with that we cannot specify any custom actions that should happen pre and post installation. For e.g. this is what we want to do whenever we want to install the patches on the endpoints:

→ Create a restore point
→ Patch installation
→ Run cleanup task.

The other RMM tools have this option e.g. Virtual System Administrator

Hello @myr ,

Thank you very much for submitting your request. We will check this in deep and will inform you as soon as possible.

Best regards,
Ilgaz

1 Like

Hi @myr ,

Please try this script in JSON as a workaround for your request
20221130_1_update.json (6.6 KB)

Kind Regards,
PremJK

Hi,
Thanks for the procedure script. Though I am going to test it out in next couple of days, I have the following questions in the meanwhile:

→ Will it handle the reboot?
→ If it handles the reboot, will it show the status as “PENDING REBOOT” in the procedure status as it normally shows with the default patch procedure?

Regards,
myr

Hello @myr ,

The script currently doesn’t check whether a patch requires reboot or not. Therefore the endpoint will be rebooted automatically upon patch installation if the patch requires a reboot.

We will provide you with an updated version of the script to allow you to suppress the reboot, and you will be able to see the appropriate status (“pending reboot” in this case) for the installed patches in Patch Management section.

Best regards,
Ilgaz

Thanks I will wait for it. The Ops team gave the feedback that the status is showing SUCCESS without checking the actual status of the KB install state. So I guess the behaviour should be same as what we normally get when we execute the patch procedure. Your R&D will have a view on its actual python code.

Hi,
Any update on this. I opened a support ticket as well but they are saying that its not possible to get multiple status as once the workstation is rebooted it will either send SUCCESS or FAILED status.

Hi @myr , we are going to deeply analyze the feature request and then we will prioritize it.