I have been trying to monitor a simple backup job on a testserver via WinRPE.
I try to monitor if the file B:\WindowsImageBackup\NagiosBackup\Catalog\GlobalCatalog is older then 1 hour, with this command:
check_winfile --target B:\WindowsImageBackup\NagiosBackup\Catalog\GlobalCatalog --filter "age le -1 hours" --critical 0
It works perfectly when I do that local, on the Backup Server,
however when copy-paste that command in nrpe.cfg and try to monitor via NRPE,
the Nagios Server says: FILE UNKNOWN - Target does not exist.
Even stranger: when I reduce the command in nrpe.cfg to
check_winfile --target B:\WindowsImageBackup --filter "age le -1 hours" --critical 0
it works, when I add the next folder to that path, it doesn't anymore.
I must be doing something wrong.