Skip to main content

Hi all,
I'd like to check the speed of a switch port and put thresholds (warning at 100Mbps and critical at 10Mbps)
Here's the command line :
Port 1 :
perl centreon_plugins.pl --plugin=network::cisco::standard::snmp::plugin --mode=interfaces --add-speed --interface=10104 --hostname=10.100.0.11 --warning-speed=100000 --critical-speed=10000
the ouput :
CRITICAL: Interface 'Gi1/0/4' Speed : 1.00Gb/s | 'speed'=1000000000b/s;0:100000;0:10000;0;
Port 2 :
perl centreon_plugins.pl --plugin=network::cisco::standard::snmp::plugin --mode=interfaces --add-speed --interface=10119 --hostname=10.100.0.11 --warning-speed=100000 --critical-speed=10000
the ouput :
CRITICAL: Interface 'Gi1/0/19' Speed : 100.00Mb/s | 'speed'=100000000b/s;0:100000;0:10000;0;

Not sure I understood the way it should work
Do you have an example that works ?

Many thanks for your answer

 

Let us look into the result:

CRITICAL: Interface 'Gi1/0/19' Speed : 100.00Mb/s | 'speed'=100000000b/s;0:100000;0:10000;0;

 

You might be looking for different thresholds, try with:

perl centreon_plugins.pl --plugin=network::cisco::standard::snmp::plugin --mode=interfaces --add-speed --interface=10119 --hostname=10.100.0.11 --warning-speed=100000: --critical-speed=10000:

Note the “:”

https://docs.centreon.com/docs/monitoring/metrics/#syntax-of-metric-thresholds

 


Hi

many thanks for your answer
After few tests, it works as I expected :

perl centreon_plugins.pl --plugin=network::cisco::standard::snmp::plugin --mode=interfaces --add-speed --interface=10122 --hostname=10.100.0.11 --critical-speed=100000000: --warning-speed=1000000000:

The output :
CRITICAL: Interface 'Gi1/0/22' Speed : 10.00Mb/s | 'speed'=10000000b/s;1000000000:;100000000:;0;

 

That’s great !


Reply