SKFREE

Mikrotik™ Podpora - Port speed cez SNMP

neos - 08.06.2016 - 18:39
Post subject: Port speed cez SNMP
Da sa cez SNMP vycitat aktualna zlinkovana rychlost ethernet portu na mikrotiku? Potrebujem to dostat do Nagiosu alebo Zabbixu, aby som vedel, kedy zblbne port.

To iste potrebujem tahat aj z UBNT. Riesil to niekto?
midnight_man - 09.06.2016 - 17:46
Post subject:
samozrejme...chce to vediet snmp oid alebo mat spravny template.
backslash_ - 10.06.2016 - 08:25
Post subject:
Dva dobre mierene dotazy do Googla by ti to vyriesili rychlejsie ako pytat sa tu. Aktualnu linkovu rychlost mas v IF-MIB v tabulke ifTable, stlpec ifSpeed, cize IF-MIB::ifSpeed.1 je linkova rychlost v bitoch na interface s indexom 1. Ak by si chcel numericku hodnotu OID tak je to .1.3.6.1.2.1.2.2.1.5.X kde X je ifIndex tvojho interface.
midnight_man - 10.06.2016 - 21:03
Post subject:
no jak pekne ti to tu kolega vysvetlil Very Happy az sa cudujem ze sa mu to chcelo hladat
neos - 15.06.2016 - 09:42
Post subject:
Dakujem, pomohlo. Aspon si obohatil google od dalsie relevantne klucove slova Smile

Spravil som si Nagios check, ktory upozorni na zle zlinkovany port na mikrotiku alebo UBNT:

/etc/nagios3/commands.cfg:
Code: ›
### Interface speed SNMP
define command {
        command_name                    check_mk_portspeed
        command_line                    $USER1$/check_snmp -H $HOSTADDRESS$ -o 1.3.6.1.2.1.2.2.1.5.$ARG2$ -C $ARG1$ -s $ARG3$ -P $ARG4$ -l SPEED: -u bps
        register                        1
}


/etc/nagios3/conf.d/services_nagios2.cfg:
Code: ›

### Mikrotik/UBNT port speed check ###
# PARAMETRE: community,port index,kontrolovany speed v bps,SNMP verzia

define service {
        host_name                       ROUTER1
        service_description             MikroTik ETH speed R1 uplink
        use                             generic-service
        check_command                   check_mk_portspeed!haluska456!1!100000000!2c
        register                        1
        notification_options            c,r
        notification_interval           0
        contact_groups                  notif_sms_mail
}


PS: UBNT podporuje len SNMP verziu 1.
All times are GMT
Powered by PNphpBB2 © 2003-2005 The PNphpBB Group
Credits