diff --git a/perl-xCAT/xCAT/Utils.pm b/perl-xCAT/xCAT/Utils.pm index f9d661ca4..dfe60281b 100644 --- a/perl-xCAT/xCAT/Utils.pm +++ b/perl-xCAT/xCAT/Utils.pm @@ -3383,6 +3383,14 @@ sub get_ServiceNode chomp $nimprime; } + # $master and $nimprime is possible to be the same (MN) + # but $master is IP addr, $nimprime is short hostname + # this results in %snhash may have two keys duplicated. + # so use ip for nimprime. + + my $nimprimeip = xCAT::NetworkUtils->getipaddr($nimprime); + $nimprime = $nimprimeip; + $noderestab = xCAT::Table->new('noderes'); $nodetab = xCAT::Table->new('nodetype');