


It's a pure-Python CLI package including its couple of dependencies (no heavy Matplotlib), can potentially plot many metrics from procfs, JSONPath queries to the process tree, has basic decimation/aggregation (Ramer-Douglas-Peucker and moving average), filtering by time ranges and PIDs, and a couple of other things. Returning to the problem of process analysis frequently enough and not being satisfied with the solutions I described below originally, I decided to write my own. This list includes various details about each process and is refreshed automatically every 5 seconds.2020 update (Linux/procfs-only). The top command generates a list of processes sorted by the parameter %CPU, or percentage of CPU consumed by a process. You can calculate the overall CPU utilization using the idle time using the formula given below:įor example, in the output above, the idle time is 98.3%, so the CPU utilization can be calculated as follows: In the output above, the top command displays various important CPU statistics, including idle time and wait time. It is one of the most widely used commands for tracking the CPU utilization, process statistics, and memory utilization of a Linux system.įor example, running the top command on a Linux system will display an output similar to the one shown below: Fig 1: Output of top command It displays various crucial system metrics along with a set of processes that are currently being managed by the Linux kernel. The top command is used to display a real-time, dynamic view of a running system. Browser tabs with ads or auto-playing videos are openĪpplications or programs that require high processing power, including video editing software and high-resolution video games-can easily drive up CPU usage.

