Hi Brian,
Thank you for your reply and pointing me to the correct logfile. I replayed the state (warning) of one of my services, and got this in the notify.log:
---->
2016-07-12 16:31:35 Got raw notification (Chat4all.IRC;US_idleRPG_process) context with 52 variables
2016-07-12 16:31:35 Global rule 'Notify all contacts of a host/service via HTML email'...
2016-07-12 16:31:35 -> matches!
2016-07-12 16:31:35 User jeroenw's rule 'notify 1'...
2016-07-12 16:31:35 -> matches!
2016-07-12 16:31:35 - adding notification of jeroenw via mail
2016-07-12 16:31:35 User pushover's rule ''...
2016-07-12 16:31:35 -> matches!
2016-07-12 16:31:35 - adding notification of pushover via pushover
2016-07-12 16:31:35 User pushover's rule ''...
2016-07-12 16:31:35 -> does not match: This rule is disabled
2016-07-12 16:31:35 Executing 2 notifications:
2016-07-12 16:31:35 * notifying jeroenw via mail, parameters: url_prefix, reply_to, elements, from, service_subject, no_floating_graphs, host_subject, bulk: no
2016-07-12 16:31:35 executing /omd/sites/mon/share/check_mk/notifications/mail
2016-07-12 16:31:36 Output: Unable to fetch number of graphs: Unable to fetch graph infos: <p>XML file "/omd/sites/mon/var/pnp4nagios/perfdata/Chat4all.IRC/US_idleRPG_process.xml" not found. <a href="http://docs.pnp4nagios.org/faq/6">Read FAQ online</a></p>
2016-07-12 16:31:37 * notifying pushover via pushover, parameters: priority, recipient_key, api_key, url_prefix, bulk: no
2016-07-12 16:31:37 executing /omd/sites/mon/share/check_mk/notifications/pushover
2016-07-12 16:31:37 Output: Traceback (most recent call last):
2016-07-12 16:31:37 Output: File "/omd/sites/mon/share/check_mk/notifications/pushover", line 147, in <module>
2016-07-12 16:31:37 Output: main()
2016-07-12 16:31:37 Output: File "/omd/sites/mon/share/check_mk/notifications/pushover", line 43, in main
2016-07-12 16:31:37 Output: send_push_notification(api_key, recipient_key, subject, text, context)
2016-07-12 16:31:37 Output: File "/omd/sites/mon/share/check_mk/notifications/pushover", line 125, in send_push_notification
2016-07-12 16:31:37 Output: ("timestamp", int(context["MICROTIME"])/1000000),
2016-07-12 16:31:37 Output: KeyError: 'MICROTIME'
2016-07-12 16:31:37 Plugin exited with code 1
<----
User "pushover" has a pushover rule set (and a disabled mail rule, which is the "does not match" line), and it seems it exits with returncode 1 due to a keyerror.
If I read this correctly, it seems there is an error in check_mk's pushover rule somewhere.
Jeroen Wierda
----- Original Message -----
From: "Brian Binder" <brian.binder@gmail.com>
To: "jeroen" <jeroen@wierda.com>
Cc: checkmk-en@lists.mathias-kettner.de
Sent: Tuesday, July 12, 2016 12:20:30 AM
Subject: Re: Pushover notifications
Hey Jeroen!
Thanks for replying with your results. I use check_mk on OMD, so I’m not sure what distro you use. When CMK sends notifications, it’s logged. Mine would be in:
/omd/sites/MYSITE/var/log/notify.log
What I would do as the next step would be to trigger the event, then examine the notify.log file on your distro (wherever it may be, based on your install) and see what it states. If it’s filtered for any reason, it should state that there was a notification triggered, but it was skipped, blacklisted, etc.
I’ve had that happen to me before. If course, you can certainly examine the user and see it there, but the notify.log might give you something you aren’t seeing in an obvious fashion. This way you can search the whole file after making test triggers, for instance.
Let us know!
Brian
On Monday, Jul 11, 2016 at 3:31 PM, Jeroen Wierda <jeroen@wierda.com (mailto:jeroen@wierda.com)> wrote:
Hi Brian,
I actually tested that as well yesterday by creating a new check_mk user, and assigning the pushover pomail address to that user. That works. I also just successfully tested it by sending a mail through the cli, as you suggested (also using Jam Mulch's tip to send it through the site user).
Jeroen Wierda
----- Original Message -----
From: "Brian Binder" <brian.binder@gmail.com>
To: checkmk-en@lists.mathias-kettner.de, "jeroen" <jeroen@wierda.com>
Sent: Monday, July 11, 2016 9:56:24 PM
Subject: Re: Pushover notifications
What I would test fist, to ensure it’s working from the server itself is to manually run the command like so:
echo "mailbody" | mail -s "testpushover" youraddress@pomail.net
Then check out the log file and verify it got sent.
Does that work properly?
Brian
On Monday, Jul 11, 2016 at 12:42 PM, Jeroen Wierda <jeroen@wierda.com (mailto:jeroen@wierda.com)> wrote:
Hi All,
I was wondering how to receive notifications using the pushover app. I have created an app within pushover, and added both the app's api key and my user key to the "push notifications (using pushover)" rule, and attached the rule to a folder. However, the rule does not seem to be triggered that way.
I have also added pushover as notification method to my check_mk userID, which (according to the check_mk notification analysis) resulted in a pushover notification, but nothing is received in Pushover (no credits used).
Maybe i'm missing a configuration component/step? Pushover is working a other applications I use. Is there a way to analyse/debug it more to see what check_mk receives from Pushover (an error or something)?
I'm using check_mk raw version 1.2.8p5.
Best,
Jeroen Wierda
_______________________________________________
checkmk-en mailing list
checkmk-en@lists.mathias-kettner.de
http://lists.mathias-kettner.de/mailman/listinfo/checkmk-en
_______________________________________________
checkmk-en mailing list
checkmk-en@lists.mathias-kettner.de
http://lists.mathias-kettner.de/mailman/listinfo/checkmk-en