How to create a Service under Win Vista
Updated: 21 May 2010 | 11 comments
I want to create as System Admin a Service under Win Vista with Wise Script Editor (Create Service), which should execute an other EXE-File (created with Wise Script Editor too) as System Admin. In this EXE-File, executed once by the Service, an MSI should be installed.
By starting the service manually I always receive Error 1053: The service did not respond to the start or control request... and the service does not start and the MSI is not installed.
Any ideas how to create such a service under Win Vista?
discussion Filed Under:
Comments
The arrangement you have...
...seems needlessly complicated. Why not simply use the MSI to create the service?
Don't know why 'x' happened? Want to know why 'y' happened? Use ProcMon and it will tell you.
Think about using http://www.google.com before posting.
Sorry, VBScab, the
Sorry, VBScab, the description was not complet enough.
There are 3 MSI's to be installed by the EXE-File, each after the other and controlled by a While-Loop regarding the correct Error-Code (0). And after the installaton of the last one, the service shoud by stopped and disabled by the EXE-File.
Still appears over complex
Just deploy the MSI files individually - it makes no sense to use a service to do this.
If your issue has been solved, please use the "Mark as Solution" link on the most relevant thread.
...Is there any good reason
...Is there any good reason behind this approach/logic?
As an alternative for the error you receive you may also try out using SC command in the command prompt to create service of your choice and check out.
Hope it helps!!
The reason is...
The reason is the following: We are deploying via SMS/SCCM a VPN-Application based on Internet Explorer.
If a user is connected via active VPN e.g. IE, it is not possible to upgrade or update this application. Therefore the necessary files will be copied via SMS/SCCM on the local machine and, if VPN/IE is not active, the created service will be able (in a System Admin-Context) to install this update.
I hope, somebody has a solution for this request, Thanks anyway
Does the SCCM job interact with the user?
If so, all you need is a Custom Action in the MSI (which SCCM will copy locally before executing) which checks for the IE and VPN processes. If either is active, the user gets prompted to close them. As soon as the processes are shut down, the CA progresses.
If the job isn't interactive, write to the WI log that the processes were present and that the install was therefore aborted.
If my understanding of SCCM is correct, th ejob will keep executing until it succeeds or the advertisement expires.
Don't know why 'x' happened? Want to know why 'y' happened? Use ProcMon and it will tell you.
Think about using http://www.google.com before posting.
Yes, but...
... the VPN-Application consists of three different MSI's to be installed. I can place the Custom Action in the first MSI, which will check the active VPN/IE. But what's about the two others? Nested MSI's are not best practive, or?
The other scenario is: The user has an active VPN-Connecton and SCCM therefore only copies the necessary files to the local hard disk. The user keeps connected, then close the connection and makes a shutdown. After the restart of the machine he will no more be able to install the files as there is no connection and therefore no SCCM available. And the user has no priviliges to install the MSI's himselve.
My "nice" idea was, that a service could do this in a System Admin-Context (e.g. after the restart, starting the service, checking VPN/IE-Connection, installing the files, stopping and disabling himselve)...
Thanks for your help
ResLi
Question
Do all three MSI files have to have the VPN inactive when installing?
If your issue has been solved, please use the "Mark as Solution" link on the most relevant thread.
Yes,
i think so as all 3 MSI files belong to the entire VPN-installation.
Question/Problem solved...
Do you need a service at all?
To install the service, you are going to need administrator access. If you know the admin account and password, you could use the "RUNAS" wisescript from Dragonsoft (http://wisescript.dragonsoft.us/scripts_5.php) to run your install with admin privileges. The install could be triggered using the RunOnce registry key so that it gets started during bootup before the user has time to open any apps. Since the wisescript is compiled, the admin password is hidden.
If your issue has been solved, please use the "Mark as Solution" link on the most relevant thread.
Would you like to reply?
Login or Register to post your comment.