[Nagios-users] check_file_age help

2012-07-30 Thread Jeremy Page
Hello list, I am trying to use check_file_age on Ubuntu 10.04 to check a local file system. When I specify the file name it works but using a wildcard fails saying it cannot find the file. I need to use the wildcard - the files have unique names based on the date created. Both work when run

Re: [Nagios-users] check_file_age help

2012-07-30 Thread Justin T Pryzby
Nagios probably doesn't use the shell, which is how wildcards get expanded, so the plugin is just seeing * instead of a filename. I suggest to use a shell wrapper, like #! /bin/sh set -e d=/stuff/backup pp=/usr/lib/nagios/plugins x=`ls -lt $d` 12 || exit 3 x=`echo $x |sed q` exec

Re: [Nagios-users] check_file_age help

2012-07-30 Thread Roger Burton West
On Mon, Jul 30, 2012 at 12:57:21PM -0400, Jeremy Page wrote: Hello list, I am trying to use check_file_age on Ubuntu 10.04 to check a local file system. When I specify the file name it works but using a wildcard fails saying it cannot find the file. I need to use the wildcard - the files have

[Nagios-users] check_file_age

2007-11-05 Thread alexus
what if i need to check if file is no more then X Mb, how would I do that? because with check_file_age it only allowes you to check if it at least X amount of bytes, not the other way around. -- http://alexus.org/ - This

Re: [Nagios-users] check_file_age

2007-11-05 Thread Andreas Ericsson
alexus wrote: what if i need to check if file is no more then X Mb, how would I do that? because with check_file_age it only allowes you to check if it at least X amount of bytes, not the other way around. Use negate. -- Andreas Ericsson [EMAIL PROTECTED] OP5 AB