Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add --sum option to interface-usage mode #199

Open
wants to merge 97 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
97 commits
Select commit Hold shift + click to select a range
0ebc8df
Merge pull request #152 from cxcv/master
lausser Dec 2, 2017
d68b409
Merge pull request #155 from simonmeggle/master
lausser Dec 2, 2017
2e6909d
Merge branch 'master' of github.com:lausser/check_nwc_health
lausser Dec 13, 2017
2bc5c98
fix cisco wlc firmware bug
lausser Dec 13, 2017
1fa17c5
fix again a ucd pull-request
lausser Dec 13, 2017
2f2b976
update glplugin
lausser Dec 14, 2017
5f51acf
update glplugin
lausser Dec 14, 2017
989d249
update glplugin
lausser Dec 14, 2017
848f0af
checkpoint zeugs
lausser Dec 20, 2017
15c1494
duplex zeugs
lausser Dec 20, 2017
e2e4925
add interface-duplex
lausser Dec 21, 2017
2fbef1c
fix f5 versions
lausser Dec 27, 2017
6b14168
update CISCOENVMONMIB temperature
lausser Dec 27, 2017
35aa441
code improvements, hh3c fix
lausser Jan 5, 2018
e2492b4
update version
lausser Jan 5, 2018
49ee11f
update glplugin
lausser Jan 8, 2018
b7d2d6d
check the clock of checkpoint fw
lausser Jan 15, 2018
e9d6c8d
add ClockSubsystem
lausser Jan 16, 2018
a89d490
Removed static thresholds from Checkpoint temperature subsystem
Jan 23, 2018
89ccc33
Merge pull request #164 from simonmeggle/temp
lausser Jan 23, 2018
b1bd2f0
fix bluecoat asg detection
lausser Jan 23, 2018
ca9b019
changelog
lausser Jan 23, 2018
dd77053
update glplugn, add modes encode/decode, rfc3986
lausser Feb 7, 2018
5cb70a4
ignore free space of iso mounts in hostresource mib
lausser Feb 26, 2018
290d8dd
update glplugin
lausser Feb 26, 2018
c5c80cf
Merge branch 'master' of github.com:lausser/check_nwc_health
lausser Feb 26, 2018
4ba0029
glplugin update
lausser Mar 2, 2018
ded803e
improve f5, G&D
lausser Mar 7, 2018
ef8168c
fix a bug in cisco enhanced mempool mib and posixmem
lausser Mar 12, 2018
37b1b60
Eltex: workaround fan rpm in sensors table.
k0ste Mar 15, 2018
9921c04
bugfix in link-aggregation-availability
lausser Mar 31, 2018
507a654
bugfix in cisco global shared memory > 9.3.2
lausser Apr 30, 2018
cb42652
simplify the cisco memory exceptions
lausser May 5, 2018
2039845
update glplugin (get_snmp_table_objects waja fix)
lausser Jun 18, 2018
a3e66b3
add braunschweig banner. meet me at the monitoring-workshop in september
lausser Jul 4, 2018
4a02c3b
fix a bug in non-map FabOS memory. set thresholds to 100% for cisco a…
lausser Jul 5, 2018
0be3263
add mode interface-uptime
lausser Jul 13, 2018
6233073
Update README.md
lausser Jul 24, 2018
7374aec
update readme
lausser Jul 24, 2018
f06a6b6
update readme
lausser Jul 24, 2018
fd72568
Update AVM.pm
sni Jul 25, 2018
289f889
Merge pull request #175 from sni/patch-4
lausser Jul 25, 2018
7216216
add custom thresholds for cisco ccm
lausser Jul 26, 2018
f77ce45
Merge branch 'master' of github.com:lausser/check_nwc_health
lausser Jul 26, 2018
0c3d7ba
changelog, fritzbox 7490
lausser Jul 26, 2018
86fb1d5
add pf engine for juniper standby nodes
lausser Aug 1, 2018
0e44bff
bugfix in ios ha-status
lausser Aug 10, 2018
2388215
bugfix in interface-modes where --name3 found no match
lausser Aug 13, 2018
390aa5d
flatten indices in if-stack
lausser Aug 20, 2018
0af3495
update cisco vpn-status
lausser Sep 10, 2018
cb996e3
add servertype hostresource
lausser Sep 10, 2018
27f7df8
update stack-status#
lausser Sep 10, 2018
eb13c83
changelog
lausser Sep 10, 2018
5cc7112
Update GLPlugin
RikaDenia Sep 26, 2018
37832e7
Huawei: Remove WIP HUAWEI-ENTITY-EXTENT-MIB definition
RikaDenia Sep 26, 2018
d8485f3
Huawei: Fully re-enable CloudEngine
RikaDenia Sep 26, 2018
eaa6cb9
list-routes, start enhance
lausser Sep 26, 2018
ce26006
Merge pull request #170 from k0ste/newfeature
lausser Sep 26, 2018
c6a3625
Merge pull request #182 from RikaDenia/huawei-cloudengine
lausser Sep 26, 2018
f1216e0
Merge branch 'master' of github.com:lausser/check_nwc_health
lausser Sep 26, 2018
957972f
re-enable Huawei CloudEngine support
lausser Sep 26, 2018
b96ceca
update glplugin
lausser Sep 28, 2018
11ff0c9
Correct unbalanced parentheses
jvandermeulen Oct 9, 2018
2b660be
Merge pull request #186 from jvandermeulen/patch-1
lausser Oct 16, 2018
c9d2ed9
better fortigate detection, update glplugin
lausser Oct 16, 2018
b2b172e
Merge branch 'master' of github.com:lausser/check_nwc_health
lausser Oct 16, 2018
f052dd4
rm braunschweig banner
lausser Oct 16, 2018
68d9d5e
update glplugin (for go-worker)
lausser Oct 21, 2018
bb7025e
update glplugin (CISCO-STACKWISE-MIB)
lausser Oct 22, 2018
7df15ff
add modes ha-status/role for fortigate
lausser Oct 22, 2018
86712e6
fix ciscoipsecflow fail timestamps
lausser Dec 3, 2018
858dc1e
fix cswStackBandWidth problem
lausser Dec 3, 2018
4bb1f03
add servertype generic_ucd
lausser Dec 3, 2018
ead2749
add lmsensors to hostresources checks
lausser Dec 3, 2018
5904b2c
make ospf checks ipv6 ready
lausser Dec 3, 2018
d7d6ec4
forgot lmsensors dreckszeug
lausser Dec 3, 2018
9bbdafc
use propritary mibs for cisco bgp
lausser Dec 3, 2018
cee3925
detect more Huawei devices
lausser Dec 4, 2018
701a44b
fix fortigate sensors
lausser Dec 4, 2018
fe753c3
fix fortigate sensors2
lausser Dec 4, 2018
3a997ae
fix cisco bgp for routers which do not export the proptietary mib, bu…
lausser Dec 5, 2018
0615380
improve ucd memory
lausser Dec 12, 2018
775e328
improve paloalto uptime model string
lausser Dec 12, 2018
ea26887
fixup! fix cisco bgp for routers which do not export the proptietary …
lausser Dec 12, 2018
c023d19
start ha for cisco wlc
lausser Dec 12, 2018
7ecc16e
changlog
lausser Dec 12, 2018
012042d
finish ha-status for cisco wlc
lausser Dec 17, 2018
029a79e
add interface-security
lausser Jan 9, 2019
475921a
Update README.md
lausser Feb 17, 2019
bef1b8c
Add --sum option to `interface-usage` mode
Feb 18, 2019
5c6850d
Updated `GLPlugin` submodule
Feb 18, 2019
1a8fb43
add Draytek Vigor
lausser Feb 18, 2019
aec9f8c
Merge branch 'master' of github.com:lausser/check_nwc_health
lausser Feb 18, 2019
2f7d8ea
Add --sum option to interface-usage mode
volalla Feb 18, 2019
1a34562
Add --sum option to interface-usage mode
volalla Feb 18, 2019
ace8a05
Add --sum option to interface-usage mode
volalla Feb 18, 2019
7ddd8df
Merge branch 'master' of https://github.com/volalla/check_nwc_health
Feb 18, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
94 changes: 94 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,97 @@
* 2019-02-18 7.5
add Draytek Vigor
* 2019-01-09 7.4.3
add mode interface-security (cisco)
* 2018-12-17 7.4.2.1
finish ha-status for cisco wlc
* 2018-12-12 7.4.2
start ha for cisco wlc
improve paloalto uptime model string
improve ucd memory
* 2018-12-04 7.4.1.2
fix cisco bgp for routers which do not export the proptietary mib, but bgp4
* 2018-12-04 7.4.1.1
fix undefs for Huawei with older Mibs
fix fortigate sensors
* 2018-12-04 7.4.1
detect more Huawei devices
* 2018-12-03 7.4
use proprietary bgp mib for cisco (and add ipv6)
make ospd v6-ready
add servertpe generic_ucd
fix ciscoipsecflow fail timestamps
* 2018-10-22 7.3.1
add modes ha-status/role for fortigate
* 2018-10-22 7.3.0.5
update glplugin (CISCO-STACKWISE-MIB)
* 2018-10-21 7.3.0.4
update glplugin (for go-worker)
* 2018-10-17 7.3.0.3
update glplugin
better fortigate detection
* 2018-09-28 7.3.0.2
update glplugin
* 2018-09-25 7.3.0.1
re-enable Huawei CloudEngine support
* 2018-09-10 7.3
update stack-status
add servertype hostresource
update cisco vpn-status
* 2018-08-13 7.2.0.2
bugfix in interface-modes where --name3 found no match
* 2018-08-10 7.2.0.1
bugfix in ios ha-status, ignore cable "failover" description
* 2018-08-01 7.2
add packet forwarding engine metrics for juniper standby nodes
* 2018-07-26 7.1
add custom thresholds for cisco ccm
detect fritzbox 7490
* 2018-07-13 7.0.2
add interface-uptime
2018-07-05 7.0.1.6
fix a bug in non-map FabOS memory
set thresholds to 100% for cisco asa heapcache memory-usage
* 2018-06-18 7.0.1.5
update glplugin (get_snmp_table_objects waja fix)
* 2018-05-05 7.0.1.4
simplify the cisco memory exceptions
* 2018-04-29 7.0.1.3
bugfix in cisco global shared memory > 9.3.2
* 2018-03-31 7.0.1.2
fix a bug in link-aggregation-availability
* 2018-03-13 7.0.1.1
fix a bug in cisco enhanced mempool mib and posixmem (thx sabedevops)
* 2018-03-07 7.0.1
improve f5, add ha-role, check-config, count-connections
* 2018-03-01 7.0.0.7
update GLPlugin
* 2018-02-26 7.0.0.6
ignore free space of iso mounts in hostresource mib
* 2018-02-06 7.0.0.5
fix a bug in hostresourcesmib memory calc. (arista eos)
* 2018-02-08 7.0.0.5
update glplugn, add modes encode/decode, rfc3986
* 2018-01-23 7.0.0.4
merge pull request #164 (simonmeggle)
add bluecoat asg fix from Stefan Kublik
* 2018-01-12 7.0.0.3
check the clock of checkpoint fw
* 2018-01-11 7.0.0.2
fix a bug in checkpoint vpn-status
* 2018-01-08 7.0.0.1
update glplugin
* 2018-01-05 7.0
code improvements, fix hh3c entities
* 2017-12-27 6.4.4.1
fix f5 versions
* 2017-12-21 6.4.4
add interface-duplex
* 2017-12-15 6.4.3.3
fix a bug in vsx-firewall1-fork
* 2017-12-14 6.4.3.2
update glplugin
* 2017-12-14 6.4.3.1
update glplugin
* 2017-12-12 6.4.3
add checkpoint ha-status, fix checkpoint vpn-status
* 2017-11-27 6.4.2.3
Expand Down
2 changes: 1 addition & 1 deletion GLPlugin
34 changes: 19 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
Meet me at...
=============
<div><a href="https://monitors2019.consol.de/wiki/doku.php?id=workshop:2019:start" target="_blank"><img src="https://labs.consol.de/assets/images/muenchen-banner.png" alt="Monitoring-Workshop 2019" style="height: auto !important;width: auto !important;" ></a></div>

