Page 1 of 1

Location of service check threshold settings

Posted: Thu Sep 27, 2018 2:42 pm
by awilson
I'm probably missing an obvious point. Where are the threshold's for service checks stored? Is there a direct path to list the threshold settings for each service check?

Thanks

Re: Location of service check threshold settings

Posted: Thu Sep 27, 2018 3:46 pm
by benjaminsmith
Hello,

The thresholds for service checks are stored in the configuration files for each service. In Nagios XI, you can edit these levels in the CCM or Core Configuration Manager.

Go to Configure > Advanced Configuration > Services and the Common Settings for each service, and you'll be able to review and edit settings.

Re: Location of service check threshold settings

Posted: Sun Sep 30, 2018 11:26 pm
by awilson
We have a request to report the threshold settings for a large number of network devices. I do not see those thresholds in the services/xxxx.cfg files or any other files. Are they stored in a database?

Thanks

Re: Location of service check threshold settings

Posted: Mon Oct 01, 2018 10:44 am
by lmiltchev
Unfortunately, obtaining this type of report is simply impossible for a couple of reasons:

1. The thresholds could be defined in many different places, e.g. in the service config, in the template that this service is using, in the check_command... Each plugin is different, so it's impossible to come up with a report that will work for all plugins.
2. The thresholds may not even defined "locally", on the Nagios XI server. You may have a command, defined on the remote machine (host) that you are monitoring via check_nrpe, check_nt, check_ncpa.py, etc.

Re: Location of service check threshold settings

Posted: Mon Oct 01, 2018 11:27 am
by BanditBBS
I have been asked for this report since I first started using Nagios in the early 2000's. At my current job I've been asked for it for 4 years and just the other day I finally wrote a script to export the thresholds into CSV files for specific checks that make sense. I'll attach the script, but unless you understand shell coding(crappy shell coding) it won't do you any good as things would need changed for your environment.

Basically it reads the setup from the database and the lines like:

Code: Select all

check_nrpe_cpu!70,80,40!90,90,80
And breaks that up with good column headers so others can understand what on earth the are looking for. That line in original form is only readable by me, my 2 other XI admins more than likely would have hard time explaining what it means. Now, with the script I wrote, when someone wants the report, we run it, supply an email address and they receive a bunch of CSV files and can then extract form that the information for the items they want and understand what it all is.

Re: Location of service check threshold settings

Posted: Mon Oct 01, 2018 11:45 am
by lmiltchev
Thanks for sharing @BanditBBS! I don't remember seeing any scripts that could be used for reporting on the threshold settings before... That was the first. :)

@awilson, let us know if you were able to modify the script enough, so that it works in your environment. We will appreciate your feedback. Thanks!

Re: Location of service check threshold settings

Posted: Tue Oct 09, 2018 11:03 pm
by awilson
Thank you! We'll check and reply.

Alan

Re: Location of service check threshold settings

Posted: Wed Oct 10, 2018 8:07 am
by scottwilkerson
awilson wrote:Thank you! We'll check and reply.

Alan
Let us know if we can be of further assistance.