Click here for "Error Codes for Commercial Air Conditioners".(Japanese Version)

CentOS7.9 ; Logwatch , Disk usage check script

1. Logwatch

①Install

②Edit configuration file

③Output Logwatch reports

You will get the following message

④Test to see if the report arrives at the address you set.
Check if you receive a log report email like the one above.

2.Introduce disk usage check script

2.1 Script Creation

Contents of disk_capacity_check.sh

2.2 Execution Confirmation

①Check current utilization

It appears as follows

②Create a dummy file (in the example, it is named "dummyfile" and is about 10G) so that the utilization is 80% or more.

③check again

Run it and make sure it is above 80%.

④Run disk space check script

You will receive an email to the email address you set up with the body of the message as "Disk usage alert : 87%".

⑤Delete the "dummyfile" you created.

⑥Periodic Execution Setting

Copied title and URL