From 182de6c93b140b5331f40f1533b4d6f32265b01a Mon Sep 17 00:00:00 2001 From: yinle Date: Mon, 27 Aug 2012 06:11:39 +0000 Subject: [PATCH] performance improving of discovering hmc. git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@13614 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/lsslp.pm | 30 ++++++++++++++------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/xCAT-server/lib/xcat/plugins/lsslp.pm b/xCAT-server/lib/xcat/plugins/lsslp.pm index 2163c96f6..dbd493d9f 100644 --- a/xCAT-server/lib/xcat/plugins/lsslp.pm +++ b/xCAT-server/lib/xcat/plugins/lsslp.pm @@ -593,26 +593,28 @@ sub format_output { ########################################### # Read table to get exists data ########################################### - my $errcode = read_from_table(); - if ($errcode) { - send_msg( $request, 0, "Can't open $errcode table" ); - return; - } + unless($globalopt{service} =~ /hardware-management-console/) { + my $errcode = read_from_table(); + if ($errcode) { + send_msg( $request, 0, "Can't open $errcode table" ); + return; + } + } ########################################### # Parse responses and add to hash ########################################### my $outhash = parse_responses( $request, \$length, $searchmacsref ); #hmc bug efix - my $newouthash; - if ($globalopt{service} =~ /hardware-management-console/) { - for my $en ( keys %$outhash ) { - if (${$outhash->{$en}}{type} eq 'hmc') { - $newouthash->{$en} = $outhash->{$en}; - } - } - $outhash = $newouthash; - } + #my $newouthash; + #if ($globalopt{service} =~ /hardware-management-console/) { + # for my $en ( keys %$outhash ) { + # if (${$outhash->{$en}}{type} eq 'hmc') { + # $newouthash->{$en} = $outhash->{$en}; + # } + # } + # $outhash = $newouthash; + #} ########################################### # filter the result in the same vlan