top Command in Linux

Back

The top command sorts active process first by their CPU load and RAM memory usage. It provides an overview of the current system status, starting with the current up time, number of connected users, active and sleeping tasks, CPU load, and more.

One problem with the top and ps command is that they display the status of process on a system as a snapshot in time. That may not be enough. Processes may load a system for just a blip of time, or even periodic blips in time.

 One way to find more information about the overall load on a system is with two commands from the sysstat package sar and iostat. That system activity information is logged courtesy of the sa1 and sa2 commands associated with the /etc/cron.d/systat script, which will be described shortly.