Mikrotik Monitoring with Zabbix

Hi there,

I have implemented the code in Python 2.7.13 which fetch the BGP Counters and RADIUS Client Counters via API.
The main reason is why this code was born is that Mikrotik’s vendor does not hurry with implementing SNMP OIDs for the certain interesting counters :frowning:.

SSL and plain API connections are supported. The code is available on Github or Bitbucket

BGP Monitoring

The next BGP counters are being monitored:

  • Remote AS
  • Prefix Count
  • Administrative status of the peer: enabled/disabled
  • Peer connection uptime
  • Peer connection state
  • Comment :slight_smile:
  • Updates Sent
  • Updates Received
  • Withdrawn Sent
  • Withdrawn Received

The next triggers are defined:

  • (Info) BGP Remote AS Number had been changed
  • (High) Peer is down
  • (Warning) Peer lost 10% of its prefixes
  • (Average) Peer lost 20% of its prefixes
  • (High) Peer lost 30% of its prefixes
  • (Warning) BGP Session was restarted
  • (Disaster) No prefixes had been received

The next charts had been added:

  • Accepted Prefixes
  • Established Time
  • BGP Updates per sec
  • BGP Withdraws per sec

Radius Client Counters Monitoring
The scripts can fetch RADIUS Client counters. Outgoing and Incoming (CoA) counters are supported.

The next counters are in mind:

  • Incoming - Acknowleged requests (CoA-ACK)
  • Incoming - Bad Requests
  • Incoming - Rejected Requests (CoA-NACK)
  • Incoming - Requests
  • Outgoing - Accepted Requests
  • Outgoing - Bad Replies
  • Outgoing - Pending Requests
  • Outgoing - Rejected Requests
  • Outgoing - Resends
  • Outgoing - Timeouts

The next Charts are available:

  • Outgoing - Requests
  • Outgoing - Requests per type
  • Outgoing - Pending Requests
  • Incoming - Requests
  • Incoming - Requests per type

You are welcome to fork, ideas and pull requests.

Added IRQ monitoring and charts yesterday.

Nice project! I’ll starting to test soon :smiley:

  • Fixed a bug with BGP disabled peer monitoring
  • Added a module which shows the counters for bytes/packets for Firewall rules (rules must have a comment which should start with ZBX word).

That is why I uses script to send important data in my Splunk for Mikrotik.
http://forum.mikrotik.com/t/tool-using-splunk-to-analyse-mikrotik-logs-3-3-graphing-everything/121810/1
Se script section 2f

It may be possible to use Splunkt to graphs BGP information as well.