Tutorials  /  Linux Basics

atop Command: The Ultimate Solution for System Monitoring in Linux

Ccentron Redaktion · June 2024 ·4 min read ·Linux Basics, Tutorial

Installation of the atop Command:

First, we need to install the atop command on the system. Debian/Ubuntu users can do this with the following command:

Code
bash
sudo apt install atop

Other Linux users can use their default package manager followed by the keyword 'atop'.

VM

Matching infrastructure at centron

No hardware needed to follow along: ccloud³ VMs with full root access start at €3.12 per month, billed by the hour and ready in seconds. Rent a cloud server →

Basic Output of the atop Command:

To display all process-related information about system resources, simply run 'atop' in the terminal.

Code
bash
atop

The output consists of two panels. The upper panel displays the cumulative usage of system resources, while the lower panel provides detailed information for each process.

Cumulative Statistics of the atop Command:

Each entry in this view focuses on a specific system resource.

  1. Process-related Statistics:
    • PRC stands for "Process".
    • The first two values represent the time consumed by the processes 'sys' (System) and 'user'.
    • Followed by the total number of processes as '#proc'.
    • Other values include the number of threads currently running in the system ('#trun').
    • '#tslpi' indicates the number of threads currently sleeping and interruptible.
    • '#tslpu' indicates the number of threads currently sleeping and uninterruptible.
    • Zombie processes, number of clone system calls, and number of exited processes ('#exit') are also displayed.
  2. Performance-related Statistics:
    • CPU refers to CPU utilization.
    • The first two values show the percentage utilization of all cores by system and user processes.
    • Percentages for interrupt requests ('irq'), idle, and CPU core wait are also displayed.
    • 'CPL' refers to CPU load and shows average loads for different periods.
  3. Memory-related Statistics:
    • MEM stands for memory usage.
    • Various memory information such as total memory, free memory, cache memory, and swap memory are displayed.
  4. Disk-related Statistics:
    • DSK stands for disk usage and shows information such as the percentage time the system spends processing requests, as well as read and write requests.
  5. Network-related Statistics:
    • NET displays network statistics at the transport layer and network layer.

System Resources for Each Process:

The generic output of the 'atop' command shows details like PID, CPU usage, virtual and physical memory, data transfers during disk accesses, and more for each process. Processes are sorted by CPU usage.

Memory-based Output of the atop Command:

The 'atop' command allows studying memory consumption for each running process. To do this, execute 'atop -m'. Processes are sorted by memory usage.

Disk-specific Output with the atop Command:

For disk usage information, use the '-d' option along with 'atop'. Processes are sorted by disk occupancy.

Finding Background Commands with atop:

To find background commands as processes in a command-line output, use 'atop -c'.

Thread-based Information:

atop provides the ability to check resource usage for threads. Execute 'atop -y' or press 'y' when the command is already displaying system resource information.

Other Information:

There are many types of information that can be extracted with the 'atop' command, including process start times, number of processes per user, and which core a process is working on.

Tips and Tricks for the atop Command:

Some useful key combinations include pausing the screen ('z' key), changing the refresh interval ('i' followed by seconds), refreshing values immediately ('t' key), and exiting the display ('q' key).

Conclusion:

The atop command may seem overwhelming at first, but it provides a wealth of information for system monitoring. With patience and persistence, this command can become a powerful tool. Feel free to reach out with any questions in the comment section.

Jetzt 200 € Guthaben sichern

Testen Sie Ihr Setup auf ccloud³

Registrieren Sie sich in der ccloud³ und erhalten Sie 200 € Startguthaben für Ihr Projekt – z. B. für eine PostgreSQL-VM mit automatischen Backups.

centron Redaktion Technische Redaktion

Das Redaktionsteam von centron schreibt Anleitungen aus dem Betriebsalltag: getestet auf unserer eigenen Plattform, betrieben im Rechenzentrum in Hallstadt bei Bamberg.

Kategorie Linux Basics
Teilen
Noch offene Fragen?

Our team will help you with your specific setup - in German or English, by people who run the platform themselves.

War dieses Tutorial hilfreich?

Your answer is stored anonymously and helps us improve our tutorials.

Kommentare

No comments yet - be the first to ask a question about this tutorial.

Sign in to comment

Comments are open to centron customers. Sign in to your account to ask a question about this tutorial.

Weiterlesen

Das könnte Sie auch interessieren

Jetzt kostenlos anfangen

Melden Sie sich an und erhalten Sie in den ersten 60 Tagen ein Guthaben von 200 € bei centron.

Dieses Werbeangebot gilt nur für neue Konten. Angebot ausschließlich für Gewerbetreibende.

Jetzt loslegen Sales kontaktieren