Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Into what file does this go? This is the confusing part do I have to define each host/service for this? For example if I have 44 servers I am checking, that is 44 extra lines I will have to add to the templates.cfg or services.cfg
The only difference between what I wrote and what you already have is the addition of the "!MaxWarn=80% MaxCrit=90% ShowAll type=physical" to the end of your command line in your windows.cfg file.
Gotcha, I'm already part of the way in I just happened to notice that the memory checking was incorrect using check_nt command so I googled around and found this was more efficient. But when I added it like you stated and that is what I gathered from searching, I need to define it somewhere. Disregard the pervasive warning
Error: Service check command 'check_nrpe!checkMem!MaxWarn=80% MaxCrit=90% ShowAll type=physical' specified in service 'Memory Usage' for host 'STLSMS' not defined anywhere!
[root@nagios var]# /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Nagios Core 4.0.8
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 08-12-2014
License: GPL
Website: http://www.nagios.org
Reading configuration data...
Read main config file okay...
Warning: Duplicate definition found for service 'Pervasive' on host 'STLSMS' (config file '/usr/local/nagios/etc/objects/windows.cfg', starting on line 147)
Read object config files okay...
Running pre-flight check on configuration data...
Checking objects...
Error: Service check command 'check_nrpe!checkMem!MaxWarn=80% MaxCrit=90% ShowAll type=physical' specified in service 'Memory Usage' for host 'STLSMS' not defined anywhere!
Checked 69 services.
Checked 10 hosts.
Checked 2 host groups.
Checked 0 service groups.
Checked 1 contacts.
Checked 1 contact groups.
Checked 72 commands.
Checked 5 time periods.
Checked 0 host escalations.
Checked 0 service escalations.
Checking for circular paths...
Checked 10 hosts
Checked 0 service dependencies
Checked 0 host dependencies
Checked 5 timeperiods
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...
Total Warnings: 0
Total Errors: 1
***> One or more problems was encountered while running the pre-flight check...
Check your configuration file(s) to ensure that they contain valid
directives and data defintions. If you are upgrading from a previous
version of Nagios, you should be aware that some variables/definitions
may have been removed or modified in this version. Make sure to read
the HTML documentation regarding the config files, as well as the
'Whats New' section to find out what has changed.
Error: Service check command 'check_nrpe!checkMem!"MaxWarn=80% MaxCrit=90% ShowAll type=physical"' specified in service 'Memory Usage' for host 'STLSMS' not defined anywhere!