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

[BUG] - reconnect after network change or standby takes about 2minutes #417

Open
egabosh opened this issue Oct 28, 2024 · 24 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@egabosh
Copy link

egabosh commented Oct 28, 2024

Describe the bug
The reconnect takes around 2 minutes each time the network is changed or the smartphone comes out of sleep mode (display off).

Smartphone (please complete the following information):

  • Device: Fairphone 4 (FP4)
  • Android Version: 13 / LineageOS 20
  • App Version: 3.5.4 (F-Droid)
  • Backend: 4.19.306

To Reproduce
Set up Wireguard client.
I have tried various ping and auto-tunnel settings. The only thing that helps faster is to deactivate and reactivate the connection in the main window. If the star in dte main window is yellow it takes in any case a longer time until it is reconnecting.
The app has allowed background data and the battery settings are unrestricted

Expected behavior
Fast detection of whether the network is available and immediate reconnect if not.

If this is not a bug what are the optimal ping interval, Ping restart cooldown,... settings for a fast reconnect.

@egabosh egabosh added the bug Something isn't working label Oct 28, 2024
@egabosh
Copy link
Author

egabosh commented Oct 29, 2024

Ah, looks like some additional android settings help:
Settings -> Network and Internet -> VPN -> WG Tunnel -> Continuously active VPN: On.
I'll keep an eye for some days on whether the VPN remains “stable” now.
Could not find this in the documentation. Maybe it should be added?
https://zaneschepke.com/wgtunnel-docs/overview.html

@dvalter
Copy link

dvalter commented Nov 3, 2024

Looks like a new regression in 3.5.3 or 3.5.4, downgrading to 3.5.2 fixes the issue for me

@egabosh
Copy link
Author

egabosh commented Nov 5, 2024

Looks like a new regression in 3.5.3 or 3.5.4, downgrading to 3.5.2 fixes the issue for me

Thanks. Just installed 3.5.2 from F-Droid. I will test here too.

@egabosh
Copy link
Author

egabosh commented Nov 5, 2024

Ah, looks like some additional android settings help: Settings -> Network and Internet -> VPN -> WG Tunnel -> Continuously active VPN: On. I'll keep an eye for some days on whether the VPN remains “stable” now. Could not find this in the documentation. Maybe it should be added? https://zaneschepke.com/wgtunnel-docs/overview.html

Unfortunately only seems to have helped to a limited extent.

@egabosh
Copy link
Author

egabosh commented Nov 5, 2024

Looks like a new regression in 3.5.3 or 3.5.4, downgrading to 3.5.2 fixes the issue for me

Thanks. Just installed 3.5.2 from F-Droid. I will test here too.

Hmm... 3.5.2 seems to crash if I switch from mobile data to WLAN.

@zaneschepke
Copy link
Owner

Hello! I have a LineageOS test device. I'll look into this one.

@egabosh
Copy link
Author

egabosh commented Nov 14, 2024

Hello! I have a LineageOS test device. I'll look into this one.

Thank you! I don't use the Kernel module. May this be needed?
Now testing 3.6 (from F-Droid).

@zaneschepke
Copy link
Owner

3.6.1 is now out. Any improvement on this issue?

@egabosh
Copy link
Author

egabosh commented Nov 29, 2024

installed and trying it...

@egabosh
Copy link
Author

egabosh commented Nov 29, 2024

Update to 3.6.1 didn't help.

@zaneschepke
Copy link
Owner

When you say reconnection, is this talking about auto tunnel switching the tunnel on or is it talking about the tunnel connectivity itself working and I guess I don't understand how phone sleep factors in. Can someone provide clear steps for me to try to reproduce this issue on my LineageOS device? Thanks!

@egabosh
Copy link
Author

egabosh commented Dec 3, 2024

Here my exact settings. Hope it helps.
grafik
grafik
grafik
grafik

@zaneschepke
Copy link
Owner

There are changes in the latest nightly version coming out tonight that I think should help with this one.

@egabosh
Copy link
Author

egabosh commented Dec 10, 2024

Are the changes also in 3.6.2?
As soon as they are available in F-Droid I will try the new version.
Many thanks!

@zaneschepke
Copy link
Owner

The changes are in 3.6.2, but that version has a pretty nasty bug that can cause crashes in certain situations. 3.6.3 would be the right version to test.

@zaneschepke
Copy link
Owner

I'm pretty confident this one is fixed by 3.6.3. If you still have the issue when 3.6.3 goes live on F-Droid, just drop a comment here and I'll reopen the issue. Thanks!

@egabosh
Copy link
Author

egabosh commented Dec 16, 2024

Moin, after Update to 3.6.3 wgtunnel isn't starting anymore:

wgtunnel-crash.mp4

@egabosh
Copy link
Author

egabosh commented Dec 18, 2024

3.6.4 works again. :-) Now testing the reconnect behaviour.

@egabosh
Copy link
Author

egabosh commented Dec 20, 2024

problem continues to occur, even if it feels less frequent.
grafik
Have to switch it off and on with the marked switch, then it works fine again.

@zaneschepke zaneschepke reopened this Dec 20, 2024
@zaneschepke
Copy link
Owner

Sorry, which problem specifically is still present?

@egabosh
Copy link
Author

egabosh commented Dec 21, 2024

The initial problem: "Reconnect after network change or standby takes about 2minutes"

@zaneschepke
Copy link
Owner

Thanks for the details. Would you be willing to try the latest nightly to see if it helps? I made some more improvements to auto tunneling that should help with this.

@egabosh
Copy link
Author

egabosh commented Dec 22, 2024

I'm on vacation with my family, so I probably won't be able to test it again until 2025.

@zaneschepke
Copy link
Owner

I'm on vacation with my family, so I probably won't be able to test it again until 2025.

No worries! Enjoy the time with your family!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants