O'Reilly logo

Linux in a Nutshell, Fourth Edition by Aaron Weber, Stephen Figgins, Ellen Siever

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

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 in display instead of just command name.

-C

For SMP systems, display total CPU information in addition to information for the individual CPUs.

-d delay

Specify delay between refreshes.

-h

Print a help message and exit.

-i

Suppress display of idle and zombie processes.

-n num

Update display num times, then exit.

-p pid

Monitor only processes with the specified process ID.

-q

Refresh without any delay. If user is privileged, run with highest priority.

-s

Secure mode. Disable some (dangerous) interactive commands.

-S

Cumulative mode. Print total CPU time of each process, including dead child processes.

-v

Print version information and exit.

Interactive commands

space

Update display immediately.

c

Toggle display of command name or full command line.

f, F

Add fields to or remove fields from the display.

h, ?

Display help about commands and the status of secure and cumulative modes.

H

Prompt for a process ID and show all threads for that process.

k

Prompt for process ID to kill and signal to send (default is 15) to kill it.

i

Toggle suppression of idle and zombie processes.

l

Toggle display of load average and uptime information. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required