Page 1 of 1

Customize Status Meassages

Posted: Tue May 20, 2014 4:05 am
by tariqondego
Is it possible to customize status messages?
I have a scenario in which I just want to tcp to an application,though not conect to it.
So,a 'Connection refused' message would be ok,because that would show the application is running because it refused the connection.
How can i customize nagios to display green, 'OK' for status and 'OK' for status information? in this scenario and red for any other scenario

Re: Customize Status Meassages

Posted: Tue May 20, 2014 9:23 am
by slansing
That would be controlled by the plugin's output itself, you would need to alter the exit codes / echoed messages that accompany them.

https://nagios-plugins.org/doc/guidelines.html

Nagios relies on Unknown, OK, Warning, and Critical thresholds for more than just display, for instance, it is what is used to effectively complete your reports, as well as control alerts, and event handlers. I would not toy too much with that. You may be able to change just the color of the output but still retain the normal state.

Re: Customize Status Meassages

Posted: Tue May 20, 2014 9:31 am
by tmcdonald
You can also reverse the status of OK/Critical by using the "negate" plugin:

http://assets.nagios.com/downloads/nagi ... Plugin.pdf

Re: Customize Status Meassages

Posted: Wed May 21, 2014 5:30 am
by tariqondego
Thnaks alot guys,negate will do for now.