From 4b88405719ce9bd2c0352571257bf30c187f01e7 Mon Sep 17 00:00:00 2001 From: jbjohnso Date: Sun, 5 Oct 2008 19:47:04 +0000 Subject: [PATCH] -Edit script to also attempt isol, to allow SOL for x336/x346 in conjunction with ipmitool 1.8.10 git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@2284 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/share/xcat/cons/ipmi | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/xCAT-server/share/xcat/cons/ipmi b/xCAT-server/share/xcat/cons/ipmi index adeadae45..ebbc3691a 100755 --- a/xCAT-server/share/xcat/cons/ipmi +++ b/xCAT-server/share/xcat/cons/ipmi @@ -57,13 +57,23 @@ until ($username and $password and $bmc) { #} #xCAT::Utils::close_all_dbhs; #my $isintel = system "ipmitool -I lanplus -U $username -P $password -H $bmc chassis status > /dev/null 2>&1"; -my $isintel = system "ipmitool -I lan -U $username -P $password -H $bmc mc info| grep 'Manufacturer ID : 343' > /dev/null 2>&1"; -$isintel = not $isintel; +my $isintel=0; +my @mcinfo=`ipmitool -I lan -U $username -P $password -H $bmc mc info`;#| grep 'Manufacturer ID : 343' > /dev/null 2>&1"; +my $solcom="sol"; +my $iface="lanplus"; +if (grep /IPMI Version : 1.5/,@mcinfo) { + $solcom="isol"; + $iface="lan"; +} elsif (grep /Manufacturer ID : 343/,@mcinfo) { + $isintel=1; +} my $inteloption=""; if ($isintel) { $inteloption=" -o intelplus"; } -system "ipmitool -I lanplus$inteloption -U $username -P $password -H $bmc sol deactivate"; #Stop any active session -exec "ipmitool -I lanplus$inteloption -U $username -P $password -H $bmc sol activate"; +if ($iface eq "lanplus") { + system "ipmitool -I lanplus $inteloption -U $username -P $password -H $bmc $solcom deactivate"; #Stop any active session +} +exec "ipmitool -I $iface $inteloption -U $username -P $password -H $bmc $solcom activate";