From db3ccd170f2bc162b9f0e8b8961cda4ef32d194a Mon Sep 17 00:00:00 2001 From: jjhua Date: Tue, 22 May 2012 03:08:16 +0000 Subject: [PATCH] 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@12856 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/conserver.pm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/xCAT-server/lib/xcat/plugins/conserver.pm b/xCAT-server/lib/xcat/plugins/conserver.pm index 7626d0f54..25ed68403 100644 --- a/xCAT-server/lib/xcat/plugins/conserver.pm +++ b/xCAT-server/lib/xcat/plugins/conserver.pm @@ -258,9 +258,11 @@ sub docfheaders { #-- then start all consoles on demand #-- this helps eliminate many ssh connections to blade AMM #-- which seems to kill AMMs occasionally - my $sitetab = xCAT::Table->new('site'); - my $vcon = $sitetab->getAttribs({key => "consoleondemand"}, 'value'); - if ($vcon and $vcon->{"value"} and $vcon->{"value"} eq "yes" ) { + #my $sitetab = xCAT::Table->new('site'); + #my $vcon = $sitetab->getAttribs({key => "consoleondemand"}, 'value'); + my @entries = xCAT::Utils->get_site_attribute("consoleondemand"); + my $site_entry = $entries[0]; + if ( defined($site_entry) and $site_entry eq "yes" ) { push @newheaders," options ondemand;\n"; }