How to read a keyword from a txt file in zabbix

fileszabbix

I want to know is there are any solution for my to read the word "Error" from a txt file on solaris and Alert me where the Error is found. I tried to create a item of type zabbix agent active but it did not work please help

Best Answer

Use log file monitoring. For example:

logrt["/export/home/user/file.txt","Error",,1]

You can then set a trigger on it, if you wish:

{myserver.example.com:logrt["/export/home/user/file.txt","Error",,1].nodata(600)}=0

A tutorial is available on the Internet that expands on this a bit.