The sar/sysstat is a very useful and effective tool to monitor your server resource usage, by installing it you will be able to find out the server’s load history, resource usage etc. The steps to install it on a Ubuntu/Debian distro is given below.

Installation of SAR on Ubuntu/Debian

In a debian based server we use the “apt-get” command to install the SAR.

Step 1 : SSH to server as root user.

Step 2 : Run the below command to install the SAR utility.

There is a chance of getting the following error if you are not configured the sysstat properly.

Fix: Open “/etc/default/sysstat” using your favorite file editor and change ENABLED=”false” to ENABLED=”true”
Step 3: One more thing to do, change the collection interval from every 10 minutes to every 2 minutes.

Step 4: Restart the service.

Thank you!!!