For the places that open site table to read attributes, change to call xCAT::Utils->get_site_attribute instead

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@12892 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
jjhua 2012-05-23 06:02:23 +00:00
parent 16be33214a
commit e819e0c23e

View File

@ -298,9 +298,11 @@ sub noderm
}
if (!$nodes) { $noderm_usage->(1); return; }
my $sitetab = xCAT::Table->new('site');
my $pdhcp = $sitetab->getAttribs({key=>'pruneservices'},['value']);
if ($pdhcp and $pdhcp->{value} and $pdhcp->{value} !~ /n(\z|o)/i) {
#my $sitetab = xCAT::Table->new('site');
#my $pdhcp = $sitetab->getAttribs({key=>'pruneservices'},['value']);
my @entries = xCAT::Utils->get_site_attribute("pruneservices");
my $t_entry = $entries[0];
if ( defined($t_entry) and $t_entry !~ /n(\z|o)/i) {
$requestcommand->({command=>['makedhcp'],node=>$nodes,arg=>['-d']});
}