-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Long time to establish first ping #1469
Comments
armooo
added a commit
to armooo/headscale
that referenced
this issue
May 27, 2023
This fixes juanfont#1469, where three bugs pervent main from existing on SIGTERM. The first two are blocking receiving from cancel chanels which never have values sent to them, cancelStateUpdateChan and cancelPolicyUpdateChan. It seems closing the chanels should be all the is needed to signal the watching goroutines to exit. The other is the signal hander never exiting an infinite for loop. The sigFunc is called in an errorGroup which blocks exiting Serve and thus main. It looks like a refactor in juanfont#1382 removed an os.Exit(0), replacing it with a return breaks out of the loop.
armooo
added a commit
to armooo/headscale
that referenced
this issue
Jun 10, 2023
This fixes juanfont#1469, where three bugs pervent main from existing on SIGTERM. The first two are blocking receiving from cancel chanels which never have values sent to them, cancelStateUpdateChan and cancelPolicyUpdateChan. It seems closing the chanels should be all the is needed to signal the watching goroutines to exit. The other is the signal hander never exiting an infinite for loop. The sigFunc is called in an errorGroup which blocks exiting Serve and thus main. It looks like a refactor in juanfont#1382 removed an os.Exit(0), replacing it with a return breaks out of the loop.
kradalby
pushed a commit
to armooo/headscale
that referenced
this issue
Jul 7, 2023
This fixes juanfont#1469, where three bugs pervent main from existing on SIGTERM. The first two are blocking receiving from cancel chanels which never have values sent to them, cancelStateUpdateChan and cancelPolicyUpdateChan. It seems closing the chanels should be all the is needed to signal the watching goroutines to exit. The other is the signal hander never exiting an infinite for loop. The sigFunc is called in an errorGroup which blocks exiting Serve and thus main. It looks like a refactor in juanfont#1382 removed an os.Exit(0), replacing it with a return breaks out of the loop.
This issue is stale because it has been open for 180 days with no activity. |
This issue was closed because it has been inactive for 14 days since being marked as stale. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug description
Whenever I try to initiate a connection with one of my machines, the first ping is always very slow, taking sometimes up to 10 seconds. After the first connection, I can ping instantly.
I am not sure this is a normal behaviour, as the connection is supposed to go through the DERP servers if a direct connection has not (yet) be made.
This is somewhat confirmed because if I run
tailscale ping
with a machine where connection has not yet been established I getand it would seem that in this case the connection was made via DERP servers until a direct connection was made. Why is this not the case when I use the
ping
command or try to initiate ahttp
connection ?Environment
To Reproduce
The text was updated successfully, but these errors were encountered: