Patricia Jung wrote:
> Am 21.03.2011 um 14:59 schrieb Patricia Jung:
>
>> Am 21.03.2011 um 13:58 schrieb Patricia Jung:
>>> when hosts change their host_name in the icinga/nagios configuration the 
>>> history of the relevant checks is obviously lost. How do I adapt historical 
>>> data to the new host_name? What do I need to change -- any cooking recipes?
>>
>> Right, I should be more precise: Are the following steps sufficient?
>>
>> 1. Change host_names in configuration and check configuration
>> 2. Take icinga down and sed retention.dat
>> 3. Change icinga database (in my case mysql)
>>
>>    Anyone with a proven sql statement? If not: What exactly do I have to 
>> change in the database?
>>
>     Would the following sql statement suffice?
>
> update icinga_objects set name1='new-host_name' where name1='old-host_name';

given the fact that the service_descriptions is also put there, you can 
only do that in case you have been keeping all services assigned to that 
host, too. otherwise you will get a bunch of is_active=0 rows after core 
restart (you'll have to clean that most likely yourself).

make sure you'll only update name1 which is marked as active btw.


> Thanks
>
>      Patricia


-- 
DI (FH) Michael Friedrich

Vienna University Computer Center
Universitaetsstrasse 7 A-1010 Vienna, Austria

email:  michael.friedr...@univie.ac.at
phone:  +43 1 4277 14359
fax:    +43 1 4277 14338
web:    http://www.univie.ac.at/zid
        http://www.aco.net

Icinga Core&  IDOUtils Developer
http://www.icinga.org


------------------------------------------------------------------------------
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
_______________________________________________
icinga-users mailing list
icinga-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/icinga-users

Reply via email to