Home Directory Plugins Anti-Virus ClamAV check_clamav_scan

Search Exchange

Search All Sites

Nagios Live Webinars

Let our experts show you how Nagios can help your organization.

Contact Us

Phone: 1-888-NAGIOS-1
Email: sales@nagios.com

Login

Remember Me

Directory Tree

check_clamav_scan

Rating
0 votes
Favoured:
0
Current Version
0.1.0
Last Release Date
2017-06-29
Compatible With
  • Nagios 1.x
  • Nagios 2.x
  • Nagios 3.x
License
MIT
Hits
6941
Files:
FileDescription
check_clamav_scan.shcheck_clamav_scan.sh
Nagios CSP

Meet The New Nagios Core Services Platform

Built on over 25 years of monitoring experience, the Nagios Core Services Platform provides insightful monitoring dashboards, time-saving monitoring wizards, and unmatched ease of use. Use it for free indefinitely.

Monitoring Made Magically Better

  • Nagios Core on Overdrive
  • Powerful Monitoring Dashboards
  • Time-Saving Configuration Wizards
  • Open Source Powered Monitoring On Steroids
  • And So Much More!
Nagios plugin for monitoring ClamAV virus scans, written in bash.
Nagios plugin for monitoring ClamAV virus scans.

Usage:

./check_clamav_scan -l [options]

Examples:

# exit OK if 0 infected files detected, CRITICAL if 1 or more detected
./check_clamav_scan -l /tmp/clamav.log

# exit UNKNOWN if logfile is more than 1 hour old
./check_clamav_scan -l /tmp/clamav.log -e '1 hour'

# exit OK if 0 infected files detected, WARNING if upto 10 detected, CRITICAL if 10 or more detected
./check_clamav_scan -l /tmp/clamav.log -c 10

# exit OK if upto 4 infected files detected, WARNING if upto 5 detected, CRITICAL if 10 or more detected
./check_clamav_scan -l /tmp/clamav.log -c 10 -w 5

Options:

-l, --logfile path to clamscan logfile
-e, --expiry expiry threshold for logfile
-w, --warning number of infected files treat as WARNING
-c, --critical number of infected files to treat as CRITICAL
-v, --verbose include the scan summary in the output
-V, --version output version
-h, --help output help information

* -e/--expiry should be a human readable duration, e.g. '1 hour', or '7 days'.
* -c/--critical takes priority over -w/--warning.

Dependencies:

* Bash
* cut, grep, rev, sed