ybe
Posts: 14
Joined: Fri Oct 09, 2020 9:27 am

Service still running after uninstall

Fri Oct 15, 2021 11:54 am

Hello

I'm using Advanced Installer on my Application. My application has an agent that runs a service in the background. For some reason, when I uninstall the application, once it finishes uninstalling the service is still existing and even still running in the background.

So because the service is not uninstalled with the Application, it's not possible to install the application again after uninstalling it, unless you manually go in and stop the service.

How do I make sure that the service is stopped and deleted in the uninstall process?

Kind regards
Ybe

Liviu
Posts: 199
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: Service still running after uninstall

Fri Oct 15, 2021 1:19 pm

Hello Ybe,
How do I make sure that the service is stopped and deleted in the uninstall process?
This can be easily set from the "Services" page, using a control operation.

If you do not use our support to launch the service, you can also use the "Stop service" custom action from the "Custom Actions" page and schedule it to be executed only on uninstall. You need to make sure that the service name you add is correct.
StopService.png
StopService.png (880.55KiB)Viewed 5208 times
So because the service is not uninstalled with the Application, it's not possible to install the application again after uninstalling it, unless you manually go in and stop the service.
Also, the above solution can work here too, in the newer version you can add the "Stop service" custom action.

Let me know if that helped you.

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

ybe
Posts: 14
Joined: Fri Oct 09, 2020 9:27 am

Re: Service still running after uninstall

Thu Oct 21, 2021 9:39 am

Hello

Thank you!

The Control Operation under Services was already set to stop and delete on uninstall, but it didn't work. however the "StopService" Custom Action made the service stop on uninstall. How do I delete the service using Custom Actions. I don't want to just stop it, I want to delete it also. The app should not leave services after uninstall. Is that something you can help with?

Kind regards
Ybe

Liviu
Posts: 199
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: Service still running after uninstall

Thu Oct 21, 2021 2:41 pm

Hi Ybe,

This is quite strange. The service should be deleted, I'm not really sure why this happens.

In order for us to further investigate this issue, can you please send us by email to support at advancedinstaller dot com, the following resources:

1. the .AIP (setup project) file.
2. an uninstallation log.
3. a download link for your setup package.
so we can fully test this scenario.

In order to generate an uninstall log, you can use a command line as it follows:

Code: Select all

msiexec /x "C:\MyPackage\Example.msi" /L*V "C:\log\example.log"

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

ybe
Posts: 14
Joined: Fri Oct 09, 2020 9:27 am

Re: Service still running after uninstall

Fri Oct 22, 2021 10:39 am

The mail is sent.

Kind Regards
Youssef

Liviu
Posts: 199
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: Service still running after uninstall

Fri Oct 22, 2021 11:03 am

Hello Youssef,

I have replied to you over the email.

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”