Warn when libp2p mdns multicast send fails#1681
Open
sblOWPCKCR wants to merge 2 commits intoexo-explore:mainfrom
Open
Warn when libp2p mdns multicast send fails#1681sblOWPCKCR wants to merge 2 commits intoexo-explore:mainfrom
sblOWPCKCR wants to merge 2 commits intoexo-explore:mainfrom
Conversation
Contributor
|
Sounds potentially similar to issues @ciaranbor was running into with tmux? |
Member
|
Yes, this is exactly the same issue. When the login shell that the tmux session was created in closes, discovery breaks and will never work again for that session. Perhaps the daemon stuff @Evanev7 is working on will fix this? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Peer discovery consistently fails on my boxes from time to time. Once it gets into this this state, nothing fixes it short of reboot. I never had Firewall on.
I traced it down to multicast not working. Here's a minimal example to check if you're in this state (should fail with and without --pin):
Interestingly, equivalent code works with
/usr/bin/python3!Even more interestingly, the above code (and exo) consistenly failed for me in my old-running
tmuxsession, but both worked just fine if I created a newtmux(or even rawssh) session.My hypothesis is that macOS assigns different network policies depending on something. Somebody more knowledgable can pick the investigation up.
This PR only makes mDNS errors visible - you would know that discovery is non-functional immediately:
Changes
Set up tracing for mDNS
Why It Works
It doesn't solve the problem, but makes it visible
Test Plan
Manual Testing
I now see this warning when I'm in 'bad' state:
Automated Testing
N/A
Potentially related: #950