Discussion:
How to find out from CMDLINE if a certain process is running (on Windows XP) ?
(too old to reply)
Cindy Parker
2010-09-07 14:41:34 UTC
Permalink
Ok, it is no problem to find out if a certain process is running by using the GUI based Windows TaskManager.

But how do I find this out from command line (e.g. from a DOS batch script) ?

In unix there is a "ps" command.
But I found no corresponding cmdline tool for WInXP/DOS

Cindy
Petr Laznovsky
2010-09-07 16:56:21 UTC
Permalink
Post by Cindy Parker
Ok, it is no problem to find out if a certain process is running by using the GUI based Windows TaskManager.
But how do I find this out from command line (e.g. from a DOS batch script) ?
In unix there is a "ps" command.
But I found no corresponding cmdline tool for WInXP/DOS
Cindy
tasklist | find /i "process_name"

L.
Guy
2010-09-07 17:42:23 UTC
Permalink
Post by Cindy Parker
In unix there is a "ps" command.
But I found no corresponding cmdline tool for WInXP/DOS
tasklist/?
Not available in XP Home, although Cindy doesn't state what
version she's running.
Hmmm...

PsList of PsTools @ sysinternals.com

<http://technet.microsoft.com/en-us/sysinternals/bb896682.aspx>


$ pslist/?

pslist v1.29 - Sysinternals PsList
Copyright (C) 2000-2009 Mark Russinovich
Sysinternals

Usage: pslist [-d][-m][-x][-t][-s [n] [-r n] [\\computer [-u username][-p password][name|pid]
-d Show thread detail.
-m Show memory detail.
-x Show processes, memory information and threads.
-t Show process tree.
-s [n] Run in task-manager mode, for optional seconds specified.
Press Escape to abort.
-r n Task-manager mode refresh rate in seconds (default is 1).
\\computer Specifies remote computer.
-u Optional user name for remote login.
-p Optional password for remote login. If you don't present
on the command line pslist will prompt you for it if necessary.
name Show information about processes that begin with the name
specified.
-e Exact match the process name.
pid Show information about specified process.

All memory values are displayed in KB.
Abbreviation key:
Pri Priority
Thd Number of Threads
Hnd Number of Handles
VM Virtual Memory
WS Working Set
Priv Private Virtual Memory
Priv Pk Private Virtual Memory Peak
Faults Page Faults
NonP Non-Paged Pool
Page Paged Pool
Cswtch Context Switches


$
SC Tom
2010-09-07 18:52:51 UTC
Permalink
Yep, PsList works, just not tasklist.
Post by Guy
Post by Cindy Parker
In unix there is a "ps" command.
But I found no corresponding cmdline tool for WInXP/DOS
tasklist/?
Not available in XP Home, although Cindy doesn't state what
version she's running.
Hmmm...
<http://technet.microsoft.com/en-us/sysinternals/bb896682.aspx>
$ pslist/?
pslist v1.29 - Sysinternals PsList
Copyright (C) 2000-2009 Mark Russinovich
Sysinternals
Usage: pslist [-d][-m][-x][-t][-s [n] [-r n] [\\computer [-u username][-p
password][name|pid]
-d Show thread detail.
-m Show memory detail.
-x Show processes, memory information and threads.
-t Show process tree.
-s [n] Run in task-manager mode, for optional seconds specified.
Press Escape to abort.
-r n Task-manager mode refresh rate in seconds (default is 1).
\\computer Specifies remote computer.
-u Optional user name for remote login.
-p Optional password for remote login. If you don't present
on the command line pslist will prompt you for it if necessary.
name Show information about processes that begin with the name
specified.
-e Exact match the process name.
pid Show information about specified process.
All memory values are displayed in KB.
Pri Priority
Thd Number of Threads
Hnd Number of Handles
VM Virtual Memory
WS Working Set
Priv Private Virtual Memory
Priv Pk Private Virtual Memory Peak
Faults Page Faults
NonP Non-Paged Pool
Page Paged Pool
Cswtch Context Switches
$
foxidrive
2010-09-07 20:58:51 UTC
Permalink
Post by SC Tom
Yep, PsList works, just not tasklist.
What problem do you find with tasklist? Are you using XP Pro?
--
Regards,
Mic
SC Tom
2010-09-07 22:15:31 UTC
Permalink
Post by foxidrive
Post by SC Tom
Yep, PsList works, just not tasklist.
What problem do you find with tasklist? Are you using XP Pro?
--
Regards,
Mic
If you'll follow the thread back to my original reply to Guy,

<quote> > tasklist/?

Not available in XP Home, although Cindy doesn't state what version she's
running.
<end quote>
--
SC Tom
-There's no such thing as TMI when asking for tech support.
Loading...