TASKLIST

suggest change

Lists tasks, including task name and process id (PID).

Show all processes, sorted:

$ tasklist | sort
========================= ======== ================ =========== ============
aesm_service.exe              2116 Services                   0      1,684 K
ApplicationFrameHost.exe     10592 Console                    1     17,460 K
AppVShNotify.exe             11312 Console                    1      1,160 K
... more output

Show a task matching a string:

$ tasklist | find "chrome.exe"
chrome.exe                   16164 Console                    1    347,644 K
chrome.exe                   20124 Console                    1      2,036 K
chrome.exe                    3972 Console                    1      1,916 K

Count number of tasks matching a string:

$ tasklist | find /C "chrome.exe"
41

List services hosted in svchost:

$ tasklist /svc | findstr svchost
svchost.exe                    940 PlugPlay
svchost.exe                    984 BrokerInfrastructure, DcomLaunch, Power,
svchost.exe                    844 RpcEptMapper, RpcSs
svchost.exe                   1076 LSM
svchost.exe                   1412 BDESVC
svchost.exe                   1428 TermService
... more output

Links:

$ tasklist /?
TASKLIST [/S system [/U username [/P [password]]]]
         [/M [module] | /SVC | /V] [/FI filter] [/FO format] [/NH]

Description:
    This tool displays a list of currently running processes on
    either a local or remote machine.

Parameter List:
   /S     system           Specifies the remote system to connect to.

   /U     [domain\]user    Specifies the user context under which
                           the command should execute.

   /P     [password]       Specifies the password for the given
                           user context. Prompts for input if omitted.

   /M     [module]         Lists all tasks currently using the given
                           exe/dll name. If the module name is not
                           specified all loaded modules are displayed.

   /SVC                    Displays services hosted in each process.

   /APPS                   Displays Store Apps and their associated processes.

   /V                      Displays verbose task information.

   /FI    filter           Displays a set of tasks that match a
                           given criteria specified by the filter.

   /FO    format           Specifies the output format.
                           Valid values: "TABLE", "LIST", "CSV".

   /NH                     Specifies that the "Column Header" should
                           not be displayed in the output.
                           Valid only for "TABLE" and "CSV" formats.

   /?                      Displays this help message.

Filters:
    Filter Name     Valid Operators           Valid Value(s)
    -----------     ---------------           --------------------------
    STATUS          eq, ne                    RUNNING | SUSPENDED
                                              NOT RESPONDING | UNKNOWN
    IMAGENAME       eq, ne                    Image name
    PID             eq, ne, gt, lt, ge, le    PID value
    SESSION         eq, ne, gt, lt, ge, le    Session number
    SESSIONNAME     eq, ne                    Session name
    CPUTIME         eq, ne, gt, lt, ge, le    CPU time in the format
                                              of hh:mm:ss.
                                              hh - hours,
                                              mm - minutes, ss - seconds
    MEMUSAGE        eq, ne, gt, lt, ge, le    Memory usage in KB
    USERNAME        eq, ne                    User name in [domain\]user
                                              format
    SERVICES        eq, ne                    Service name
    WINDOWTITLE     eq, ne                    Window title
    MODULES         eq, ne                    DLL name

NOTE: "WINDOWTITLE" and "STATUS" filters are not supported when querying
      a remote machine.

Examples:
    TASKLIST
    TASKLIST /M
    TASKLIST /V /FO CSV
    TASKLIST /SVC /FO LIST
    TASKLIST /APPS /FI "STATUS eq RUNNING"
    TASKLIST /M wbem*
    TASKLIST /S system /FO LIST
    TASKLIST /S system /U domain\username /FO CSV /NH
    TASKLIST /S system /U username /P password /FO TABLE /NH
    TASKLIST /FI "USERNAME ne NT AUTHORITY\SYSTEM" /FI "STATUS eq running"

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents