Windows Dienste ändern per cmd

Aus Howtos und Anleitungen

Wechseln zu: Navigation, Suche

Das benötigte Tool gibt es direkt Onboard mitgeliefert:

sc
sc <server> [command] [service name] <option1> <option2>

Hier die wichtigsten Komandos:

query-----------Queries the status for a service, or enumerates the status for types of services.

queryex---------Queries the extended status for a service, or enumerates the status for types of services.

start-----------Starts a service.

pause-----------Sends a PAUSE control request to a service.


continue--------Sends a CONTINUE control request to a service.

stop------------Sends a STOP request to a service.

config----------Changes the configuration of a service (persistant).

description-----Changes the description of a service.

failure---------Changes the actions taken by a service upon failure.

qc--------------Queries the configuration information for a service.

qdescription----Queries the description for a service.

qfailure--------Queries the actions taken by a service upon failure.

delete----------Deletes a service (from the registry).

create----------Creates a service. (adds it to the registry).


Beispiele:

sc start MyService
sc stop Service & sc config Service start=disabled