How can I verify the details of a service from the command line?

Posted on 2006-03-22
Last Modified: 2012-05-05
For instance I want to verify that status of the Alerter service is set to disabled.

Is this possible from the command line?


Question by:JoshFink
    LVL 95

    Expert Comment

    by:Lee W, MVP
    LVL 11

    Accepted Solution


    Also try using the sc command:

    Sc.exe uses the following syntax:

    Syntax1 (use Syntax1 to run Sc.exe)
    sc [Servername] Command Servicename [Optionname= Optionvalue...]
    Syntax2 (use Syntax2 to display help information, except for the query command)
    sc [Command]

    Optional. Specifies the name of the server when you want to run the commands on a remote computer. The name must start with two backslash (\) characters (for example, \\myserver). To run Sc.exe on the local computer, do not supply this parameter.
    •      Command
    Specifies the sc command. Note that many of the sc commands require administrative privileges on the specified computer. Sc.exe supports the following commands:
    Changes the configuration of a service (persistent).

    Sends a Continue control request to a service.

    Sends a control to a service.

    Creates a service (adds it to the registry).

    Deletes a service (from the registry).

    Enumerates service dependencies.

    Obtains the DisplayName for a service.

    Obtains the ServiceKeyName for a service.

    Sends an Interrogate control request to a service.

    Sends a Pause control request to a service.

    Queries configuration for the service. For detailed information, see the reference section, "SC QC."

    Queries the status for a service, or enumerates the status for types of services. For detailed information, see the reference section, "SC QUERY."

    Starts a service

    Sends a Stop request to a service.
    •      Servicename
    Specifies the name given to the Service key in the registry. Note that this is different from the display name (which is what you see with net start command and the Services tool in Control Panel. Sc.exe uses the service key name as the primary identifier for the service.
    •      Optionname
    The Optionname and Optionvalue parameters allow you to specify the names and values of optional command parameters. Note that there is no space between the Optionname and the equal sign. You can supply none, one, or more optional parameters name and value pairs.
    •      Optionvalue
    Specifies the value for the parameter named by Optionname. The range of valid values is often restricted for each Optionname. For a list of available values, request help for each command.

    Author Comment

    Thanks.. The sc.exe qc alerter works great

    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Join & Write a Comment

    Learn about cloud computing and its benefits for small business owners.
    ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
    Hi everyone! This is Experts Exchange customer support.  This quick video will show you how to change your primary email address.  If you have any questions, then please Write a Comment below!
    This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor ( If you're looking for how to monitor bandwidth using netflow or packet s…

    733 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    24 Experts available now in Live!

    Get 1:1 Help Now