Home Directory Plugins Log Files check_file_monitoring

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_file_monitoring

Rating
0 votes
Favoured:
0
Current Version
1.0
Last Release Date
2020-04-02
Compatible With
  • Nagios 4.x
  • Nagios XI
Hits
4627
Files:
FileDescription
check_file_monitoringcheck_file_monitoring
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!
Plugin in python to be run remotely via check_by_ssh on a FTP/SFTP/SCP server (in my case NAS synology).
It allows to monitor if a file (like a backup of a device) is created regularly and optionally validate it against a md5 if available.
It runs as follow (script must be on the remote server like here "/var/services/homes/nagios/check_file_monitoring"):

check_file_monitoring -d '' -f 'file pattern to be matched' -s -c -w " -t

sudo -u nagios /usr/local/nagios/libexec/check_by_ssh -H -C "/var/services/homes/nagios/check_file_monitoring -d '/volumex/backup/nagios/' -f 'nagios_server*.gz' -s md5 -c 7 -w 5" -t 180

Return something like:
OK - Last file found /volumex/backup/nagios/nagios_server_mycompany.org.backup.200508.tar.gz was updated on 2020-05-08 , has a size of 1366862734 KiBs and has a valid md5 calculated of bb1ad22a1403bc94f2650a61ac14fc9c wich matches the one received in /volumex/backup/nagios/nagios_server_mycompany.org.backup.200508.tar.gz.md5