jagub2 / mikrotik_bandwidth_monitor_exporter

Exporter for the Mikrotik Bandwidth Monitor
MIT License
8 stars 0 forks source link

Stack doesnt work as intended. #1

Closed denveronly closed 9 months ago

denveronly commented 9 months ago

Hey there, let me be first to write here.

So i got the stack running on Unraid server, its a bit complicated, cos docker compose is not the Unraid official support, but it started and i can login to all containers.

So what i have for now. 1) Bandwith monitor container ( see only logs: image

2) Prometheus container, no info, connection to Monitor is set i guess (it has domain name connection not set, but i guess localhost is fine)

image

3)Grafana, as there is no data from 2 of those, i would not see anything there, have zero dashboard

The thing is why monitor is not running as intended or there is some connection error between monitor and prometheus

upd:: Monitor gave error logs at last.

image

jagub2 commented 9 months ago

Hi, I can see that you have set bandwidth_monitor.env on your side. Looks like Docker can't connect to 192.168.1.1. Have you verified manually? I suspect this could be the case here. Personally I run it on Podman on OMV and I didn't need to configure any networking, it shouldn't require any additional network setup on Docker either.

denveronly commented 9 months ago

Hi, I can see that you have set bandwidth_monitor.env on your side. Looks like Docker can't connect to 192.168.1.1. Have you verified manually? I suspect this could be the case here. Personally I run it on Podman on OMV and I didn't need to configure any networking, it shouldn't require any additional network setup on Docker either.

I logged to Monitor console and made a ping to router and it passes through Tried 2 Mikrotik accounts with same result IMG_2881

jagub2 commented 9 months ago

Have you verified that you have connectivity to WebFig? If you use WebFig with HTTPS you need to change port and protocol. Despite that, there could be something with firewall here.

denveronly commented 9 months ago

Have you verified that you have connectivity to WebFig? If you use WebFig with HTTPS you need to change port and protocol. Despite that, there could be something with firewall here.

What version of RouterOS are you using? As im reading Mikrotik Rest API documents here: https://help.mikrotik.com/docs/display/ROS/REST+API

To start using REST API, the www-ssl or www (starting with RouterOS v7.9)

I tried to make a terminal command to Mikrotik API image

Maybe it is just not the version of my RouterOS?

UPDATED:

YEAP, Its the ROUTER OS version, it should be 7+ and i had v6, no rest api on v6. Upgraded and all got working. I guess this info should be in readme docs

jagub2 commented 9 months ago

I see. I’m running my router on version 7.11.2, I’ll add that to the readme.