Description
============
The plugin check_nwc_health was developed with the aim of having a single tool for all aspects of monitoring of network components.

<a href="https://labs.consol.de/wiki/doku.php?id=workshop:2017:start"><img src="https://labs.consol.de/assets/images/duesseldorf-banner.gif"></a>
<div><a href="https://www.buymeacoffee.com/bsNED0Wct" target="_blank"><img src="https://www.buymeacoffee.com/assets/img/custom_images/black_img.png" alt="Buy Me A Coffee" style="height: auto !important;width: auto !important;" ></a></div>

Motivation
==========
Expand All @@ -24,23 +28,23 @@ Modi
| Mode | Function |
|-------------------------------|------------------------------------------------------------------------|
| hardware-health | Check the status of environmental equipment (fans, temperatures, power) |
| cpu-load | Check the CPU load of the device) |
| memory-usage | Check the memory usage of the device) |
| interface-usage | Check the utilization of interfaces) |
| cpu-load | Check the CPU load of the device |
| memory-usage | Check the memory usage of the device |
| interface-usage | Check the utilization of interfaces |
| interface-errors | Check the error-rate of interfaces |
| interface-discards | Check the discard-rate of interfaces) |
| interface-discards | Check the discard-rate of interfaces |
| interface-status | Check the status of interfaces (oper/admin) |
| interface-nat-count-sessions | Count the number of nat sessions) |
| interface-nat-count-sessions | Count the number of nat sessions |
| interface-nat-rejects | Count the number of nat sessions rejected due to lack of resources) |
| list-interfaces | Show the interfaces of the device and update the name cache) |
| list-interfaces-detail | Show the interfaces of the device and some details) |
| list-interfaces | Show the interfaces of the device and update the name cache |
| list-interfaces-detail | Show the interfaces of the device and some details |
| interface-availability | Show the availability (oper != up of interfaces) |
| link-aggregation-availability | Check the percentage of up interfaces in a link aggregation) |
| list-routes | Check the percentage of up interfaces in a link aggregation) |
| route-exists | Check if a route exists. --name is the dest, --name2 check also the next hop)) |
| count-routes | Count the routes. --name is the dest, --name2 is the hop)) |
| vpn-status | Check the status of vpns (up/down)) |
| create-shinken-service | Create a Shinken service definition) |
| link-aggregation-availability | Check the percentage of up interfaces in a link aggregation |
| list-routes | Check the percentage of up interfaces in a link aggregation |
| route-exists | Check if a route exists. (--name is the dest, --name2 check also the next hop) |
| count-routes | Count the routes. (--name is the dest, --name2 is the hop) |
| vpn-status | Check the status of vpns (up/down) |
| create-shinken-service | Create a Shinken service definition |
| hsrp-state | Check the state in a HSRP group) |
| hsrp-failover | Check if a HSRP group's nodes have changed their roles |
| list-hsrp-groups | Show the HSRP groups configured on this device |
Expand All @@ -60,7 +64,7 @@ Modi
| pool-complections | Check the members and connections of a load balancer pool |
| list-pools | List load balancer pools |
| check-licenses | Check the installed licences/keys |
| count-users | Count the | connected) users/sessions |
| count-users | Count the (connected) users/sessions |
| check-config | Check the status of configs (cisco, unsaved config changes) |
| check-connections | Check the quality of connections |
| count-connections | Check the number of connections (-client, -server is possible) |
Expand Down
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
dnl Process this file with autoconf to produce a configure script.
AC_REVISION ($Revision: 1.150 $)
AC_PREREQ(2.58)
AC_INIT(check_nwc_health,6.4.3)
AC_INIT(check_nwc_health,7.5)
AM_INIT_AUTOMAKE([1.9 tar-pax])
AM_MAINTAINER_MODE([disable])
AC_CANONICAL_HOST
Expand Down
6 changes: 3 additions & 3 deletions plugins-scripts/Classes/ALARMMIB/Component/AlarmSubsystem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
$self->get_snmp_tables('ALARM-MIB', [
#['models', 'alarmModelTable', 'Classes::ALARMMIB::Component::AlarmSubsystem::AlarmModel'],
#['variables', 'alarmActiveVariableTable', 'Classes::ALARMMIB::Component::AlarmSubsystem::AlarmVariable'],
Expand All @@ -26,7 +26,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::TableItem);
use strict;

sub finish {
my $self = shift;
my ($self) = @_;
$self->{ceAlarmTypes} = [];
if ($self->{alarmActiveVariableValueType} eq 'octetString') {
my $index = 0;
Expand All @@ -44,7 +44,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::TableItem);
use strict;

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info(sprintf "there are %d active alarms",
$self->{alarmActiveStatsActiveCurrent});
if ($self->{alarmActiveStatsActiveCurrent}) {
Expand Down
2 changes: 1 addition & 1 deletion plugins-scripts/Classes/AVOS.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ our @ISA = qw(Classes::Bluecoat);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
if ($self->mode =~ /device::hardware::health/) {
} elsif ($self->mode =~ /device::hardware::load/) {
$self->analyze_and_check_cpu_subsystem("Classes::AVOS::Component::CpuSubsystem");
Expand Down
4 changes: 2 additions & 2 deletions plugins-scripts/Classes/AVOS/Component/ConnectionSubsystem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
$self->get_snmp_objects('BLUECOAT-AV-MIB', (qw(
avSlowICAPConnections)));
}

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info(sprintf '%d slow ICAP connections',
$self->{avSlowICAPConnections});
$self->set_thresholds(warning => 100, critical => 100);
Expand Down
7 changes: 3 additions & 4 deletions plugins-scripts/Classes/AVOS/Component/CpuSubsystem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my %params = @_;
my ($self, %params) = @_;
# With AVOS version 5.5.4.1, 5.4.6.1 and 6.1.2.1, the SNMP MIB has been extended to support multiple CPU cores.
# The new OID is defined as a table 1.3.6.1.4.1.3417.2.11.2.4.1 in the BLUECOAT-SG-PROXY-MIB file with the following sub-OIDs.
# https://kb.bluecoat.com/index?page=content&id=FAQ1244&actp=search&viewlocale=en_US&searchid=1360452047002
Expand All @@ -23,7 +22,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::TableItem);
use strict;

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info(sprintf 'cpu %s usage is %.2f%%',
$self->{sgProxyCpuCoreIndex}, $self->{sgProxyCpuCoreBusyPerCent});
$self->set_thresholds(warning => 80, critical => 90);
Expand All @@ -41,7 +40,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::TableItem);
use strict;

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info(sprintf 'cpu %s usage is %.2f%%',
$self->{deviceUsageIndex}, $self->{deviceUsagePercent});
$self->set_thresholds(warning => $self->{deviceUsageHigh} - 10, critical => $self->{deviceUsageHigh});
Expand Down
4 changes: 2 additions & 2 deletions plugins-scripts/Classes/AVOS/Component/KeySubsystem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
$self->get_snmp_objects('BLUECOAT-AV-MIB', (qw(
avLicenseDaysRemaining avVendorName)));
}

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info(sprintf 'license %s expires in %d days',
$self->{avVendorName},
$self->{avLicenseDaysRemaining});
Expand Down
4 changes: 2 additions & 2 deletions plugins-scripts/Classes/AVOS/Component/MemSubsystem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ sub init {
# There's two separate OIDs to obtain memory pressure value for AVOSV4 and AVOSV5;
# AVOSV4: memPressureValue - OIDs: 1.3.6.1.4.1.3417.2.8.2.3 (systemResourceMIB)
# AVOSV5: sgProxyMemoryPressure - OIDs: 1.3.6.1.4.1.3417.2.11.2.3.4 (bluecoatSGProxyMIB)
my $self = shift;
my ($self) = @_;
$self->get_snmp_objects('BLUECOAT-SG-PROXY-MIB', (qw(
sgProxyMemPressure sgProxyMemAvailable sgProxyMemCacheUsage sgProxyMemSysUsage)));
if (! defined $self->{sgProxyMemPressure}) {
Expand All @@ -36,7 +36,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub check {
my $self = shift;
my ($self) = @_;
my $errorfound = 0;
$self->add_info('checking memory');
$self->add_info(sprintf 'memory usage is %.2f%%',
Expand Down
4 changes: 2 additions & 2 deletions plugins-scripts/Classes/AVOS/Component/SecuritySubsystem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
$self->get_snmp_objects('BLUECOAT-AV-MIB', (qw(
avVirusesDetected)));
}

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info(sprintf '%d viruses detected',
$self->{avVirusesDetected});
$self->set_thresholds(warning => 1500, critical => 1500);
Expand Down
2 changes: 1 addition & 1 deletion plugins-scripts/Classes/Alcatel.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ our @ISA = qw(Classes::Device);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
if ($self->{productname} =~ /AOS.*OAW/i) {
bless $self, 'Classes::Alcatel::OmniAccess';
$self->debug('using Classes::Alcatel::OmniAccess');
Expand Down
2 changes: 1 addition & 1 deletion plugins-scripts/Classes/Alcatel/OmniAccess.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ our @ISA = qw(Classes::Alcatel);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
if ($self->mode =~ /device::hardware::health/) {
$self->analyze_and_check_environmental_subsystem("Classes::Alcatel::OmniAccess::Component::EnvironmentalSubsystem");
# waere praktischer, aber in diesem fall muss alarmdreck ausgeputzt werden
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
$self->get_snmp_tables('WLSX-SYSTEMEXT-MIB', [
['memories', 'wlsxSysExtProcessorTable', 'Classes::Alcatel::OmniAccess::Component::CpuSubsystem::Cpu'],
]);
Expand All @@ -15,7 +15,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::TableItem);
use strict;

sub check {
my $self = shift;
my ($self) = @_;
my $label = sprintf '%s_usage', lc $self->{sysExtProcessorDescr};
$label =~ s/\s+/_/g;
$self->add_info(sprintf '%s usage is %.2f%%',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
$self->{fan_subsystem} =
Classes::Alcatel::OmniAccess::Component::FanSubsystem->new();
$self->get_snmp_objects('WLSX-SYSTEMEXT-MIB', qw(
Expand All @@ -15,7 +15,7 @@ sub init {
}

sub check {
my $self = shift;
my ($self) = @_;
$self->{fan_subsystem}->check();
$self->{powersupply_subsystem}->check();
$self->{storage_subsystem}->check();
Expand All @@ -32,7 +32,7 @@ sub check {
}

sub dump {
my $self = shift;
my ($self) = @_;
printf "[%s]\n%s\n", uc "wlsxSysExtInternalTemparature",
$self->{wlsxSysExtInternalTemparature};
$self->{fan_subsystem}->dump();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::Item);
use strict;

sub init {
my $self = shift;
my ($self) = @_;
$self->get_snmp_tables('WLSX-SYSTEMEXT-MIB', [
['fans', 'wlsxSysExtFanTable', 'Classes::Alcatel::OmniAccess::Component::FanSubsystem::Fan'],
]);
Expand All @@ -14,7 +14,7 @@ our @ISA = qw(Monitoring::GLPlugin::SNMP::TableItem);
use strict;

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info(sprintf 'fan %d status is %s',
$self->{flat_indices},
$self->{sysExtFanStatus});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use strict;
use constant { OK => 0, WARNING => 1, CRITICAL => 2, UNKNOWN => 3 };

sub init {
my $self = shift;
my ($self) = @_;
if ($self->mode =~ /device::ha::role/) {
$self->get_snmp_objects('WLSX-SYSTEMEXT-MIB', (qw(wlsxSysExtSwitchRole)));
if (! $self->opts->role()) {
Expand All @@ -14,7 +14,7 @@ sub init {
}

sub check {
my $self = shift;
my ($self) = @_;
$self->add_info('checking ha');
$self->add_info(sprintf 'ha role is %s', $self->{wlsxSysExtSwitchRole});
if ($self->{wlsxSysExtSwitchRole} ne $self->opts->role()) {
Expand Down
Loading