From 46d9b6345c4f13af5a7f4e7587c508d1dd9125ba Mon Sep 17 00:00:00 2001 From: zhaoertao Date: Thu, 6 Dec 2012 03:26:05 +0000 Subject: [PATCH] fix bug 3185: rvitals NODE lcds has no output on rhels6.2 and NGP Flex blades git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.7@14564 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/FSPvitals.pm | 2 +- xCAT-server/lib/xcat/plugins/blade.pm | 6 +++++- xCAT-server/lib/xcat/plugins/fsp.pm | 6 +++++- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/perl-xCAT/xCAT/FSPvitals.pm b/perl-xCAT/xCAT/FSPvitals.pm index 3506b1af4..1cb36bac6 100644 --- a/perl-xCAT/xCAT/FSPvitals.pm +++ b/perl-xCAT/xCAT/FSPvitals.pm @@ -429,7 +429,7 @@ sub lcds { } } - if( $type =~ /lpar/ ) { + if( $type =~ /lpar|blade/ ) { $action = "query_lcds"; } else { $action = "cec_query_lcds"; diff --git a/xCAT-server/lib/xcat/plugins/blade.pm b/xCAT-server/lib/xcat/plugins/blade.pm index 7adf9a734..4e1b6300e 100644 --- a/xCAT-server/lib/xcat/plugins/blade.pm +++ b/xCAT-server/lib/xcat/plugins/blade.pm @@ -3827,7 +3827,11 @@ sub filter_nodes{ push @{$mpnodes}, @ngpfsp; } } elsif ($cmd eq "rvitals") { - push @{$mpnodes}, @ngpfsp; + if (@args && (grep /^lcds$/,@args)) { + push @{$fspnodes}, @ngpfsp; + } else { + push @{$mpnodes}, @ngpfsp; + } } else { push @{$fspnodes}, @ngpfsp; } diff --git a/xCAT-server/lib/xcat/plugins/fsp.pm b/xCAT-server/lib/xcat/plugins/fsp.pm index 1d767c6e6..6272df794 100644 --- a/xCAT-server/lib/xcat/plugins/fsp.pm +++ b/xCAT-server/lib/xcat/plugins/fsp.pm @@ -176,7 +176,11 @@ sub filter_nodes{ push @{$mpnodes}, @ngpfsp; } } elsif ($cmd eq "rvitals") { - push @{$mpnodes},@ngpfsp; + if (@args && (grep /^lcds$/,@args)) { + push @{$fspnodes}, @ngpfsp; + } else { + push @{$mpnodes},@ngpfsp; + } } else { push @{$fspnodes}, @ngpfsp; }