[icinga-checkins] icinga.org: icinga2/next: Migration: Fix timeperiod object name stripping.

git at icinga.org git at icinga.org
Wed Nov 27 13:25:32 CET 2013


Module: icinga2
Branch: next
Commit: c25a7d580bda70f5f3f5e832161c38351f0e4687
URL:    https://git.icinga.org/?p=icinga2.git;a=commit;h=c25a7d580bda70f5f3f5e832161c38351f0e4687

Author: Michael Friedrich <michael.friedrich at netways.de>
Date:   Wed Nov 27 13:25:00 2013 +0100

Migration: Fix timeperiod object name stripping.

Fixes #5230

---

 tools/migration/icinga2-migrate-config |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/tools/migration/icinga2-migrate-config b/tools/migration/icinga2-migrate-config
index 4bcc2d4..aac1ae2 100755
--- a/tools/migration/icinga2-migrate-config
+++ b/tools/migration/icinga2-migrate-config
@@ -433,7 +433,8 @@ sub parse_icinga1_object_cfg {
                     $attr =~ /groups/ ||
                     $attr =~ /members/ ||
                     $attr =~ /use/ ||
-                    $attr =~ /parents/
+                    $attr =~ /parents/ ||
+                    $attr =~ /_period/
                 ) {
                 $val = strip_object_name($val);
             }
@@ -479,7 +480,7 @@ sub parse_icinga1_objects_cache {
 
     my $cfg_obj_cache = {};
 
-    print "Processing file '$cfg_file'...\n";
+    print "Processing file '$object_cache_file'...\n";
     $cfg_obj_cache = parse_icinga1_object_cfg($cfg_obj_cache, $object_cache_file);
 
     #say Dumper($cfg_obj_cache);





More information about the icinga-checkins mailing list