From 012d3cedc829bf1ff09d4c4ac1dd05d9a5adb71e Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Thu, 22 May 2008 14:12:05 +0000 Subject: [PATCH] -Provide better error message when nodetype.os is not set for nodeset install -Correct nodetype failure description when nodetype.arch is not set git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@1478 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server-2.0/lib/xcat/plugins/anaconda.pm | 12 +++++++++++- xCAT-server-2.0/sbin/xcatd | 4 +++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/xCAT-server-2.0/lib/xcat/plugins/anaconda.pm b/xCAT-server-2.0/lib/xcat/plugins/anaconda.pm index be539c035..8ed0e0f97 100644 --- a/xCAT-server-2.0/lib/xcat/plugins/anaconda.pm +++ b/xCAT-server-2.0/lib/xcat/plugins/anaconda.pm @@ -363,11 +363,21 @@ sub mkinstall { my $osinst; my $ent = $ostab->getNodeAttribs($node, ['profile', 'os', 'arch']); + my @missingparms; + unless ($ent->{os}) { + push @missingparms,"nodetype.os"; + } + unless ($ent->{arch}) { + push @missingparms,"nodetype.arch"; + } + unless ($ent->{profile}) { + push @missingparms,"nodetype.profile"; + } unless ($ent->{os} and $ent->{arch} and $ent->{profile}) { $callback->( { - error => ["No profile defined in nodetype for $node"], + error => ["Missing ".join(',',@missingparms)." for $node"], errorcode => [1] } ); diff --git a/xCAT-server-2.0/sbin/xcatd b/xCAT-server-2.0/sbin/xcatd index df3429fc6..70ce21af3 100755 --- a/xCAT-server-2.0/sbin/xcatd +++ b/xCAT-server-2.0/sbin/xcatd @@ -667,7 +667,9 @@ sub plugin_command { if ($sock) { print $sock XMLout({node=>[{name=>[$_],data=>["Unable to identify plugin for this command, check relevant tables: $queuelist"],errorcode=>[1]}]},NoAttr=>1,RootName=>'xcatresponse'); } else { - $callback->({node=>[{name=>[$_],data=>['Unable to identify plugin for this command, check relevant tables'],errorcode=>[1]}]}); + my $tabdesc = $queuelist; + $tabdesc =~ s/=.*$//; + $callback->({node=>[{name=>[$_],data=>['Unable to identify plugin for this command, check relevant tables: '.$tabdesc],errorcode=>[1]}]}); } } }