Saturday, September 24, 2022

Install and Configure SysStat on Debian 11

In this article, we want to teach you How To Install and Configure SysStat on Debian 11.

SysStat is a powerful logging and monitoring tool for Linux/Unix systems. It can be used to monitor system performance and troubleshoot problems.

How To Install and Configure SysStat on Debian 11

Before you start to install SysStat on Debian 11, you need to log in to your server as a non-root user with sudo privileges. To do this, you can follow our article the Initial Server Setup with Debian 11.

Now follow the steps below to install SysStat on your server.

Installing SysStat on Debian 11

First, you need to update your local package index with the following command:

sudo apt update

By default, SysStat is available in the Debian default repository. So you can use the following command to install SysStat on your server:

sudo apt install sysstat

When your installation is completed, you need to make some configuration changes.

Configuring SysStat on Debian 11

By default, SysStat monitoring is disabled. You need to enable it on your server to use it.

Open the SysStat configuration file with your favorite text editor, here we use vi:

vi /etc/default/sysstat

Find the ENABLED directive and set it to the:

ENABLED="true"

When you are done, save and close the file.

Now start your SysStat service on Debian 11 with the following command:

sudo systemctl start sysstat

If you want to start your service at boot run the following command:

sudo systemctl enable sysstat

Check your SysStat service is active and running on your Debian 11 with the command below:

sudo systemctl status sysstat

In your putout you should see:

Output
sysstat.service - Resets System Activity Logs
Loaded: loaded (/lib/systemd/system/sysstat.service; enabled; vendor prese>
Active: active (exited) since Sat 2021-12-18 04:42:55 EST; 56s ago
Docs: man:sa1(8)
man:sadc(8)
man:sar(1)
Main PID: 1239 (code=exited, status=0/SUCCESS)
Tasks: 0 (limit: 2340)
Memory: 0B
CPU: 0
CGroup: /system.slice/sysstat.service

At this point, you have SysStat installed on your Debian 11, let’s see how to use it.

How to Use SysStat Service

You can get a real-time system static command-line tool. Here we show you some examples of different statics.

To check CPU usage, you can use the following command:

sar -u

You can check the display device with the command below:

iostat -d

Use the following command to view display usage:

iostat -x

Also, you can view current processes on your Debian 11 with the command below:

pidstat -d

For more information, you can visit the SysStat Documentation page.

Conclusion

At this point, you learn to set up SysStat on Debian 11.

Hope you enjoy using it.

Maybe you will be interested in these articles:

Set up Fail2ban on Debian 11.

Install Umami software on Debian 11.

Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Articles

POPULAR TAGS

Most Popular