bluecmd / fortigate_exporter

Prometheus exporter for Fortigate firewalls
GNU General Public License v3.0
232 stars 72 forks source link

fix: update schema and path for managed switch and call `/port-stats` endpoint to get additional metrics #290

Open hexionas opened 4 months ago

hexionas commented 4 months ago

Created a patch file with these changes before building the binary and running it in Docker on our own setup. This is needed after v7.2.

We were able to see metrics from our fortigates:

image

@bluecmd @secustor

hexionas commented 4 months ago

Actually, we have just found out that a lot of the expected port related metrics are missing. After some further investigation it seems that the PortStats is now derived from hitting the api/v2/monitor/switch-controller/managed-switch/port-stats endpoint as well as the api/v2/monitor/switch-controller/managed-switch/status endpoint and combining the results. I will take a look when I get a chance to get this to work and make the necessary changes.