Bulk modify services template

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Bulk modify services template

Post 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
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Bulk modify services template

Post 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.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Re: Bulk modify services template

Post by brdr »

okie, thanks. Look forward to the next major release :)
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Bulk modify services template

Post by abrist »

As do we all :) Are we clear for locking, or do you have a further inquiry concerning this?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Re: Bulk modify services template

Post 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.
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Re: Bulk modify services template

Post 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?
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Bulk modify services template

Post 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.
Former Nagios employee
brdr
Posts: 312
Joined: Mon Jun 02, 2014 12:49 pm

Re: Bulk modify services template

Post 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.
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Bulk modify services template

Post 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.
Former Nagios employee
Locked