Page 1 of 1
NCPA Configuration Wizard - Howto Modify Default Metrics.
Posted: Wed Aug 02, 2017 9:55 am
by TBT
We're looking to modify default metrics within the NCPA Configuration Wizard. For example, CPU warning and alarm thresholds. I've viewed Host Template Management for NCPA, however, these values differ from what is shown within the Wizard.
Please advise.
Re: NCPA Configuration Wizard - Howto Modify Default Metrics
Posted: Wed Aug 02, 2017 1:01 pm
by tmcdonald
The wizard (to my knowledge) does not use the host template values when populating the defaults in its configuration phase. You would need to modify the wizard, located under
/usr/local/nagiosxi/html/includes/configwizards/ncpa. There are some references in
ncpa.inc.php like:
Code: Select all
// Set defaults for services
$default_services['cpu_usage']['monitor'] = 'on';
$default_services['cpu_usage']['warning'] = 20;
$default_services['cpu_usage']['critical'] = 40;
$default_services['cpu_usage']['average'] = 1;
$default_services['memory_usage']['monitor'] = 'on';
$default_services['memory_usage']['warning'] = 50;
$default_services['memory_usage']['critical'] = 80;
$default_services['swap_usage']['monitor'] = 'on';
$default_services['swap_usage']['warning'] = 50;
$default_services['swap_usage']['critical'] = 80;
Re: NCPA Configuration Wizard - Howto Modify Default Metrics
Posted: Wed Aug 02, 2017 1:18 pm
by TBT
tmcdonald wrote:The wizard (to my knowledge) does not use the host template values when populating the defaults in its configuration phase. You would need to modify the wizard, located under
/usr/local/nagiosxi/html/includes/configwizards/ncpa. There are some references in
ncpa.inc.php like:
Code: Select all
// Set defaults for services
$default_services['cpu_usage']['monitor'] = 'on';
$default_services['cpu_usage']['warning'] = 20;
$default_services['cpu_usage']['critical'] = 40;
$default_services['cpu_usage']['average'] = 1;
$default_services['memory_usage']['monitor'] = 'on';
$default_services['memory_usage']['warning'] = 50;
$default_services['memory_usage']['critical'] = 80;
$default_services['swap_usage']['monitor'] = 'on';
$default_services['swap_usage']['warning'] = 50;
$default_services['swap_usage']['critical'] = 80;
When the module updates these config changes wouldn't carry over. Perhaps Nagios will consider a templating in the next release?
Re: NCPA Configuration Wizard - Howto Modify Default Metrics
Posted: Wed Aug 02, 2017 1:58 pm
by tmcdonald
We have templating currently, but it only affects steps 3-5 (the pages that are common to all wizards). It is my understanding that wizards are being overhauled in XI 6, but I do not at this time have specifics on what will be configurable.