Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wireguard connection detection #13

Open
martyy665 opened this issue Jul 7, 2024 · 1 comment
Open

Wireguard connection detection #13

martyy665 opened this issue Jul 7, 2024 · 1 comment

Comments

@martyy665
Copy link

Hi there,
I have tried the SW on two independent Debian 12 machines. On both, a wireguard interface is configured and working OK. Running as sudo, I get this output (regardless of verbosity set):

root@martyy-ntb:/home/martyy/projects/Prometheus/wg_exporter/git/wireguard_exporter/target/release# sudo ./wireguard_exporter -vv
2024-07-07T18:38:01.567869Z  INFO wireguard_exporter: Registering metrics...
2024-07-07T18:38:01.567925Z  INFO wireguard_exporter: Spawning server...
2024-07-07T18:38:01.567933Z  INFO wireguard_exporter: Collecting metrics...
2024-07-07T18:38:01.568116Z  INFO prometheus_hyper: starting hyper server to serve metrics
2024-07-07T18:38:01.569724Z  INFO wireguard_exporter: Collecting metrics...
2024-07-07T18:38:06.569237Z  INFO wireguard_exporter: Collecting metrics...
2024-07-07T18:38:11.569793Z  INFO wireguard_exporter: Collecting metrics...
2024-07-07T18:38:16.569782Z  INFO wireguard_exporter: Collecting metrics...
2024-07-07T18:38:21.569817Z  INFO wireguard_exporter: Collecting metrics...
2024-07-07T18:38:26.569409Z  INFO wireguard_exporter: Collecting metrics...
2024-07-07T18:38:31.569560Z  INFO wireguard_exporter: Collecting metrics...

The process is listening on the right port, but Error 404 is always returned:

root@martyy-ntb:/home/martyy/.ssh# wget 127.0.0.1:9586
--2024-07-07 20:38:08--  http://127.0.0.1:9586/
Connecting to 127.0.0.1:9586... connected.
HTTP request sent, awaiting response... 404 Not Found
2024-07-07 20:38:08 ERROR 404: Not Found.

Moreover, with self-compiled binary, the result is same. Can I omit some necessary parameter like for example wg interface name?

@matejgordon
Copy link

You have to go to /metrics not just the plain host url.

for example:
http://127.0.0.1:9586/metrics

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants