Restart services through Wise?
Does anyone know how to restart a service through Wise? I see in the service page that services can be controlled - start, stop, and delete. I need the print spooler service to stop and then start, but Wise always starts the service first which makes my package bomb as the service is already started. Is there anyway to order the services?
I tried to capture restarting the print spooler but I receive permission rights to registry keys when I execute the msi.
If there is no other way I could always force a reboot, but I was trying to avoid that.
Any help would be appreciated.
Thanks
I tried to capture restarting the print spooler but I receive permission rights to registry keys when I execute the msi.
If there is no other way I could always force a reboot, but I was trying to avoid that.
Any help would be appreciated.
Thanks
0 Comments
[ + ] Show comments
Answers (9)
Please log in to answer
Posted by:
sikkert
18 years ago
I just made a simple package (with Wise) that restarted the spooler, and had no problems there. Also, according to the SDK, the stop service SA should always come before the start SA.
Have you validated the package, to make sure that the standard actions run in the correct order? Do you get an error message when your package bombs? Anything in the event viewer?
misk:
Using a custom action for something that Windows Installer should be able to do by itself is generally a bad idea. Windows Installer have the functionality to start/stop services, so I would try to make that work first.
Have you validated the package, to make sure that the standard actions run in the correct order? Do you get an error message when your package bombs? Anything in the event viewer?
misk:
personally i would go down the custom action road my friend.
Using a custom action for something that Windows Installer should be able to do by itself is generally a bad idea. Windows Installer have the functionality to start/stop services, so I would try to make that work first.
Posted by:
rj01
18 years ago
Posted by:
brenthunter2005
18 years ago
Posted by:
sikkert
18 years ago
rj01:
I assume you have tested starting/stopping the service manually, just to check that this isn't a general problem?
Have you tried making a new package, that just stops the service and then start it again? If you put a message box or something after the "Stop Services" SA, you can also check that it really has stopped. Just remember to set the message box as a deferred CA.
I assume you have tested starting/stopping the service manually, just to check that this isn't a general problem?
Have you tried making a new package, that just stops the service and then start it again? If you put a message box or something after the "Stop Services" SA, you can also check that it really has stopped. Just remember to set the message box as a deferred CA.
Posted by:
rj01
18 years ago
Mr B Hunter,
To simplify things I put a stop only in the service page (once I get this working I will add the start option). With the stop service the package installs successfully, but I don’t see where it stopped the service.
Here are the entries for the ServiceControl table
ServiceControl – spoolsv.exe
Name – spoolsv.exe
Event – 2
Arguments – n/a
Wait – n/a
Component - ServiceControl
Can the ServiceControl field have any value?
I am new to Wise and any guidance would be appreciated.
Thanks,
rj01
To simplify things I put a stop only in the service page (once I get this working I will add the start option). With the stop service the package installs successfully, but I don’t see where it stopped the service.
Here are the entries for the ServiceControl table
ServiceControl – spoolsv.exe
Name – spoolsv.exe
Event – 2
Arguments – n/a
Wait – n/a
Component - ServiceControl
Can the ServiceControl field have any value?
I am new to Wise and any guidance would be appreciated.
Thanks,
rj01
Posted by:
brenthunter2005
18 years ago
Posted by:
rj01
18 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.