Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Question
Friday, August 4, 2017 12:37 PM | 1 vote
I have ServiceA, ServiceB, and ServiceC. ServiceB depends on ServiceA, ServiceC depends on ServiceB.
Dependency chain:
ServiceA <- ServiceB <- ServiceC
When I open Services desktop app ( Services.msc ), then click on ServiceA and hit restart, I get an error:
Error 1051 Stop Control has been sent to a service that other running services are dependent on
The problem is that windows attempts to stop ServiceB before ServiceC.
This setup works in pre-Windows 10 systems. In pre-Windows 10, ServiceC would be stopped first then ServiceB then A.
I have tried altering the order in which I set the dependencies. I have tried creating a servicegroup and setting the startup order in the registry under GroupOrderList. Nothing has any effect, and the restarting always picks the same order and fails.
From powershell, I can run restart-service ServiceA -force, and all services restart correctly without an error.
This appears to be an issue with the Windows service manager.
All replies (8)
Tuesday, August 8, 2017 2:56 AM
Hi Summer,
That's normal behavior.
The Restart-Service cmdlet sends a stop message and then a start message to the Windows Service Controller for a specified service. If you specify -force parameter, it means override restrictions that prevent the command from succeeding, e.g. stop and restart a service that has dependent services.
However, Windows Server manager launched via **services.msc **you mentioned is not running with force parameter when you click restart button there.
Thus if you want to do that, either stop the dependent services first, then retry or use the PowerShell command line to restart.
Please remember to mark the replies as answers if they help.
If you have feedback for TechNet Subscriber Support, contact [email protected].
Tuesday, August 8, 2017 1:50 PM
When you click restart in services.msc, it does attempt to restart the dependent services. However, it chooses the incorrect order. Is there a way to specifiy which order it chooses?
Wednesday, August 9, 2017 9:10 AM
When you click restart in services.msc, it does attempt to restart the dependent services. However, it chooses the incorrect order. Is there a way to specifiy which order it chooses?
No, when click the restart button in services.msc window, it only attempt to restart the current service that you selected and not restart the dependent services.
You may need to stop the dependent service first then try again.
Please remember to mark the replies as answers if they help.
If you have feedback for TechNet Subscriber Support, contact [email protected].
Monday, August 14, 2017 2:37 PM
I'm sorry, but that is not true. When you click a service and click restart, this window appears and attempts to restart all dependent services.
Wednesday, August 16, 2017 8:41 AM
Hi Summer,
Yes, it will attempt to restart the dependent services but not forcedly as with -force parameter.
Please remember to mark the replies as answers if they help.
If you have feedback for TechNet Subscriber Support, contact [email protected].
Wednesday, August 16, 2017 10:13 PM
So my question is this: is there a way to control which order the services.msc attempts to restart the dependent services?
Friday, August 18, 2017 8:48 AM
So my question is this: is there a way to control which order the services.msc attempts to restart the dependent services?
No way.
Please remember to mark the replies as answers if they help.
If you have feedback for TechNet Subscriber Support, contact [email protected].
Thursday, October 12, 2017 10:28 AM | 1 vote
Hi,
we have the same issue. On 1607 the dependencies are stopped correctly, on 1703 they are not anymore. So something seems to have been broken between the 2 builds. So there used to be a correct way to do this that worked until recently!
Mircea