Linux "top" command

By EssingtonITS team ·

The "top" command is essential for Linux system administrators, offering real-time monitoring and management of processes and resource usage. It features an interactive interface that provides detailed insights into system performance and allows process termination.

The top command is an invaluable tool for system administrators who need to keep an eye on processes and resource usage in Linux. It’s a staple in the sysadmin toolkit, and you’ll find it pre-installed on virtually every Linux distribution. What makes top so handy is its interactivity; not only can you view and monitor processes, but you can also terminate them if necessary.

Getting Started with Top

To fire up top, simply open your terminal and type top. This launches the interactive interface, which may seem a bit overwhelming at first glance, but it's quite straightforward once you get the hang of it.

Terminal displaying system processes and resource usage statistics

Deciphering the Interface

Before diving into the details, you might want to check the version of top you’re using by typing top -v. Once you’re in, the screen is divided into two main sections: the summary area at the top and the task area below, which lists all the processes. By default, this information refreshes every three seconds, providing a near real-time view of your system's performance.

The Summary Area

The first line of the summary area displays the current time, the system uptime, and the number of users currently logged in. It also shows the load averages for the past 1, 5, and 15 minutes, which can help you understand how heavily your system has been used over those time frames.

The second line provides a snapshot of the number of tasks and their states: running, sleeping, stopped, or zombie. This is crucial for understanding how many processes are actively using resources versus those that are idle.

Next, you'll find the CPU usage breakdown:

  • us: Time spent on user processes.
  • sy: Time spent on system (kernel) processes.
  • ni: Time spent on processes with adjusted priority (nice value).
  • id: Idle CPU time.
  • wa: Time waiting for I/O operations to complete.
  • hi: Time handling hardware interrupts.
  • si: Time handling software interrupts.
  • st: Time stolen from this VM by the hypervisor (applicable in virtualised environments).

The fourth line details memory usage, showing total physical memory and how much is free, used, or cached. The fifth line does the same for swap memory, including how much is recoverable from caches.

The Task or Process Area

Below the summary, the task area provides a list of all processes, each with several columns of information:

  • PID: Unique Process ID.
  • USER: Username of the process owner.
  • PR: Priority of the process.
  • NI: Nice value, which affects scheduling priority.
  • VIRT: Virtual memory used.
  • RES: Resident memory used (physical memory).
  • SHR: Shared memory used.
  • S: Current status of the process.
  • %CPU: CPU usage percentage since the last update.
  • %MEM: Percentage of physical memory used.
  • TIME+: Total CPU time consumed by the process, shown in hundredths of a second.
  • COMMAND: The command that started the process.

Process statuses include:

  • D: Uninterruptible sleep (usually I/O).
  • R: Running or runnable (on run queue).
  • S: Sleeping (idle).
  • T: Stopped by job control signal.
  • Z: Zombie process, terminated but not reaped by its parent.

When you're ready to exit top, just press q. Avoid using Ctrl+x, as this can leave a process in a stopped state.

Looking to enhance your Linux infrastructure? At EssingtonITS.co.uk, we offer expert support and tailored solutions to optimise your systems. Let us help you achieve seamless integration and improved performance.

person people found this useful.

Related

Knowledge base 10 Jun 2026

Personal Notebook in eLLM

The personal notebook in eLLM allows users to organise and store notes, images, and files in a private, searchable timeline. It ensures privacy by keeping contents visible only to the user, and it can be integrated with the assistant for personalised answers.

Knowledge base 9 Jun 2026

Git Commands Quick Reference Guide

This quick reference guide covers essential Git commands for repository setup, staging, branching, merging, and working with remote repositories, making it a handy tool for developers to streamline their workflow.

Knowledge base 9 Jun 2026

Organisation Skills in the eLLM Admin Console

The article explains how the eLLM Admin Console allows organisations to create and manage shared instruction sets called "organisation skills" to ensure consistent responses across teams. These skills can be customised, restricted to specific groups, and integrated with extern…

Expand 29 Jul 2026

How AI can support pupils with SEND

Explore how AI tools are aiding pupils with special educational needs and disabilities by simplifying text, breaking down tasks, and enhancing accessibility. Learn about the considerations schools should make before implementation.

Expand 29 Jul 2026

AI policy and practice in further education

Further education colleges need distinct AI policies due to their unique mix of vocational courses, diverse age groups, and specific funding and inspection requirements. This guidance highlights the importance of tailored AI approaches in FE settings.