Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
check_file_exists_glob
Current Version
0.11
Last Release Date
2015-07-23
Compatible With
- Nagios 3.x
- Nagios 4.x
Owner
Download URL
Hits
44527
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!
$ ./check_file_exists_glob -h
check_file_exists_glob - Alert if a FILE does not exist.
Usage: check_file_exists_glob [options] -d DIR FILE
FILE : The file to search for. Can glob using '*' etc, but
place file names with glob patterns within quotes.
Mandatory. The FILE must always be specified.
-d DIR : Base directory to search in.
Mandatory option - the DIR must always be specified.
-i : Invert FILE, so alert if FILE does exist.
-I : Alert if DIR does not exist.
-p : Add performance data output for graphing.
-w NUM : Warning alert if >=NUM files are found and invert
files '-i' is on. (Default is: 1)
-c NUM : Critical alert if >=NUM files are found and invert
files '-i' is on. (Default is: 1)
-h : Display this help text.
Example:
Check that /tmp/dir/file exists.
./check_file_exists_glob -d /tmp/dir file
Check that /tmp/dir/file does NOT exist.
./check_file_exists_glob -d /tmp/dir -i file
Again check that /tmp/dir/file does NOT exist but this time alert
if the directory it could be found in, /tmp/dir, is missing.
./check_file_exists_glob -d /tmp -i -I file
Check for files matching the glob 'fi*' and alert if found in
/tmp/dir. Alert if /tmp/dir does not exist. Provide performance
data for graphing, showing the number of files matching the
glob pattern.
./check_file_exists_glob -d /tmp/dir -i -I -p "fi*"
Same as previous but only alert if thresholds are exceeded. In
this case issue a warning alert when there are 20 or more files
found, critical for 30 or more.
./check_file_exists_glob -d /tmp/dir -i -I -p -w 20 -c 30 "fi*"
check_file_exists_glob - Alert if a FILE does not exist.
Usage: check_file_exists_glob [options] -d DIR FILE
FILE : The file to search for. Can glob using '*' etc, but
place file names with glob patterns within quotes.
Mandatory. The FILE must always be specified.
-d DIR : Base directory to search in.
Mandatory option - the DIR must always be specified.
-i : Invert FILE, so alert if FILE does exist.
-I : Alert if DIR does not exist.
-p : Add performance data output for graphing.
-w NUM : Warning alert if >=NUM files are found and invert
files '-i' is on. (Default is: 1)
-c NUM : Critical alert if >=NUM files are found and invert
files '-i' is on. (Default is: 1)
-h : Display this help text.
Example:
Check that /tmp/dir/file exists.
./check_file_exists_glob -d /tmp/dir file
Check that /tmp/dir/file does NOT exist.
./check_file_exists_glob -d /tmp/dir -i file
Again check that /tmp/dir/file does NOT exist but this time alert
if the directory it could be found in, /tmp/dir, is missing.
./check_file_exists_glob -d /tmp -i -I file
Check for files matching the glob 'fi*' and alert if found in
/tmp/dir. Alert if /tmp/dir does not exist. Provide performance
data for graphing, showing the number of files matching the
glob pattern.
./check_file_exists_glob -d /tmp/dir -i -I -p "fi*"
Same as previous but only alert if thresholds are exceeded. In
this case issue a warning alert when there are 20 or more files
found, critical for 30 or more.
./check_file_exists_glob -d /tmp/dir -i -I -p -w 20 -c 30 "fi*"
Reviews (1)
bymuhalb, July 22, 2018
Is there anyway we can make it to check a web link to see if you the file download exist?