Name

top

Synopsis

top [options]

Provide information (frequently refreshed) about the most CPU-intensive processes currently running. You do not need to include a - before options. See ps for explanations of the field descriptors.

Options

-b

Run in batch mode; don’t accept command-line input. Useful for sending output to another command or to a file.

-c

Show command line or program name in display. -c is a toggle; top starts with the last remembered setting.

-d delay

Specify delay between refreshes. Specify as ss.tt (seconds and tenths).

-f

Add or remove fields or columns.

-h

Print a help message and exit.

-H

Display either all individual threads or a summary of all threads in process. -H is a toggle; top starts with the last remembered setting.

-i

Suppress display of idle and zombie processes. -i is a toggle; top starts with the last remembered setting.

-n num

Update display num times, then exit.

-p pids

Monitor only processes with the specified process IDs.

-s

Secure mode. Disable some (dangerous) interactive commands.

-S

Cumulative mode toggle. Print total CPU time of each process, including dead child processes when on. top starts with the last remembered setting.

-u user

Monitor only processes with the specified effective UID or username.

-U user

Monitor only processes with the specified UID or username, matching real, effective, saved, and filesystem ids.

-v

Print version information and exit.

Interactive commands

=

Remove restrictions on which tasks are shown. Reverses the effect of an active i or n command. ...

Get Linux in a Nutshell, 6th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.