GithubHelp home page GithubHelp logo

visteras / mikrotik-exporter Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nshttpd/mikrotik-exporter

0.0 1.0 1.0 3.58 MB

prometheus mikrotik device(s) exporter

License: BSD 3-Clause "New" or "Revised" License

Dockerfile 0.38% Makefile 2.11% Go 95.93% Shell 1.58%

mikrotik-exporter's Introduction

Docker Pulls

prometheus-mikrotik

tl;dr - prometheus exporter for mikrotik devices

This is still a work in progress .. consider master at the moment as a preview release.

Description

A Prometheus Exporter for Mikrotik devices. Can be configured to collect metrics from a single device or multiple devices. Single device monitoring can be configured all on the command line. Multiple devices require a configuration file. A user will be required that has read-only access to the device configuration via the API.

Currently the exporter collects metrics for interfaces and system resources. Others can be added as long as published via the API.

Mikrotik Config

Create a user on the device that has API and read-only access.

/user group add name=prometheus policy=api,read,winbox

Create the user to access the API via.

/user add name=prometheus group=prometheus password=changeme

Single Device

./mikrotik-exporter -address 10.10.0.1 -device my_router -password changeme -user prometheus

where address is the address of your router. device is the label name for the device in the metrics output to prometheus. The user and password are the ones you created for the exporter to use to access the API.

Config File

./mikrotik-exporter -config-file config.yml

where config-file is the path to a config file in YAML format.

example config
devices:
  - name: my_router
    address: 10.10.0.1
    user: prometheus
    password: changeme
  - name: my_second_router
    address: 10.10.0.2
    user: prometheus2
    password: password_to_second_router

features:
  bgp: true
  dhcp: true
  dhcpv6: true
  routes: true
  pools: true
  optics: true
example output
mikrotik_interface_tx_byte{address="10.10.0.1",interface="ether2",name="my_router"} 1.4189902583e+10
mikrotik_interface_tx_byte{address="10.10.0.1",interface="ether3",name="my_router"} 2.263768666e+09
mikrotik_interface_tx_byte{address="10.10.0.1",interface="ether4",name="my_router"} 1.6572299e+08
mikrotik_interface_tx_byte{address="10.10.0.1",interface="ether5",name="my_router"} 1.66711315e+08
mikrotik_interface_tx_byte{address="10.10.0.1",interface="ether6",name="my_router"} 1.0026481337e+10
mikrotik_interface_tx_byte{address="10.10.0.1",interface="ether7",name="my_router"} 3.18354425e+08
mikrotik_interface_tx_byte{address="10.10.0.1",interface="ether8",name="my_router"} 1.86405031e+08

mikrotik-exporter's People

Contributors

nshttpd avatar czerwonk avatar visteras avatar nacef-labidi avatar cliv avatar aeriff avatar arachnist avatar moonug avatar

Watchers

James Cloos avatar

Forkers

artmares

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.