Raja's Exocortex

Monit Config for Base System Monitoring

Monitor system CPU, RAM and root file system for abnormal utilization and generate email alerts. To avoid false alarms, the loadavg and memory usage need to be adjusted after understanding the baseline usage of each server and application.

# Monit config to monitor CPU, RAM and disk usage
# File: /etc/monit/conf.d/system
#
check system $HOST
    if loadavg (5min)  > 3 for 4 cycles then alert
    if loadavg (15min) > 2 for 4 cycles then alert
    if memory usage > 80% for 4 cycles then alert
    if swap   usage > 20% for 4 cycles then alert
    if cpu usage (user)   > 80% for 4 cycles then alert
    if cpu usage (system) > 20% for 4 cycles then alert
    if cpu usage (wait)   > 20% for 4 cycles then alert

check filesystem "root" with path /
    if space usage > 25% for 8 cycles then alert