/[smecontribs]/rpms/smeserver-zabbix-agent/contribs9/smeserver-zabbix-agent-0.1-megaraid_fix_raid10.patch
ViewVC logotype

Contents of /rpms/smeserver-zabbix-agent/contribs9/smeserver-zabbix-agent-0.1-megaraid_fix_raid10.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Tue Feb 9 23:18:26 2016 UTC (8 years, 9 months ago) by stephdl
Branch: MAIN
CVS Tags: smeserver-zabbix-agent-0_1-53_el6_sme, smeserver-zabbix-agent--, HEAD
* Wed Feb 10 stephane de Labrusse <stephdl@de-labrusse.fr> - 0.1-53.sme
- New rpm for sme9

1 --- smeserver-zabbix-agent-0.1/root/var/lib/zabbix/bin/megaraid-parser.pl.megaraid_fix_raid10 2009-07-08 14:24:25.000000000 +0200
2 +++ smeserver-zabbix-agent-0.1/root/var/lib/zabbix/bin/megaraid-parser.pl 2009-07-08 14:33:00.000000000 +0200
3 @@ -111,7 +111,7 @@
4 open (LDINFO, "$megacli -LdInfo -L$ld -a$adp |")
5 || die "error: Could not execute $megacli -LdInfo -L$ld -a$adp";
6
7 - my ($size, $unit, $raidlevel, $ldpdcount, $state);
8 + my ($size, $unit, $raidlevel, $ldpdcount, $spandepth, $state);
9 while (<LDINFO>) {
10 if ( m/Size:\s*((\d+)(MB|GB|TB))/ ) {
11 $size = $2;
12 @@ -126,8 +126,11 @@
13 if ( $state ne 'Optimal' ) {
14 $status = 'CRITICAL';
15 }
16 - } elsif ( m/Number Of Drives:\s*(\d+)/ ) {
17 - $ldpdcount = $1;
18 + } elsif ( m/Number Of Drives( per span)?:\s*(\d+)/ ) {
19 + $ldpdcount = $2;
20 + } elsif ( m/Span Depth:\s*(\d+)/ ) {
21 + $spandepth = $1;
22 + $ldpdcount = $ldpdcount * $spandepth;
23 } elsif ( m/RAID Level: Primary-(\d)/ ) {
24 $raidlevel = $1;
25 }

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed