[Nagiosplug-devel] A patch for check_file_ages_in_dirs
Jess Portnoy
jessp at traiana.com
Thu Jul 21 13:38:47 CEST 2011
Hello list,
My patch consist of the following changes:
- Added support for single file monitoring [in addition to monitoring
all files in a given dir]
- Modified arguments for stat from:
- st_ctime=`stat --printf=%Y
${next_filepath}`
to:
+ st_ctime=`stat -c%Y
${next_filepath}`
Because the --printf flag doesn't exist in older Linux distros versions
[for instance RHEL 4].
- Fixed:
# /usr/local/nagios_plugins/check_file_ages_in_dirs
-f /var/log/httpd/error_log -c 120 -w hhh
/usr/local/nagios_plugins/check_file_ages_in_dirs: line 228: [: hhh:
integer expression expected
Thanks,
--
Best regards,
Jess Portnoy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nagios-plugins.org/archive/devel/attachments/20110721/d78655b5/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: check_file_ages_in_dirs.diff
Type: text/x-patch
Size: 4463 bytes
Desc: not available
URL: <http://nagios-plugins.org/archive/devel/attachments/20110721/d78655b5/attachment.bin>
More information about the Devel
mailing list