Page 1 of 1

Bulk modify services template

Posted: Fri May 01, 2015 11:52 am
by brdr
Hi

We have Nagios XI 2014 R2.3.

Under the Tools link in CCM there is Bulk Modifications. I need to change about 800 service checks for network switches (bandwidth/status). We use templates extensively. I need to change the assigned template these service checks use. Rather than open up each service, remove the exisiting template it uses (it is valid and currently used) and assign a different (new) template is there a bulk way to do this as I do not see an option.

Thanks

Re: Bulk modify services template

Posted: Fri May 01, 2015 12:13 pm
by abrist
It is not currently an option in XI. This feature has been requested many times and development work has been done to add many new features to the bulk mod tool (including this). Expect to see many additions to the bulk mod tool in the next major XI release. For now, you will either have to do it by hand or *very carefully* perform the changes with a nagiosql query.

Re: Bulk modify services template

Posted: Fri May 01, 2015 12:27 pm
by brdr
okie, thanks. Look forward to the next major release :)

Re: Bulk modify services template

Posted: Fri May 01, 2015 12:28 pm
by abrist
As do we all :) Are we clear for locking, or do you have a further inquiry concerning this?

Re: Bulk modify services template

Posted: Fri May 01, 2015 1:45 pm
by brdr
actually... is there a way to default to different service templates (rather than its defaults xiward_switch_port and bandwidth_service) within the Network Switch Configuration Wizard in CCM?

This would be a good workaround.

Re: Bulk modify services template

Posted: Fri May 01, 2015 2:01 pm
by brdr
If i change these two lines in /usr/local/nagiosxi/html/includes/configwizards/switch/switch.ini.php

"use" => "xiwizard_switch_port_status_service",
"use" => "xiwizard_switch_port_status_service",

to a different template, then run the wizard, will that work?

Re: Bulk modify services template

Posted: Fri May 01, 2015 2:16 pm
by tmcdonald
*Should* work but I have not tested it. Give it a shot! Otherwise I can check it out Monday and let you know.

Re: Bulk modify services template

Posted: Sat May 02, 2015 4:30 am
by brdr
It worked!

NOTE: There were two places in the switch.inc.php to change 'xiwizard_switch_port_status_service' to my new status port template name.

Thx. Please close.

Re: Bulk modify services template

Posted: Mon May 04, 2015 9:06 am
by tmcdonald
Great!

Just remember that these changes (as well as others that you make on your own) may be overwritten on some upgrades, and certainly if you update the wizard directly.