星期六, 3月 10, 2007

Add/Remove Services in Windows

Some program may install services on your system, and when they have problem during install/uninstall. There may be a zombie service left on your system. You will see the error message "At least one service or driver failed during system startup. Use Event Viewer to examine the event log for details." every time you boot, and this slow down the boot process. You try to set the service to be Disabled in Services Manage Console,but could not find that service exist.

What you need is SC.exe - a command line program used for communicating with the Service Control Manager and services.

sc query lists all services installed on your system, the list could be too long to display on console, use sc query > service.txt to redirect all services to a file.

All service description looks like this:

SERVICE_NAME: ALG
DISPLAY_NAME: Application Layer Gateway Service
TYPE : 10 WIN32_OWN_PROCESS
STATE : 4 RUNNING
(STOPPABLE, NOT_PAUSABLE, IGNORES_SHUTDOWN))
WIN32_EXIT_CODE : 0 (0x0)
SERVICE_EXIT_CODE : 0 (0x0)
CHECKPOINT : 0x0
WAIT_HINT : 0x0

To start/stop a service : sc start/stop service_name
To uninstall : sc delete service_name

I have had an ASInsHelp service from ASUS Monitor , which failed to install on 2003 and could not uninstall cleanly. Give me the annoying warring message every boot. After the service removed, booting obviously faster.

沒有留言: