-
Notifications
You must be signed in to change notification settings - Fork 18.1k
runtime: Deadlock while writing to UDP socket when laptop goes to sleep #61555
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
Comments
@ianlancetaylor @neild |
Working with a user who more reliably encountered this issue, we've identified a Mac program called Little Snitch ( I wrote a stub program that sends out UDP packets to many different port numbers, on the theory that each of these packets look like a new connection to Little Snitch. Little Snitch then (in one of its modes) triggers when detecting these new connections, and prompts me to allow or deny the connection. When it does this, the UDP packets block while being sent until the dialog is responded to. If I either deny the connection or don't allow it quickly enough, the program remains frozen. Reproduction steps:
Stub program (edit the code with your favorite IP address to control which host you spam with the UDP packets):
We have emailed the authors of Little Snitch to push this issue we encountered forward. I'm not sure at this point that this is a golang problem. I'm suspicious that Little Snitch / MacOS's API that Little Snitch is using is somehow not marking the fd as writable again after blocking it. (Could be a Little Snitch bug or MacOS bug.) |
@nbrownus Are you working with @brad-defined ? Does the Little Snitch problem apply to your case as well? Thanks. |
@ianlancetaylor yes - @nbrownus and I work at the same place. The user who reported the initial issue to us which generated the originally reported stack trace in this ticket was running Little Snitch. |
I'm a former Little Snitch user, might try to repro on my old personal laptop. |
@ianlancetaylor yes, @brad-defined and I work together. Little snitch was installed in all cases that we've seen so far. |
Thanks, I'm going to optimistically close this as something that can't be fixed by changes to Go. Please comment if you disagree. |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Have not tried yet, difficult to reproduce reliably.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
Ran nebula, put laptop to sleep, came back after a while and woke laptop, goroutine handling UDP writes was hung.
What did you expect to see?
UDP writes happening as expected
What did you see instead?
We have had a few instances of this and I am not sure where else to look. Sending
SIGQUIT
to the process, they all appear to have a goroutine blocked in the same way.The text was updated successfully, but these errors were encountered: