How to customize nagios alerts?

Aravinth Anto t-aravinth at juspay.in
Mon Sep 17 11:10:07 CEST 2012


On Mon, Sep 17, 2012 at 7:34 AM, PRA <nagiospra at gmail.com> wrote:

>  if your echo statement has $stacktrace it will print that only till to
> the limit "Additional Info field".
>
> NAGIOS gets string and return code from its plugins.String is to print the
> message and return code is to identify the type of alert
> (ok,warning,critical).
> So as long as you send it to nagios to this format it identifies.
>
> Now coming to your script, you echo statements at the last part of IF ,
> Should have your stack trace.
>
> ============SNIP=============
>
>         then
>             echo "$stacktrace"    #### The stack trace should hold the
> stack trace string.
>         exit $ST_CR
>
> ===========SNIP===========
>
>
> -PRA
>
>
Thanks for your reply. It works now.


> On 9/15/2012 8:56 AM, Aravinth Anto wrote:
>
> Hi
>
>  Thanks for the reply. I have attached my script. And if I say I'm
> returning the stack trace from my script, how come Nagios will know that? I
> can name the hole stack trace a name and can use $stacktrace in nagios will
> work?
>
>  Thanks in advance.
>
> On Sat, Sep 15, 2012 at 12:31 AM, PRA <nagiospra at gmail.com> wrote:
>
>>  The script shoud generate two types of out put (return code and text ),
>> If the can be anything if you pass the stack trace to text it would print
>> that only
>> in the alerts
>> -S
>>
>>
>> On 9/14/2012 7:22 PM, Aravinth Anto wrote:
>>
>>  Hello all,
>>
>>  I wish to customize my email alerts that is sent by Nagios. Say for
>> example, I want to send the email along with error trace of Tomcat which
>> caused the exception.
>>
>>
>>  Are there any ways to do it?
>>
>>
>>  Thanks in advance.
>>
>>
>>
>>
>>   ------------------------------------------------------------------------------
>> Got visibility?
>> Most devs has no idea what their production app looks like.
>> Find out how fast your code is with AppDynamics Lite.http://ad.doubleclick.net/clk;262219671;13503038;y?http://info.appdynamics.com/FreeJavaPerformanceDownload.html
>>
>>
>>
>> _______________________________________________
>> Nagios-users mailing listNagios-users at lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/nagios-users
>> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
>> ::: Messages without supporting info will risk being sent to /dev/null
>>
>>
>>
>>
>> ------------------------------------------------------------------------------
>> Got visibility?
>> Most devs has no idea what their production app looks like.
>> Find out how fast your code is with AppDynamics Lite.
>> http://ad.doubleclick.net/clk;262219671;13503038;y?
>> http://info.appdynamics.com/FreeJavaPerformanceDownload.html
>> _______________________________________________
>> Nagios-users mailing list
>> Nagios-users at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/nagios-users
>> ::: Please include Nagios version, plugin version (-v) and OS when
>> reporting any issue.
>> ::: Messages without supporting info will risk being sent to /dev/null
>>
>
>
>
> ------------------------------------------------------------------------------
> How fast is your code?
> 3 out of 4 devs don\\\'t know how their code performs in production.
> Find out how slow your code is with AppDynamics Lite.http://ad.doubleclick.net/clk;262219672;13503038;z?http://info.appdynamics.com/FreeJavaPerformanceDownload.html
>
>
>
> _______________________________________________
> Nagios-users mailing listNagios-users at lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
> ::: Messages without supporting info will risk being sent to /dev/null
>
>
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Nagios-users mailing list
> Nagios-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when
> reporting any issue.
> ::: Messages without supporting info will risk being sent to /dev/null
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20120917/b4f1db49/attachment.html>
-------------- next part --------------
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
-------------- next part --------------
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null


More information about the Users mailing list