Finding Out Why a Service Won't Start

  • Section(s): Admin
  • Created on Sep 01, 2006.
  • Last Modified on Jan 03, 2007.
  • Last Modified by Mitch Tulloch.
  • Rated 4 out of 5 based on 4 votes.
How to display service exit codes.
If you want to know whether a particular Windows service started successfully when your machine booted up, you can use the sc query command to do this. Simply run the command sc query service_name and look for the WIN32_EXIT_CODE field in the output of the command. If this field is zero then the service started properly, and if the service didn't start properly then WIN32_EXIT_CODE will display a non-zero exit code specific to the service.

For example, when I run the command sc query vss to query the status of the Volume Shadow Copy service on a Windows Server 2003 machine, the WIN32_EXIT_CODE value returned is 1077 (0x435). To find out what this exit code means, you can type net helpmsg 1077, and the result of doing this is "No attempts to start the service have been made since the last boot." This likely indicates that the Startup Type for this service is Manual i.e. the service isn't set to start automatically upon reboot.

Mitch Tulloch is President of MTIT Enterprises, an IT content development company based in Winnipeg, Canada. Prior to starting his own company in 1998, Mitch worked as a Microsoft Certified Trainer (MCT) for Productivity Point International. Mitch is a widely recognized expert on Windows administration, networking and security and has written 14 books and over a hundred articles on various topics. He has been repeatedly awarded Most Valuable Professional (MVP) status by Microsoft for his outstanding contributions in supporting users who deploy Microsoft platforms, products and solutions. Mitch is also a professor at Jones International University (JIU) where he teaches graduate-level courses in Information Security Management (ISM) for their Masters of Business Administration (MBA) program. For more information see http://www.mtit.com.

Article not looking right or info is missing? Let us know so that we can fix it: .


Receive all the latest articles by email!

Receive Real-Time & Monthly WindowsNetworking.com article updates in your mailbox. Enter your email below!
Click for Real-Time sample & Monthly sample

Become a WindowsNetworking.com member!

Discuss your network issues with thousands of other network administrators. Click here to join!

Community Area

Log in | Register

Readers' Choice

Which is your preferred Anti Virus Appliance solution?