Service Notifications
Service Notifications
Is it possible to have service checks send emails with attachments upon alerts. I have three servers I watch eventlogs (Windows Event Logs) on and the contacts would like the output be in an email attachment so as to obtain all the data and not be limited to the X amount of characters that Nagios has imposed on the service checks. One web server is a "Windows 2008", two are "Windows 2003", and the Nagios instance is "Nagios XI 2012R2.5".
-
sreinhardt
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: Service Notifications
Presently this isn't really possible. You would need to ship the logs off to the nagios system, and then include them via email. Provided you could get the logs or portions that you needed to the nagios system, it may be possible to include them using an additional macro or something of that nature. Additionally, an easier solution might be to attempt a modification to your service command that will include the lines that are causing the warning or error from the event log. This would depend on the plugin you are using, but is likely possible to do.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
Re: Service Notifications
What about this? I found this forum thread, but I cannot get an attachment:
http://support.nagios.com/forum/viewtop ... =7&t=22213
http://support.nagios.com/forum/viewtop ... =7&t=22213
Re: Service Notifications
That thread was actually the opposite issue, in that the user got an unwanted attachment and was trying to get rid of it.
As sreinhardt mentioned, you would need to get the logs onto the Nagios server before you would be able to attach them in an email. Barring that, you would need to modify your plugin to output the offending log lines, again as sreinhardt had said.
As sreinhardt mentioned, you would need to get the logs onto the Nagios server before you would be able to attach them in an email. Barring that, you would need to modify your plugin to output the offending log lines, again as sreinhardt had said.
Former Nagios employee
Re: Service Notifications
OK, I apologize for the misunderstanding and thanks for the clarification.
-
slansing
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: Service Notifications
Excellent, let us know if you need help.
Re: Service Notifications
This can be closed, we have decided to test out the nagios log server.