From cd406905a8177fee4b2e06ef71887dc44bf13d5e Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Tue, 18 Jun 2013 17:07:34 +0000 Subject: [PATCH] Change flexdiscover to separate imm and cmm search git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.8@16668 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/lsslp.pm | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/xCAT-server/lib/xcat/plugins/lsslp.pm b/xCAT-server/lib/xcat/plugins/lsslp.pm index 02ac4d566..f6feef573 100644 --- a/xCAT-server/lib/xcat/plugins/lsslp.pm +++ b/xCAT-server/lib/xcat/plugins/lsslp.pm @@ -539,9 +539,16 @@ sub invoke_dodiscover { my %arg; - if ($globalopt{flexdiscover}) { - $arg{SrvTypes} = [ qw/service:management-hardware.IBM:chassis-management-module service:management-hardware.IBM:management-module service:management-hardware.IBM:integrated-management-module2/ ]; + if ($globalopt{flexdiscover}) { #we do two SLP passes, one to hopefully catch the less numerous management modules reliably, a separate one to best-effort catch imms + $arg{SrvTypes} = [ qw/service:management-hardware.IBM:chassis-management-module service:management-hardware.IBM:management-module/ ]; my ($searchmacsref,$sendcount,$rsp) = xCAT::SLP::dodiscover(SrvTypes=>$arg{SrvTypes},Callback=>\&bt_handle_new_slp_entity); + $arg{SrvTypes} = [ qw/service:management-hardware.IBM:integrated-management-module2/ ]; + my ($newsearchmacsref,$newsendcount,$newrsp) = xCAT::SLP::dodiscover(SrvTypes=>$arg{SrvTypes},Callback=>\&bt_handle_new_slp_entity); + foreach (keys %$newsearchmacsref) { + $searchmacsref{$_}=$newsearchmacsref->{$_}; + } + $sendcount += $newsendcount; + $rsp+=$newrsp; return ($searchmacsref,$sendcount,$rsp); } $arg{SrvTypes} = $services;