Skip to content

Explicitly set IP_MULTICAST_IF to ensure that queries are sent on specified NIC#27

Open
jaime-sense wants to merge 1 commit into
dylanmckay:masterfrom
jaime-sense:multihomed
Open

Explicitly set IP_MULTICAST_IF to ensure that queries are sent on specified NIC#27
jaime-sense wants to merge 1 commit into
dylanmckay:masterfrom
jaime-sense:multihomed

Conversation

@jaime-sense

Copy link
Copy Markdown

When using a multihomed environment, the library allows the user to specified a NIC to search for a particular service; however without setting IP_MULTICAST_IF, the OS is free to send the query on an interface of its choosing. This change forces the send to occur on the user specified interface. This change works also when using INADDR_ANY.

@esarver

esarver commented Aug 9, 2022

Copy link
Copy Markdown

I have tested this on windows and can confirm it works perfectly. I was having this exact issue when running discovery on multiple NICs.

@esarver

esarver commented Mar 7, 2024

Copy link
Copy Markdown

@dylanmckay is there something holding this PR up? I would be happy to help get it merged. I haven't tested this patch against the latest version, though there doesn't appear to be any conflicts (according to GitHub). The MDNS search doesn't work properly for me without this change.

@esarver

esarver commented Mar 7, 2024

Copy link
Copy Markdown

I have once again tested these changes against 3.0.0 and it works perfectly (on Windows. I have not tested on Linux yet).

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

Successfully merging this pull request may close these issues.

2 participants