diff --git a/centreon-plugins/network/f5/bigip/snmp/mode/poolstatus.pm b/centreon-plugins/network/f5/bigip/snmp/mode/poolstatus.pm index a1449f0a6..fb8480a66 100644 --- a/centreon-plugins/network/f5/bigip/snmp/mode/poolstatus.pm +++ b/centreon-plugins/network/f5/bigip/snmp/mode/poolstatus.pm @@ -181,8 +181,7 @@ sub manage_selection { my $snmp_result = $options{snmp}->get_multiple_table(oids => [ { oid => $mapping->{new}->{AvailState}->{oid} }, { oid => $mapping->{old}->{AvailState}->{oid} }, - ], - , nothing_quit => 1); + ], nothing_quit => 1); my ($branch_name, $map) = ($mapping->{new}->{AvailState}->{oid}, 'new'); if (!defined($snmp_result->{$mapping->{new}->{AvailState}->{oid}}) || scalar(keys %{$snmp_result->{$mapping->{new}->{AvailState}->{oid}}}) == 0) { @@ -197,8 +196,9 @@ sub manage_selection { my $result = $options{snmp}->map_instance(mapping => $mapping->{$map}, results => $snmp_result->{$branch_name}, instance => $instance); $result->{Name} = ''; foreach (split /\./, $instance) { - $result->{Name} .= chr if ($_ >= 32 && $_ <= 126); + $result->{Name} .= chr if ($_ >= 32 && $_ <= 126); } + $result->{Name} =~ s/^.//; if (defined($self->{option_results}->{filter_name}) && $self->{option_results}->{filter_name} ne '' && $result->{Name} !~ /$self->{option_results}->{filter_name}/) { diff --git a/centreon-plugins/network/f5/bigip/snmp/mode/virtualserverstatus.pm b/centreon-plugins/network/f5/bigip/snmp/mode/virtualserverstatus.pm index b2ab6d60c..82e2a52c7 100644 --- a/centreon-plugins/network/f5/bigip/snmp/mode/virtualserverstatus.pm +++ b/centreon-plugins/network/f5/bigip/snmp/mode/virtualserverstatus.pm @@ -171,8 +171,7 @@ sub manage_selection { $self->{results} = $options{snmp}->get_multiple_table(oids => [ { oid => $oid_ltmVirtualServEntry, start => $mapping->{old}->{AvailState}->{oid} }, { oid => $oid_ltmVsStatusEntry, start => $mapping->{new}->{AvailState}->{oid} }, - ], - , nothing_quit => 1); + ], nothing_quit => 1); my ($branch, $map) = ($oid_ltmVsStatusEntry, 'new'); if (!defined($self->{results}->{$oid_ltmVsStatusEntry}) || scalar(keys %{$self->{results}->{$oid_ltmVsStatusEntry}}) == 0) { @@ -187,8 +186,10 @@ sub manage_selection { $result->{Name} = ''; foreach (split /\./, $instance) { - $result->{Name} .= chr if ($_ >= 32 && $_ <= 126); + $result->{Name} .= chr if ($_ >= 32 && $_ <= 126); } + $result->{Name} =~ s/^.//; + if (defined($self->{option_results}->{filter_name}) && $self->{option_results}->{filter_name} ne '' && $result->{Name} !~ /$self->{option_results}->{filter_name}/) { $self->{output}->output_add(long_msg => "Skipping '" . $result->{Name} . "': no matching filter name.");