MSI - Windows Service Restart
Hi all,
I want to create a shortcut that restarts two win32 services (the services themselves have no dependencies).
I was thinking of using an MSI with an Advertised shortcut and the Service Control table however I'm struggling. I get..... insufficient privelidges (1920.). I have.... run as admin, assigned priviledges to the files (to test), specified my user credentials within the Service Control table (again to test). I have manually started the services ok and can start them from the comand line so I'm either missing something or the permissions error is a bit of a red herring.
I'm familiiar with the use of SHIMs and SecEdit but not so much the ServiceControl table.
Any help\ideas would be appreciated.
Win7, x86, Installshield
Answers (1)
Top Answer
why do you need to re-start the services via a shortcut?
You can create and start the services via the SC table. This includes starting them on install and stopping them before de-installation...
Which tool are you using?
Cheers
Phil
Comments:
-
Thanks for the reply.
I'm using Installshield 2014.
I want to allow the services to be restarted by the user base (who wont have permisisons\knowledge to do this through services.msc). My thinking is therefore that I place a shortcut that the users can use to restart the services.
I have been trying what you suggested with an advertised shortcut and the SC table however thats where my1920 ERROR is coming from. The error itself says you dont have permissions, yet I can start the services from both the command line and manually through the using the same credentials. - Busby101 8 years ago-
OK,
the MSI will have to be installed as an Admin / System. Using SecEdit you can create a security.inf file that would (for example) allow authorised users to control (start and stop) the services. This can be implemented using a CA (don't know if IS 2014 can import security.inf files and apply them correctly). Then you can create the short cuts to start / stop the services. - Pressanykey 8 years ago