Here is the scenario that I have. I have a directory that I want to monitor if any .log files exist, if the exist for more than 2 minutes I want a critical event generated. If there are currently no .log files in the directory my command works correctly. However if there is a .log file it generates an error.
With a file in the directory called jason.log i get the following
$ ./check_nt -p 12489 -H Corp343 -v FILEAGE -l 'c:\\scripts\\*.log' -w 1 -c 2
Client - ERROR: File not found: c:\\scripts\jason.log
with no file in the log i get the following:
$ ./check_nt -p 12489 -H Corp343 -v FILEAGE -l 'c:\\scripts\\*.log' -w 1 -c 2
OK: 0 Minutes, c:\\scripts\\*.log
Anyone have any ideas?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Here is the scenario that I have. I have a directory that I want to monitor if any .log files exist, if the exist for more than 2 minutes I want a critical event generated. If there are currently no .log files in the directory my command works correctly. However if there is a .log file it generates an error.
With a file in the directory called jason.log i get the following
$ ./check_nt -p 12489 -H Corp343 -v FILEAGE -l 'c:\\scripts\\*.log' -w 1 -c 2
Client - ERROR: File not found: c:\\scripts\jason.log
with no file in the log i get the following:
$ ./check_nt -p 12489 -H Corp343 -v FILEAGE -l 'c:\\scripts\\*.log' -w 1 -c 2
OK: 0 Minutes, c:\\scripts\\*.log
Anyone have any ideas?
I have also ran this with " instead of the single ' and I don't get any difference in the results.