Stop a service in a state of starting

June 22, 2011 at 09:16:06
Specs: Windows 2003
Can someone confirm if stop or taskkill from a batch file will be able to stop/kill a service that is hung in a state of "starting"? I need to stop services across multiple servers in a particular order and then restart those same services in the reverse order.


Stop service2 on server2
stop service1 on server2
stop service2 on server1
stop service1 on server1

start service1 on server1
start service2 on server1
start service1 on server2
start service2 on server2

My issue is that if a service gets hung in a state of "starting" the batch does not go on to the next step. I suspect I can simply kill the hung process and then attempt to start it again to see if that fixes the issue and allows the batch to complete.

I realize this is treating the symptom and not the issue, but I do not know of a way to replicate a hung service to determine what the root problem is.

I'm running Windows 2003 on some servers and Windows 2008 on the other servers.

Any help would be greatly appreciated.

See More: Stop a service in a state of starting

Report •

June 23, 2011 at 09:02:24
no responses, yet...I was able to find a service that took long enough in the starting state to stop works but takes a bit....taskkill /F took care of it quickly...thought I would update in case it helps anyone else

Report •
Related Solutions

Ask Question