Hi,
I know that I can use vfs.file.time and then put .fuzzytime in a trigger if I want to be alerted to a file being modifier / not being modified.
However, if I then view the item's data, I just get a straight line since 1970. What I want is for the individual item to record the age of the file on disk, as a number of seconds ago.
Currently, to do this, we use a small shell script as a UserParameter, but this feels like something that perhaps many Zabbix users would like to have.
The patch necessary to libs/zbxsysinfo/common/file.c is very small, and I'm happy to supply this if someone can suggest a suitable function name or syntax. Should it be vfs.file.timedelta, whose syntax is identical to vfs.file.time, or would it be preferable to have an additional parameter to the existing vfs.file.time item to control whether to return absolute file age in epoch seconds, or the delta between now and file time?
Of course, if this functionality already exists, I'd be really grateful if someone can point it out.
I know that I can use vfs.file.time and then put .fuzzytime in a trigger if I want to be alerted to a file being modifier / not being modified.
However, if I then view the item's data, I just get a straight line since 1970. What I want is for the individual item to record the age of the file on disk, as a number of seconds ago.
Currently, to do this, we use a small shell script as a UserParameter, but this feels like something that perhaps many Zabbix users would like to have.
The patch necessary to libs/zbxsysinfo/common/file.c is very small, and I'm happy to supply this if someone can suggest a suitable function name or syntax. Should it be vfs.file.timedelta, whose syntax is identical to vfs.file.time, or would it be preferable to have an additional parameter to the existing vfs.file.time item to control whether to return absolute file age in epoch seconds, or the delta between now and file time?
Of course, if this functionality already exists, I'd be really grateful if someone can point it out.
Comment