Is there any possibility under nagios settings to gets notification based on status information/data (attached picture), similar to SNMP trap monitoring?
For example, I'm using 'check_multi' plugin who check about 10 tcp listen ports on one server, so my problem is that when any of this ports going down I get first notification and the service state is critical, wich is ok, but in next check it can be situation that another parallel port is also down and in this situation I don't get notification because of the first one. So for me it would be great when I could get notification based on every status information changes, something like stalking options for logging.
SOLVED. notification based on status information/data
SOLVED. notification based on status information/data
Last edited by marcha83 on Sun Feb 28, 2016 5:57 am, edited 1 time in total.
Re: notification based on status information/data
This should be possible, except it sounds like you're looking to monitor each individual port.
I think this would be better handled with a check, per each port, thus giving you the notifications based on the different ports states.
Is there a specific reason you're using check_multi instead?
I think this would be better handled with a check, per each port, thus giving you the notifications based on the different ports states.
Is there a specific reason you're using check_multi instead?
Former Nagios Employee
Re: notification based on status information/data
Well, monitoring each individual port as particular check is always option. But, if you have 50 servers and each server has about 10 different listen tcp ports that you need to check and not only the ports, you can combine with other checks, so i think it is much more work than when you use one check_multi plugin and just need to change config.cmd. E.g. my config.cmd
command [ listen_443 ] = check_tcp -p 443
command [ listen_80 ] = check_tcp -p 80
command [ listen_oracle_1524 ] = check_tcp -p 1524
....
....
But as I wrote the problem is with notifications, that's why I open this topic.
command [ listen_443 ] = check_tcp -p 443
command [ listen_80 ] = check_tcp -p 80
command [ listen_oracle_1524 ] = check_tcp -p 1524
....
....
But as I wrote the problem is with notifications, that's why I open this topic.
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: notification based on status information/data
Unfortunately this is how core works, the only way around it would be to write an event handler that tracked the last state and sent a notification if it changed.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: notification based on status information/data
I found workaround solution with event handler based on Box293 hint, this is steps:
1. create service that over ssh runs check_multi plugin on remote server
2. enable 'Is Volatile' option
3. disable default notification
4. create 'event handler' who calls my script that based on $SERVICEOUTPUT$ standard macros checks if there is differences. If have difference call service notification (nagios_send_service_mail.pl --> http://nagios.fm4dd.com/howto/nagios-fl ... ations.htm) and that's it.
I had problems with $CONTACEMAIL$ and $NOTIFICATIONTYPE$ macros because (https://assets.nagios.com/downloads/nag ... olist.html) this macros is not available, so i had to improvise in my event handler script.
I hope it could help someone with similar issues.
1. create service that over ssh runs check_multi plugin on remote server
2. enable 'Is Volatile' option
3. disable default notification
4. create 'event handler' who calls my script that based on $SERVICEOUTPUT$ standard macros checks if there is differences. If have difference call service notification (nagios_send_service_mail.pl --> http://nagios.fm4dd.com/howto/nagios-fl ... ations.htm) and that's it.
I had problems with $CONTACEMAIL$ and $NOTIFICATIONTYPE$ macros because (https://assets.nagios.com/downloads/nag ... olist.html) this macros is not available, so i had to improvise in my event handler script.
I hope it could help someone with similar issues.
Re: notification based on status information/data
Thanks for your contribution!
Are we good to mark this thread as resolved?
Are we good to mark this thread as resolved?
Former Nagios Employee
Re: notification based on status information/data
Before it gets closed, another option would be BPI where you can tell it how many things have to fail before it's considered a problem. Don't know if it really helps you, but it might be worth looking into.
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoyd
I'm a Nagios Fanatic! • Join our public Nagios Discord Server!
Re: notification based on status information/data
Excellent tip there, eloyd. Keep us posted marcha83.
Be sure to check out the Knowledgebase for helpful articles and solutions!
Re: notification based on status information/data
I think that we could mark this thread as solved. Any hint how to do it, I don't have experience?
Re: notification based on status information/data
Are you talking about BPI or something else, now? If you're looking for information on BPI, this document (https://assets.nagios.com/downloads/nag ... BPI_v2.pdf) has a great overview of how it works.
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoyd
I'm a Nagios Fanatic! • Join our public Nagios Discord Server!