ndecker / fritzbox_exporter Goto Github PK
View Code? Open in Web Editor NEWFritz!Box Upnp statistics exporter for prometheus
License: Apache License 2.0
Fritz!Box Upnp statistics exporter for prometheus
License: Apache License 2.0
followed instructions: https://github.com/ndecker/fritzbox_exporter#building
but received error before using
△ github.com/ndecker/fritzbox_exporter @ raspberrypi ./fritzbox_exporter -h master :: 784d :: ⬢
Usage of ./fritzbox_exporter:
-gateway-address string
The hostname or IP of the FRITZ!Box (default "fritz.box")
-gateway-port int
The port of the FRITZ!Box UPnP service (default 49000)
-listen-address string
The address to listen on for HTTP requests. (default ":9133")
-test
print all available metrics to stdout
△ github.com/ndecker/fritzbox_exporter @ raspberrypi ./fritzbox_exporter -test master :: 784d :: ⬢
panic: EOF
goroutine 1 [running]:
panic(0x2d94e0, 0x10726058)
/usr/lib/go-1.7/src/runtime/panic.go:500 +0x33c
main.test()
/root/go/src/github.com/ndecker/fritzbox_exporter/main.go:285 +0xa8
main.main()
/root/go/src/github.com/ndecker/fritzbox_exporter/main.go:312 +0x2c
Would be nice to handle this without aborting the program. Happened after a reboot with the systemd service starting before the network was up. DNS resolution worked because it was done on the local box.
panic: Get http://fritz.box:49000/igddesc.xml: dial tcp 192.168.0.1:49000: connect: network is unreachable
goroutine 1 [running]:
panic(0x852280, 0xc8201108a0)
/usr/lib/go/src/runtime/panic.go:481 +0x3e6
main.main()
.../src/src/github.com/ndecker/fritzbox_exporter/main.go:250 +0xbf
Thanks for creating this by the way, it's a nice source of data for my Grafana dashboard (using it for used bandwidth, available DSL bandwidth & uptime)
Hello,
Is it possible to remote monitore a fritzbox with this exporter? Auf so, how can it be done using only the fritz box at the other network, no additional device.
Some Upnp Port opening on the fritzbox?
Hope to get some help thanks great work
any plans for implement tr64 http://fritz.box:49000/tr64desc.xml
i want it for
NewUpstreamMaxRate
NewDownstreamMaxRate
I have a FritzBox 7560 with firmware version 06.92
, works without limitations.
I am using the latest published docker version and a 6660 (cable).
From the logs, it seems that the connection is properly established but it breaks right after.
LOG LEVEL READ FROM CONFIG
2021-09-02 20:11:10,168 INFO fritzexporter | registering 192.168.178.1 to collector
2021-09-02 20:11:10,984 INFO fritzexporter.fritzdevice | Connection to 192.168.178.1 successful, reading capabilities
2021-09-02 20:11:10,984 DEBUG fritzexporter.fritzcapability | Capability DeviceInfo set to {self.present} on device {device.host}
Traceback (most recent call last):
File "/usr/local/lib/python3.9/runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/local/lib/python3.9/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/app/fritzexporter/__main__.py", line 74, in <module>
main()
File "/app/fritzexporter/__main__.py", line 58, in main
FritzDevice(dev['hostname'], dev['username'], dev['password'], dev['name']))
File "/app/fritzexporter/fritzdevice.py", line 35, in __init__
self.capabilities = FritzCapabilities(self)
File "/app/fritzexporter/fritzcapabilities.py", line 75, in __init__
self.checkPresent(device)
File "/app/fritzexporter/fritzcapabilities.py", line 99, in checkPresent
self.capabilities[c].checkCapability(device)
File "/app/fritzexporter/fritzcapabilities.py", line 46, in checkCapability
device.fc.call_action(svc, action)
File "/usr/local/lib/python3.9/site-packages/fritzconnection/core/fritzconnection.py", line 227, in call_action
return self.soaper.execute(service, action_name, arguments)
File "/usr/local/lib/python3.9/site-packages/fritzconnection/core/soaper.py", line 238, in execute
return handle_response(response)
File "/usr/local/lib/python3.9/site-packages/fritzconnection/core/soaper.py", line 222, in handle_response
raise_fritzconnection_error(response)
File "/usr/local/lib/python3.9/site-packages/fritzconnection/core/soaper.py", line 147, in raise_fritzconnection_error
raise exception(message)
fritzconnection.core.exceptions.FritzSecurityError: UPnPError:
errorCode: 606
errorDescription: Action Not Authorized
Hello everyone,
reading through the state of this repository, it seems like the author has moved on. Which is completely fine! I have much appreciation and would like to thank @ndecker a lot for the awesome project he has created!
I have not really found that many alternatives to this project. There are some projects like https://github.com/wbwue/FritzExporter by @wbwue or https://github.com/pdreker/fritzbox_exporter by @pdreker , which are worth exploring and contacting.
My go experience is only average, but I have several ideas on how to push this project forward. I would like to start by creating a fork and eventually finding a few co-maintainer. They should be OK with the PR-based workflow and have at least some existing FOSS-Contribution history, then I am happy to add them as maintainer to the fork.
The goal would be to get things into shape with fixes tests, moving from vendoring to go modules.
Then collect issues and existing PRs and throw everything into the coming Hacktoberfest and hack on it.
With this issue I want to call out of anyone interested in helping or maybe there is already such an ongoing effort I have overlooked!
Happy to hear from anyone.
I'll do the next steps hopefully by the weekend.
Maybe it is due to my lack of understanding of the GO language, but downloading and trying to use your release packe does not seem possible.
package .
imports ./vendor/github.com/prometheus/client_golang/prometheus: must be imported as github.com/prometheus/client_golang/prometheus
If I get all of that right it means I have to install directly from GitHub. So what is the purpose of the release package?
I prefer release packages as they ensure if I have them stored locally I can re-use them 10 years from now, weather you deleted your project or not.
Please advise if this is just my lack of understanding.
Hi,
found this project today and noticed that there are some interesting PRs pending and some other forks ongoing...
Hence the question if the PRs will be merged or if this fork is sort of abandoned?
TIA
/tklein
Hi,
go get github.com/ndecker/fritzbox_exporter
works under
but not with
Error message in both cases:
go/pkg/mod/github.com/ndecker/[email protected]/main.go:326:26: undefined: prometheus.Handler
Currently the exporter can connect to exactly one fritzbox. So in order so monitor multiple devices multiple exporters need to be setup. And a new port assigned to each.
Other exporters that pull in metrics from other sources like the snmp_exporter or the blackbox_exporter allow to fetch from multiple sources at once.
I propose to extend the exporter to support multiple devices with a single process.
Most probaly the best way would be through a config file specifying which fritz boxes to scrape or torough paramters sent from prometheus like it is done for blackbox_exporter. So something like: http://localhost:9133/probe?address=fritz.box&port=49000
.
Does this feature make sense or does it just over complicate stuff?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.