views:

4250

answers:

4

How do I uninstall a Windows Service when there is no executable for it left on the system? I can not run installutil -u since there is not executable left on the system. I can still see an entry for the service in the Services console.

The reason for this state is probably because of a problem in the msi package that does not remove the service correctly, but how do I fix it once the service is in this state?

+1  A: 

Create a copy of executables of same service and paste it on the same path of the existing service and then uninstall.

Samiksha
That's a good suggestion. If that doesn't work he may need to reinstall, run installutil -u, and then uninstall
wcm
+4  A: 

found here

I just tried on windows XP, it worked

local computer: sc \\. delete [service-name]

  Deleting services in Windows Server 2003

  We can use sc.exe in the Windows Server 2003 to control services, create services and delete services. Since some people thought they must directly modify the registry to delete a service, I would like to share how to use sc.exe to delete a service without directly modifying the registry so that decreased the possibility for system failures.

  To delete a service: 

  Click “start“ - “run“, and then enter “cmd“ to open Microsoft Command Console.

  Enter command:

  sc servername delete servicename

  For instance, sc \\dc delete myservice

  (Note: In this example, dc is my Domain Controller Server name, which is not the local machine, myservice is the name of the service I want to delete on the DC server.)

  Below is the official help of all sc functions:

  DESCRIPTION:
    SC is a command line program used for communicating with the
    NT Service Controller and services. 
  USAGE:
          sc
Fredou
+8  A: 

You should be able to uninstall it using sc.exe (I think it is included in the Windows Resource Kit) by calling

sc.exe delete <service name>

where <service name> is the name of the service itself as you see it in the service management console, not of the exe.

Alternatively, you can directly call the DeleteService() api. That way is a little more complex, since you need to get a handle to the service control manager via OpenSCManager() and so on, but on the other hand it gives you more control over what is happening.

Treb
It did exactly what I wanted and removed the service from the registry. It doesn't show up in the Services console any more. Thanks!
Manga Lee
i used installultil command but sc also works well....
dankyy1
+1  A: 

My favourite way of doing this is to use Sysinternals Autoruns application. Just select the service and press delete.

Thomas Bratt