Check that SNMP in/outoctet modules respond.

This commit is contained in:
Ramon Novoa 2018-10-29 12:09:35 +01:00
parent 1973a5fe54
commit 20d6c30416

View File

@ -587,7 +587,7 @@ sub PandoraFMS::Recon::Base::create_agent($$) {
} }
} }
# ifInOctets # ifInOctets
else { elsif (defined($self->snmp_get_value($device, "$PandoraFMS::Recon::Base::IFINOCTECTS.$if_index"))) {
$module_id = get_agent_module_id($self->{'dbh'}, "${if_name}_ifInOctets", $agent_id); $module_id = get_agent_module_id($self->{'dbh'}, "${if_name}_ifInOctets", $agent_id);
if ($module_id <= 0) { if ($module_id <= 0) {
my %module = ('id_tipo_modulo' => 16, my %module = ('id_tipo_modulo' => 16,
@ -660,7 +660,7 @@ sub PandoraFMS::Recon::Base::create_agent($$) {
} }
} }
# ifOutOctets # ifOutOctets
else { elsif (defined($self->snmp_get_value($device, "$PandoraFMS::Recon::Base::IFOUTOCTECTS.$if_index"))) {
$module_id = get_agent_module_id($self->{'dbh'}, "${if_name}_ifOutOctets", $agent_id); $module_id = get_agent_module_id($self->{'dbh'}, "${if_name}_ifOutOctets", $agent_id);
if ($module_id <= 0) { if ($module_id <= 0) {
my %module = ('id_tipo_modulo' => 16, my %module = ('id_tipo_modulo' => 16,