简体   繁体   中英

Unable to Uninstall a Windows Service

I am trying to uninstall a older version of windows service in my machine and install a latest version. But when I uninstall using InstallUtil.exe /u command,I got following exception "The uninstall has completed. An exception occurred while uninstalling. This exception will be ignored and the uninstall will continue. However, the application might not be fully uninstalled after the uninstall is complete."

After this when I try to install to the latest version, I got this exception "An exception occurred during the Install phase. System.ComponentModel.Win32Exception: The specified service has been marked for deletion".

I even tried to delete the service with SC delete command. I get "The specified service has been marked for deletion" exception again. I also tried to delete the service manually from REGEDIT. But still couldn't install the service... I even tried to restart the machine. can someone help me with this???

I did face this issue, I followed the below steps, hope they work for you.

  1. Restart the system.
  2. In services.msc, stop the service and set it to disabled.
  3. Restart the system, boot in safe mode and uninstall the service.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM