From eff23d4a3e0c13ee1016c26f9cc529b3af31be75 Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Fri, 11 May 2012 15:31:09 +0000 Subject: [PATCH] Have SvrUtils potentiall prefetchcache git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.7@12638 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/perl/xCAT/SvrUtils.pm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/xCAT-server/lib/perl/xCAT/SvrUtils.pm b/xCAT-server/lib/perl/xCAT/SvrUtils.pm index 2cba744ac..5476a691e 100644 --- a/xCAT-server/lib/perl/xCAT/SvrUtils.pm +++ b/xCAT-server/lib/perl/xCAT/SvrUtils.pm @@ -152,13 +152,17 @@ sub get_nodeset_state { $node = shift; } + my %options=@_; + my %gnopts; + if ($options{prefetchcache}) { $gnopts{prefetchcache}=1; } + my $state = "undefined"; my $tftpdir; #get boot type (pxe, yaboot or aixinstall) for the node my $noderestab = xCAT::Table->new('noderes', -create => 0); - my $ent = $noderestab->getNodeAttribs($node, [qw(netboot tftpdir)]); + my $ent = $noderestab->getNodeAttribs($node, [qw(netboot tftpdir)],%gnopts); #get tftpdir from the noderes table, if not defined get it from site talbe if ($ent && $ent->{tftpdir}) { @@ -212,7 +216,7 @@ sub get_nodeset_state if ($state eq "undefined") { my $chaintab = xCAT::Table->new('chain'); - my $stref = $chaintab->getNodeAttribs($node, ['currstate']); + my $stref = $chaintab->getNodeAttribs($node, ['currstate'],%gnopts); if ($stref and $stref->{currstate}) { $state = $stref->{currstate}; } }