PDA

View Full Version : Problem with mail.queue.count.last Value as Displayed in Alert EMails


rob9988
28-06-2006, 03:04
We're currently having a great experience with Zabbix v1.1 to date, so thanks to the development team for creating such a great product.

Unfortunately, we occasionally run into some interesting bugs/problems, and I have one that I can't solve. We are using Zabbix to monitor the total size and number of messages in our mail queue. The items and triggers work fine, but we have discovered that the value for one of the variables sent in the alert email when the trigger is activated is incorrect.

Here's the message, as defined in the action:
-------------------------------------------------------------------------------------------
The queue on {HOSTNAME} is too large.

# of emails in queue: {HOSTNAME:mail.queue.count.last(0)}
Size of queue: {HOSTNAME:mail.queue.size.last(0)}
--------------------------------------------------------------------------------------------

The problem is that both mail.queue.count.last and mail.queue.size.last show the value of mail.queue.size.last in the alert email. When we look at the values and graphs for these items in the Zabbix interface, mail.queue.count.last shows the correct number of messages in the queue, and mail.queue.size.last shows the correct total size of the mail queue.

Odd, don't you think? We're stumped. Any suggestions?

Thanks,

-Rob

rob9988
28-06-2006, 23:11
I obviously (!) forgot to post some information relating to my initial question. Here it is:

UserParameter=mail.queue.count,ls -l /var/spool/mqueue | wc -l | cut -f1
UserParameter=mail.queue.size,du -b /var/spool/mqueue | cut -f1

Thanks,

=-Rob

gatrfan
03-11-2006, 22:29
Got this working finally, wanted to monitor/graph inbound/outbound mail queues...works great! However, I am sending SMS notifications and it would be nice to have the actual VALUE available in the email message. How would I go about doing that?

Thanks in advance.
gatrfan

Alexei
04-11-2006, 08:16
This should work:

# of emails in queue: {{HOSTNAME}:mail.queue.count.last(0)}
Size of queue: {{HOSTNAME}:mail.queue.size.last(0)}

Not that there was a problem handling "recursive" macros in 1.1.2, so use different release.