Service operations fail with timeout

Issue encountered

When attempting to start, stop or pause a service, one of the following error messages is encountered:

  • Error 1053: The service did not respond to the start or control request in a timely fashion.
  • Error 7000: The <ServiceName> failed to start due to the following error: The service did not respond to the start or control request in a timely fashion.
  • Error 7009: Timeout (30000 milliseconds) waiting for the <ServiceName> service to connect.

Cause

The Microsoft Windows Service Control Manager controls the state (i.e., started, stopped, paused, etc.) of all Windows services. By default, the Service Control Manager waits 30 seconds for a service to respond. Certain configurations, technical restrictions, or performance issues, however, may result in the service taking longer to start.

Solution

Using the ServicesPipeTimeout DWORD in registry, the Service Control Manager default timeout period can be overridden.

NOTE

The following procedure requires changes to Windows registry. Problems may occur if you modify the registry incorrectly. Do not edit the Windows registry unless you are confident about doing so.

To create the ServicesPipeTimeout entry in Registry:

  1. Go to Start > Run and type regedit.
  2. Navigate to: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control
  3. Right click in the right pane and select New > DWORD.
  4. Name the new DWORD: ServicesPipeTimeout
  5. Right-click the newly created ServicesPipeTimeout entry and click Modify.
  6. Click Decimal, type 180000, and then click OK.
  7. Restart the server.