Home Directory Plugins System Metrics File System check remote files age in minutes

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 remote files age in minutes

Rating
3 votes
Favoured:
2
Hits
108524
Files:
FileDescription
check_fileages_remotechecks remote files in directory which are older than specified minutes
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!
checks a directory on a remote system (via rsh or ssh) and returns a warning if a specified amount of files is found which is older than x minutes.
checks a directory on a remote system (via rsh or ssh) and returns a warning if a specified amount of files is found which is older than x minutes.

We are using the find command with the option \"-mmin\" to select the correct files in a directory. The results are piped to the command \"wc -l\" to determine the amount of files found. The result is interpreted as a nagios status OK, WARNING or CRITICAL.

Tested on Solaris 5.8 with the appropriate \"find\" packages from www.sunfreeware.com and tested on Linux.

That\'s all folks
Reviews (3)
bynajmarte, September 27, 2016
1 of 1 people found this review helpful
0
In formation of command a hyphen is missing ; that causes the cmd to always return zero . in mmin we need to provide (-) to ruun the command properly.

Expected :$CMD = "/bin/find " . $pattern . " -type f -mmin " . -$mmin . " 2>/dev/null| /usr/bin/wc -l";

Otherwise the plugin is excellent and runs great.
byMageru, September 23, 2011
I had to change the path for find in the plugin to adapt for my Red Hat servers but the plugin is most excellent!