-
October 19th, 2003, 07:22 PM
#1
Senior Member
Processes in command line
Is there a way to view and/or kill a process from the command line of a windows machine?
-
October 19th, 2003, 07:25 PM
#2
command prompt>> NET STOP <service>
Will Stop A Process
Will give you a list of processes
AntiOnline Quick Forum Version 2b Click Here
10010101000000110010001100111
-
October 19th, 2003, 07:35 PM
#3
NET STOP will only work on installed services. to kill any process use (from systernals.com) the pstoolkit:
pslist -t will list running processes
pskill will kill them even when task manager will not.
to get an absolute complete list with info on all provesses:
psservice.exe
will give you:
SERVICE_NAME: AppMgmt
DISPLAY_NAME: Application Management
Provides software installation services such as Assign, Publish, and Remove.
TYPE : 20 WIN32_SHARE_PROCESS
STATE : 1 STOPPED
(NOT_STOPPABLE,NOT_PAUSABLE,IGNORES_SHUTDOWN)
WIN32_EXIT_CODE : 1077 (0x435)
SERVICE_EXIT_CODE : 0 (0x0)
CHECKPOINT : 0x0
WAIT_HINT : 0x0
SERVICE_NAME: lanmanworkstation
DISPLAY_NAME: Workstation
Provides network connections and communications.
TYPE : 20 WIN32_SHARE_PROCESS
STATE : 4 RUNNING
(STOPPABLE,PAUSABLE,ACCEPTS_SHUTDOWN)
WIN32_EXIT_CODE : 0 (0x0)
SERVICE_EXIT_CODE : 0 (0x0)
CHECKPOINT : 0x0
WAIT_HINT : 0x0
etc.
these also work on machines remotly if you have admin rights to them
psservice \\mach_name start tlntsvr
Bukhari:V3B48N826 “The Prophet said, ‘Isn’t the witness of a woman equal to half of that of a man?’ The women said, ‘Yes.’ He said, ‘This is because of the deficiency of a woman’s mind.’”
-
October 19th, 2003, 09:16 PM
#4
Also Windows Resource Kit Utilities
Props to Tedob1 for the post on the SysInternals utils - they make some of the best utilities.
Another option would be to use the Windows Resource Kit Utility called "kill.exe".
Also from the resource kit utils. All of which can perform against remote machines...
* List of processes: PULIST
* List of services: SCLIST
* Stopping/Starting/Querying services: NETSVC
Oh, by the way, all of these are found in the NT 4.0 and W2K Resource Kits. And you can run the 4.0 utils on W2K with no probs.
Enjoy.
-
October 19th, 2003, 09:24 PM
#5
In Windows XP Pro, tasklist; taskkill.
-
October 19th, 2003, 10:00 PM
#6
taskkill is the best way if an offending service or program wil not let you load windows.
something like taskkill /f /pid will forcefully kill the service or program.
taskkill /f is something like kill -9 in unix.
If you are killing a process on a remote machine use /s to specify the correct remote system.
-
October 19th, 2003, 11:17 PM
#7
Senior Member
Thanks for all the great info
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|