Windows Service Fails to start

Having trouble running Advanced Installer? Got a bug to report? Post it all here.
rfuller
Posts: 2
Joined: Mon Mar 08, 2010 5:32 pm

Windows Service Fails to start

Postby rfuller » Mon Mar 08, 2010 5:39 pm

I'm using Advanced installer to install a windows service. However I always get the error "Service failed to start. Verify that you have sufficient privileges to start system services."

I'm running on Windows XP.
I'm running as an Administrator.
I want to use the LocalSystem account so the username and password text boxes in the advanced installer ui are left blank.
I can install and run the service manually, myself, without any problem (using installutil).
If, after I receive the above error message I go into the Windows Services Control Panel I can start the service myself with no problem, so the installer is installing the service successfully and the services works. If, after starting the service myself, I go back into my installer program and click 'retry' it still can't start the service even though its already started. So it seems like the installer is really confused.

Can anyone help me with this?

-Ryan

rfuller
Posts: 2
Joined: Mon Mar 08, 2010 5:32 pm

Re: Windows Service Fails to start

Postby rfuller » Mon Mar 08, 2010 6:00 pm

I figured it out. By default it was trying to start a service using its file name as its service name. i had to select the actual service name from the drop down and it worked.

-Ryan

daniel.c
Posts: 4
Joined: Thu Dec 16, 2010 8:11 am

Re: Windows Service Fails to start

Postby daniel.c » Thu Dec 23, 2010 6:39 am

@rfuller:
You Sir ROCK!!
I've spent the entire day trying to figure this one out!

I believe this is a bug. Why would they set the service name to the .exe name ?????????

Thanks you so much !!

Bogdan
Posts: 2763
Joined: Tue Jul 07, 2009 7:34 am
Contact:

Re: Windows Service Fails to start

Postby Bogdan » Thu Dec 23, 2010 4:15 pm

Hi Daniel,
I believe this is a bug. Why would they set the service name to the .exe name ?????????

This is not a bug. What happens is the following:
-- the user goes to Services page and select "New Service Installation", then selects the EXE that will installed as a service
-- after it presses OK to confirm the EXE file, a new service installation and a new service control operation are added automatically
-- at this stage the user has not filled in a name for the service, so by default Advanced Installer uses the name of the EXE file

If you later choose to edit the service name, not display name, of the service from the "Services to Install" tree, please remember that you also need to update the name of the service from the "Control Operations" tree.

We will try to improve in the future this feature, so if you modify a service installation by changing the name of the service a warning is presented informing you that a control operation
for the old name of the service exists and you should update that too.

Regards,
Bgdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

daniel.c
Posts: 4
Joined: Thu Dec 16, 2010 8:11 am

Re: Windows Service Fails to start

Postby daniel.c » Thu Dec 23, 2010 11:43 pm

Thanks Bogdan.
That would be really helpful.

Sehremis
Posts: 4
Joined: Mon Nov 20, 2017 3:28 pm

Re: Windows Service Fails to start

Postby Sehremis » Thu Nov 23, 2017 12:25 pm

I'm having the same issue with my project. However, none of the above steps helped me fix it.

When running the installation file, the installer takes forever at the step "Starting Services" before eventually failing with the error message "Service 'XXX' (XXX.exe) failed to start. Verify that you have sufficient privileges to start system services." and rolling back the installation.

This also happens for the Creating a Java Service Installation Tutorial.

As for my environment, I'm running Windows Server 2016, and am logged on with the Administrator Account.

Can somebody please help me with this?
Attachments
Advanced Installer Service Start Fail.png
Advanced Installer Service Start Fail.png (91.67 KiB) Viewed 123 times

Daniel
Posts: 6535
Joined: Mon Apr 02, 2012 1:11 pm
Contact:

Re: Windows Service Fails to start

Postby Daniel » Mon Nov 27, 2017 4:56 pm

Hello,

The Java Service Example installation setup may fail during service installation if there is no 32-bit version of JRE installed on target machine. Please note that our EXE Java Launcher will search for an installed JRE to alunch the java app. So, when the service start operationis triggered our EXE Java Launcher will search for and installed JRE to launch the java app. If none found then the start operation will fail.

In what regards your own service app installation, I suggest you to try installing and starting the service manually (outside of the setup package) and make sure it successfully works. For instance you can use the sc.exe Windows tool to manually install and start your service app.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube


Return to “Common Problems”

Who is online

Users browsing this forum: Eusebiu, Sorin and 2 guests