GNU/Linux Command – TOP

top — Display TOP Intensive processes
Summary :
TOP provides an ongoing look at processor activity in real time. TOP list the process, which is sorted based on the CPU usage of the each task on the system. It can also sort the tasks by memory usage and run time.
Examples :
$ top -- List the most CPU-Intensive processes.  $ top -q -- Runs with the highest possible priority.  $ top -d 6 -- List will be updated every 6 Sec.  $ top -n 5 -- Update the list for 5 times and then exit.  $ top -p 100 -p 200 -- Monitor only process with PID 100 and   200. Maximum 20 processes can be monitored.  $ top -s -- Run in secure mode (Disables the potentially dangerous   interactive commands).  $ top -c -- List the process with command line options insteadof the  command name only (default).  $ top -b -n 5 > myfile -- Run in Batch mode & dump the output in myfile.

  1. Batch Mode is useful for sending output from top to other programs or to a file. It runs until it produces the number of iterations requested with the n option or until killed.
  2. TOP supports few interactive commands to change the output formats like changing update time and few actions like killing a process.

Read : man top

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: