From 8688e63f336f308c5af23c7004e765828fb73069 Mon Sep 17 00:00:00 2001 From: zhaoertao Date: Thu, 6 Dec 2012 06:09:26 +0000 Subject: [PATCH] fix bug 3194: power usage NOSUCHINSTANCE in 'rvitals cn all' firebird plus git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@14567 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/blade.pm | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/xCAT-server/lib/xcat/plugins/blade.pm b/xCAT-server/lib/xcat/plugins/blade.pm index bf7f91418..3594e5eca 100644 --- a/xCAT-server/lib/xcat/plugins/blade.pm +++ b/xCAT-server/lib/xcat/plugins/blade.pm @@ -883,12 +883,16 @@ sub vitals { if (grep /watt/,@vitems) { my $tmp_oid = "1.3.6.1.4.1.2.3.51.2.2.10.2.1.1.7."; - if ($slot < 8) { - $tmp_oid .= ($slot+16); - #$tmp = $session->get(["1.3.6.1.4.1.2.3.51.2.2.10.2.1.1.7.".($slot+16)]); + if ($mpatype eq 'cmm') { + $tmp_oid .= ($slot+24); } else { - $tmp_oid .= ($slot+9); - #$tmp = $session->get(["1.3.6.1.4.1.2.3.51.2.2.10.3.1.1.7.".($slot+9)]); + if ($slot < 8) { + $tmp_oid .= ($slot+16); + #$tmp = $session->get(["1.3.6.1.4.1.2.3.51.2.2.10.2.1.1.7.".($slot+16)]); + } else { + $tmp_oid = "1.3.6.1.4.1.2.3.51.2.2.10.3.1.1.7.".($slot+9); + #$tmp = $session->get(["1.3.6.1.4.1.2.3.51.2.2.10.3.1.1.7.".($slot+9)]); + } } $tmp = $session->get([$tmp_oid]); unless ($tmp =~ /Not Readable/) {