View Full Version : triggers for a host unreachable for 10 mins
let's say I want a trigger to be True only when a host is unreachable for 10 mins or more, how should i write the expression?
i tried {host:status.min(600)}=2 but it triggers as soon as the host goes offline
i also tried {JurongPoint.AD:ping.nodata(600)}=1 but the status is unknown when the host is down
thanks
I don't know why your statement doesn't work.
Try this:
{host:status.min(600)}>1
I've tested and it seems to work quite nicely.
For example, Triggers won't be activated during regularly scheduled reboots.
according to http://sourceforge.net/forum/message.php?msg_id=1911027, it seems to show that there wun be any data until the host goes down. so the min of 10 mins will be (nodata, 2), which is 2. all the 20 win/linux host i monitoring seems to exhibit this behaviour
So any resolution to your problem?
I realized that my statement also didn't work. It also triggers as soon
as a server goes down.
I've tried tweaking different things, but there must be something we are
doing wrong.
Anyone out there who can help us, please?
I believe combination of last() and nodata() would be useful. Something like:
({host:status.last(0)}=2)&({host:status.nodata(600)}=1)
Yes, it's not very obvious but should work.
I'm open to discuss any ideas for new trigger functions! I'm sure more elegant solution can be implemented.
Alexei,
Thank you for your reply.
Zabbix is a great tool, and I really appreciate all the excellent work that you've done.
Thanks again,
Jeff
Alexei,
I gave that a try, but it seems that it doesn't work.
EDIT: let me try to clarify; the trigger never activates. It never triggers even though the "nodata(time)" has been satisfied.
I'm looking at the Alarms page, and I see that the time for "False" exceeds the time parameter in nodata().
After reading the manual, it turns out that the nodata can only be used with zabbix trapper items and not zabbix agent items.
status is a zabbix agent type item, so it looks like this parameter doesn't work with nodata.
I know it looks silly, but the following seems to work, but only if the interface is down:
({host:status.last(0)}=2)&({host:status.min(600)}=2)
I do not know why if the server reboots the item is still triggered.
Edit: It looks as if the status.min parameter only works if the network interface is down. There must be a way for it to work if the server reboots.
Any help is greatly appreciated!
Thanks in advance,
Jeff
So the crux of the issue seems to be that following statement does not work as advertised:
{host:status.min(600)}=2
No matter what time period is specified, it seems to trigger immediately.
This is just driving me nuts! Anyone got any suggestions?
Does anyone have a working answer?
The following only triggers between 8AM and 6PM:
({host:status.last(0)}=2)&({host:status.time(0)}>080000)&({host:status.time(0)}<180000)
I mean, I can set the time parameters for a range of time to monitor servers, but that kinda defeats the purpose of a monitoring tool, doesn't it? :)