From 26f294864336dc92d829a7eb2c0f16f770023e23 Mon Sep 17 00:00:00 2001 From: zhaoertao Date: Tue, 19 Aug 2014 00:25:42 -0700 Subject: [PATCH] fix bug 4251:nodeset return xnba plugin bug, pid 657 when node mac is not defined --- xCAT-server/lib/perl/xCAT/Template.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xCAT-server/lib/perl/xCAT/Template.pm b/xCAT-server/lib/perl/xCAT/Template.pm index 523644b04..5cf62948f 100644 --- a/xCAT-server/lib/perl/xCAT/Template.pm +++ b/xCAT-server/lib/perl/xCAT/Template.pm @@ -671,9 +671,9 @@ sub kickstartnetwork { my $line = "network --onboot=yes --bootproto="; my $hoststab; my $mactab = xCAT::Table->new('mac',-create=>0); - unless ($mactab) { die "mac table should always exist prior to template processing when doing autoula"; } + unless ($mactab) { $tmplerr ="mac table should always exist prior to template processing when doing autoula"; return;} my $ent = $mactab->getNodeAttribs($node,['mac'],prefetchcache=>1); - unless ($ent and $ent->{mac}) { die "missing mac data for $node"; } + unless ($ent and $ent->{mac}) { $tmplerr ="missing mac data for $node"; return;} my $suffix = $ent->{mac}; $suffix = lc($suffix); if ($::XCATSITEVALS{managedaddressmode} eq "autoula") {