Windows

check_files.vbs – external script to be used with nsclient

Description:

Check files under a given path against various criteria:
namefilter, age, size

counts the files which match the given criterias and gives alarm if the count is higher or lower than the threshold
(bounds definition conforms to nagios plugin guidelines)

Current Version

0.1.3

Last Release Date

2011-10-06

Compatible With

  • Nagios 3.x

License

GPL


Project Files
Project Notes
check files under a given path uses NagiosPlugin.vbs from nsclient++/scripts/lib - NagiosPlugin.vbs which came with nsclient++ vers. 0.3.9 (earlier version needed adaptation) - compares bounds to double values, so 10 comes after 9 (numeric sorting) - bounds definition conforms to nagios plugin guidelines (http://nagiosplug.sourceforge.net/developer-guidelines.html#THRESHOLDFORMAT) args: ===== warning: threshold warning alert if x... 10 < 0 or > 10, (outside the range {0..10}) 10: < 10, (outside {10 .. 8}) ~:10 > 10, (outside the range of {-8 .. 10}) 10:20 < 10 or > 20, (outside the range {10..20}) @10:20 >= 10 and <= 20, (inside the range {10..20}) critical: threshold critical namefilter: regular expressionon on which files have to match age: files have to be older/newer (see selage) than age e.g.: 5d: 5 days, 4h: 4 hours, 10n: 10 Minutes, 90s: 90 seconds selage: older/newer/hour/ignore older/newer: count only files if the are older/newer hour: alert if file is not written until hour ignore: count files independent of their age searchdepth: search down x subdirs (searchdepth:1 - do not go down in directory hierarchy) seldat: modified/created modified: date, when file was written created: date, when file was created size: if file is smaller than given size give a warning expectmatch: if less than expectmatch files correspond to namefilter give a warning weekdays: if selage:hour files have to be written only on weekdays (1:sunday, 2:monday, ...) if selage:newer or selage:older and the timeunit of age is d (days), we add as many days to age as the last weekday is back e.g.: weekdays:23456 files are written on Monday, Tuesday, Wednesday, Thursday, Friday
Reviews (0) Add a Review
Add a Review

You must be logged in to submit a review.

Thank you for your review!

Your review has been submitted and is pending approval.

Recommend

To:


From:


Thank you for your recommendation!

Your recommendation has been sent.

Project Stats
Rating
5 (1)
Favorites
1
Views
94,464