Skip to content

GillesMocellin/check-s3-file-age

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

check-s3-file-age

GPLv2 license Maintenance

nagios check for age of a specific file in AWS S3

usage

check_s3_file_age v0.5 (nagios-plugins 2.0.3)
The nagios plugins come with ABSOLUTELY NO WARRANTY. You may redistribute
copies of the plugins under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.
Copyright (c) 2015 Christopher Hicks

Usage:
  check_s3_file_age [-w <secs>] [-c <secs>] [-W <size>] [-C <size>] [-i] [-k <access-key>] [-s <secret-key>] -n <bucket-name> -f <file>
  check_s3_file_age [-h | --help]
  check_s3_file_age [-V | --version]

  -i | --ignore-missing :  return OK if the file does not exist
  <secs>  File must be no more than this many seconds old (default: warn 240 secs, crit 600)
  <size>  File must be at least this many bytes long (default: crit 0 bytes)
  <access-key> is optional if you have the environment variable AWS_ACCESS_KEY defined
  <secret-key> is optional if you have the environment variable AWS_SECRET_KEY defined

examples

Look in s3bucket for a file named foo. Warn if the file is smaller than 100000 bytes and go critical if the file is less than 50.

check_s3_file_age.pl -n s3bucket -f foo -W 100000 -C 50

Look in s3bucket for a file named foo.
Go critical if the file is less than 50000000 bytes. Also warn if the file is older than 6 days and go critical if the file is older than 8 days.

check_s3_file_age.pl -n s3bucket -f foo -C 50000000 -w 6d -c 8d

requirements

acknowledgements

see also

About

nagios check for AWS S3 file age

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Perl 100.0%