开发者

Decrementing counter to disable shutdown. If counter >= 0, shutdown will be denied. Counter after decrement: -1

开发者 https://www.devze.com 2023-02-18 13:52 出处:网络
I use msiexec.msi line command to run a msi file created using WIX, the setup is runn with the parameter /qb and /promptrestart, but if I get the line

I use msiexec.msi line command to run a msi file created using WIX, the setup is runn with the parameter /qb and /promptrestart, but if I get the line "Decrementing counter to disable shutdown. If counter >= 0, shutdown will be denied. Counter after decrement: -1" in log the prompt didn't appear. The exit code of the msiexec process is 0 not 3010 (need restart) but the service that must be uninstalled remain in services.msc mark开发者_高级运维ed for deletion and some time even running (during install/uninstall services.msc is closed). After restart the computer all works fine.

Could you please tell me how to detect that a restart is required?


Windows Installer is not very reliable when it comes to handling reboots. A good approach is to determine yourself if the install or uninstall process requires a reboot and trigger it manually if it does.

To perform a reboot you can use the REBOOT property.


You might also want to ensure the service isn't running through a custom action.

0

精彩评论

暂无评论...
验证码 换一张
取 消