Command Line program for Windows Service Control Manager communication

Source: Internet
Author: User

SC is a command line used to communicate with the Service Control Manager. Program .

Usage:

SC <Server> [command] [service name] <option1> <option2>...

the format of option is "\ servername"
you can type "SC [command]" for further help.

command:
query ----------- query service status,
or enumerative service status.
queryex --------- query the extended status of the service.
or enumerate the status of the service type.
Start ----------- start the service.
pause ----------- send a pause control request to the service.
interrogate ----- sends an interrogate control request to the service.
continue -------- send a continue control request to the service.
stop ------------ send a stop request to the service.
config ---------- (permanently) change the service configuration.
description ----- modify the service description.
failure --------- modify the operation performed when the service fails.
QC ------------ query service configuration information.
qdescription ---- query the service description.
qfailure -------- operations performed by the failed query service.
Delete ---------- (from the Registry) Delete the service.
Create ---------- create a service (add it to the registry ).
Control --------- send control to service.
sdshow ---------- displays the security descriptor of the service.
sdset ----------- set the security descriptor of the service.
getdisplayname -- get the displayname of the service.
getkeyname ------ obtain the servicekeyname of the service.
enumdepend ------ enumeration service dependency.

the following command does not query the service name:
SC
boot ------------ (OK | bad) indicates whether to save the last startup as
the last known STARTUP configuration
lock ---------- lock the Service database
querylock ------- Query lockstatus of the scmanager database
example:
SC start myservice

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.