Hi Jaap,
A very long time ago, I did this kind of dirty thing:
file:find /var/lock/ -maxdepth 1 -type f -name backup.lock -mmin +60
I'm not proud of, but it works... So you can adapt easily with the
"find" command features.
Regards,
Le 12/07/2018 à 20:36, Jaap Winius a écrit :
Hi folks,
According to http://xymon.sourceforge.net/xymon/help/manpages/man5/client-local.cfg.5.htm it's possible to add file configuration entries to /etc/xymon/client-local.cfg. For example, to check for the existence of a file called /tmp/krb5cc_0 on host.example.com, I'd add this stanza:
[bap1.umrk.nl] file:/tmp/krb5cc_0
That works. However, the above mentioned manpage also says this about file configuration entries:
"A file monitoring entry is used to watch the meta-data of a file: Owner, group, size, permissions, checksum etc."
Meta data? How is that done? Except for some hash settings, no examples are given. To check to see if the example file is always less than 3600 seconds old, I would think something like this would be necessary:
[bap1.umrk.nl] file:/tmp/krb5cc_0 mtime<3600
Or possibly:
[bap1.umrk.nl] file:/tmp/krb5cc_0:mtime<3600
But, these don't seem to work: Xymon still only reports that the file exists.
Would anyone mind explaining what the correct syntax is for this file test and perhaps other ones like it (e.g. for owner, group, file size, permissions)?
Thanks,
Jaap
Xymon mailing list Xymon at xymon.com http://lists.xymon.com/mailman/listinfo/xymon
-- Cordialement, Damien Martins