Page 1 of 1

Bulk Mods - Check Period not updating

Posted: Fri Apr 15, 2016 9:34 am
by brdr
Hi guys,

I don't know when this has changed but is used to work perfectly before.....

When I run Bulk Modifications, to change a single config option, I select 'check period' and purposefully don't put a new value because I do not want 'check period' at the service level to have a value because the template for the service check handles the check period. When I save and apply configuration the 'check period' doesn't get updated. This same is true for 'notification period'. I have thousands of checks with various groups of time periods that I need to maintain at the template level.

How can run bulk mods with value of blank for these periods? NOTE: when I change value to blank for interval settings it works just fine. Something about these periods... Sorry if this known issue.

Thx

Re: Bulk Mods - Check Period not updating

Posted: Fri Apr 15, 2016 10:15 am
by rkennedy
I just tried to do the same, and was able to replicate this. The Notification period, and check period both were not going blank.

I have filed a bug report for this, ID 8285. Thanks for letting us know.

Re: Bulk Mods - Check Period not updating

Posted: Fri Apr 15, 2016 11:18 am
by brdr
Thank you for verifying and submitting the bugger.

Re: Bulk Mods - Check Period not updating

Posted: Fri Apr 15, 2016 12:17 pm
by bwallace
Are we OK to close this thread brdr, or were there additional questions on the topic?

Re: Bulk Mods - Check Period not updating

Posted: Fri Apr 15, 2016 12:17 pm
by bheden
Thanks for bringing this to our attention. We've fixed it on our end, and it will be available at the next release. In the meantime: if you need this functionality right now, you can run the following command on the NagiosXI server:

Code: Select all

sed -i 's/.*SELECT id from.*/if \(\$timeperiod != \"\"\) { &/;s/\$value = \$timeperiod_id;/& }/' /usr/local/nagiosxi/html/includes/components/bulkmodifications/bulkmodifications.inc.php
Hope this helps.

Re: Bulk Mods - Check Period not updating

Posted: Fri Apr 15, 2016 12:39 pm
by brdr
That is awesome. Ran it, then bulk'ed up. All good. Thx n plz close.

u guys rock!

Re: Bulk Mods - Check Period not updating

Posted: Fri Apr 15, 2016 12:56 pm
by bwallace
Glad we were able to help. We'll lock this thread now and feel free to open another should you require assistance with anything else.