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

It won't hold the connection to wireguard. #11

Closed
legomannetje opened this issue Oct 11, 2021 · 4 comments
Closed

It won't hold the connection to wireguard. #11

legomannetje opened this issue Oct 11, 2021 · 4 comments

Comments

@legomannetje
Copy link

Problem/Motivation

When installed in the hassio os version it is unable to connect.

Expected behavior

It connects to my wireguard server

Actual behavior

It makes an initial connection, but doesn't hold it. I can see it connects, send a couple packages, and then it drops

Steps to reproduce

Install hassio os, this plugin and try to connect to a server.

Proposed changes

No idea.

Logs

https://pastebin.com/aem09zsr

@bigmoby
Copy link
Owner

bigmoby commented Oct 19, 2021

Please could you post here your Wireguard addon plugin configuration?
Please obfuscate the password and the server fields 👍

@legomannetje
Copy link
Author

interface:
private_key: PrivateKey
address: 10.116.181.38
dns:
- 10.2.3.1
post_up: iptables -t nat -A POSTROUTING -o wg0 -j MASQUERADE
post_down: iptables -t nat -D POSTROUTING -o wg0 -j MASQUERADE
peer:
public_key: MyPublicKey
pre_shared_key: PreSharedKey
endpoint: ServerIP:41775
allowed_ips:
- 0.0.0.0/0,::/0
persistent_keep_alive: '25'

@bigmoby
Copy link
Owner

bigmoby commented Oct 21, 2021

Hi @legomannetje ,
please try with this configuration:

interface:
  private_key: PrivateKey
  address: 10.116.181.38
  dns:
    - 10.2.3.1
  post_up: iptables -t nat -A POSTROUTING -o wg0 -j MASQUERADE
  post_down: iptables -t nat -D POSTROUTING -o wg0 -j MASQUERADE
peer:
  public_key: MyPublicKey
  pre_shared_key: PreSharedKey
  endpoint: ServerIP:41775
  allowed_ips:
    - 10.116.181.0/24
  persistent_keep_alive: 25

I changed allowed_ips notation avoiding the 0.0.0.0 (no sense because I could imagine your client is not on the same host machine) neither the IPv6 not supported.
Please try it and give me a feedback 👍
p.s.: Are you sure that your dns is aware of the ServerIP resolution?

@legomannetje
Copy link
Author

Yep, that solved it! Thanks a lot!

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