diff --git a/perl-xCAT-2.0/xCAT/Utils.pm b/perl-xCAT-2.0/xCAT/Utils.pm index b5f5c789f..8bd965966 100644 --- a/perl-xCAT-2.0/xCAT/Utils.pm +++ b/perl-xCAT-2.0/xCAT/Utils.pm @@ -2269,12 +2269,11 @@ sub getSNList # reads all nodes from the service node table my @servicenodes; - my $servicenodetab = xCAT::Table->new('servicenode'); + my $servicenodetab = xCAT::Table->new('servicenode',-create=>1); unless ($servicenodetab) # no servicenode table { xCAT::MsgUtils->message('I', "Unable to open servicenode table.\n"); - return 0; - + return (); } my @nodes = $servicenodetab->getAllNodeAttribs([$service]); $servicenodetab->close;