Since 5.3.0 Global Event Handlers not working
Since 5.3.0 Global Event Handlers not working
I have 2 Nagios XI servers using Global Event Handlers. Since upgrading to 5.3.0 the Global Event Handlers no longer work. I have uninstalled and reinstalled the Global Event Handler component. Any help would be appreciated.
Thanks
CentOS release 6.7 (Final)
64 bit
manual Install
SSL
Thanks
CentOS release 6.7 (Final)
64 bit
manual Install
SSL
Re: Since 5.3.0 Global Event Handlers not working
What is the version of the "Global Even Handlers" component that you see when you go to Admin->Manage Components? Have you enabled "state changes", "notifications" commands, or both? Can you show us a screenshot?
Can you also give us a specific example of the error that you are getting? Show us relevant configs/logs (hide sensitive info).
Can you also give us a specific example of the error that you are getting? Show us relevant configs/logs (hide sensitive info).
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Since 5.3.0 Global Event Handlers not working
Global Event Handlers - 1.2.0
I'm not getting any errors. Events are not executing.
I have added a screenshot of my Global Event Handler screen.
What logs should I look at?
Thanks
I'm not getting any errors. Events are not executing.
I have added a screenshot of my Global Event Handler screen.
What logs should I look at?
Thanks
You do not have the required permissions to view the files attached to this post.
-
dwhitfield
- Former Nagios Staff
- Posts: 4583
- Joined: Wed Sep 21, 2016 10:29 am
- Location: NoLo, Minneapolis, MN
- Contact:
Re: Since 5.3.0 Global Event Handlers not working
you can post /tmp/nagiosxi/upgrade.log here. Also, if you could PM me your profile that will help us. Admin -> System Profile (Under System Config) -> Download Profile.
Re: Since 5.3.0 Global Event Handlers not working
In addition to what dwhitfield said, start a running tail on the "event_handler.log":
then go to Home->Host Detail, click on a host, go to "Advanced" tab, and submit a passive check result to change the current state of the host. Check the output of the tail command to see if anything shows up there.
You can do a very simple test by creating a bash script, i.e. "test.sh" as such:
Place it in /tmp, and made it executable:
Add it to your global event handler.
and click on "Apply Settings". Create a host state change, and check to see of the "/tmp/test.txt" file was created.
Code: Select all
tail -f /usr/local/nagiosxi/var/event_handler.logYou can do a very simple test by creating a bash script, i.e. "test.sh" as such:
Code: Select all
#!/bin/bash
DATE=$(date)
echo "The host has changed state at $DATE" >> /tmp/test.txtCode: Select all
chmod +x /tmp/test.shand click on "Apply Settings". Create a host state change, and check to see of the "/tmp/test.txt" file was created.
Code: Select all
cat /tmp/test.txtYou do not have the required permissions to view the files attached to this post.
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
dwhitfield
- Former Nagios Staff
- Posts: 4583
- Joined: Wed Sep 21, 2016 10:29 am
- Location: NoLo, Minneapolis, MN
- Contact:
Re: Since 5.3.0 Global Event Handlers not working
Profile stored internally at T:\Forum Files\mcauble50
Re: Since 5.3.0 Global Event Handlers not working
I did the tail on the event_handler.log
Created the bash script, made it executable.
Added it to the Global Event Handler
Created a state change. I see the event come up in the event_hander log. But, it never fires off the script.
Which is what I have been seeing on 2 different Nagios servers, since the upgrade.
Let me know if there is anything else you need.
Thanks
Created the bash script, made it executable.
Added it to the Global Event Handler
Created a state change. I see the event come up in the event_hander log. But, it never fires off the script.
Which is what I have been seeing on 2 different Nagios servers, since the upgrade.
Let me know if there is anything else you need.
Thanks
Re: Since 5.3.0 Global Event Handlers not working
It sounds like there may be a permission issue on the script you're executing at this point. What is the output of ls -la /path/to/your/script.sh?
Former Nagios Employee
Re: Since 5.3.0 Global Event Handlers not working
-rwxrwxr-x 1 apache nagios 6233 Oct 3 14:53 /usr/local/nagios/libexec/check_alert
This has been working for months. Quit working after latest upgrade.
Thanks
This has been working for months. Quit working after latest upgrade.
Thanks
Re: Since 5.3.0 Global Event Handlers not working
Also as a test. I set the above script (check_alert) as a local event_handler on a host. Then submitted a passive check to create a state change. The script executed as expected.
Thanks
Thanks