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

mdns through thread networks / border routing #2578

Open
dakhnod opened this issue Nov 1, 2024 · 9 comments
Open

mdns through thread networks / border routing #2578

dakhnod opened this issue Nov 1, 2024 · 9 comments

Comments

@dakhnod
Copy link

dakhnod commented Nov 1, 2024

I have the following setup:

A <--thread--> B <--Ethernet--> C

All of the nodes have avahi running, with ipv4 enabled for B and C.
B(avahi) is configured as a reflector. It is supposed to bridge avahi between A and C.
A and B have point-to-point interfaces enabled.

My issue is that A can simply not resolve C.local.
Is there any quirks for mdns through thread?
Maybe multicast ff00::fb doesn't work in thread?

Thanks you so much!

@jwhui
Copy link
Member

jwhui commented Nov 1, 2024

Thread supports DNS-based Service Discovery using the Service Registration Protocol and unicast DNS. Thread Border Routers implement both a DNS Discovery Proxy and Advertising Proxy to support discovery across the Thread and Ethernet/Wi-Fi segments.

The Thread Border Router Codelab may be useful to provide more information.

@dakhnod
Copy link
Author

dakhnod commented Nov 1, 2024

Thanks, this is great!
Yet, does thread anyhow stand in the way of mdns? For our setup, it would be great to avoid having an a centralized dns server...

@jwhui
Copy link
Member

jwhui commented Nov 1, 2024

With SRP, the Thread Border Router serves as a DNS an SRP server. Thread devices publish their DNS service names to the SRP server and the Thread Border Router publishes them using mDNS on the Ethernet side. This allows Ethernet/Wi-Fi hosts to use mDNS to discover services published by Thread devices.

@dakhnod
Copy link
Author

dakhnod commented Nov 1, 2024

Okay, this sounds useful.
But what about the other side?
Are thread devices able to discover mdns devices from the ethernet network?

@jwhui
Copy link
Member

jwhui commented Nov 1, 2024

Yes, Thread devices use unicast DNS to the Thread Border Router, which then uses mDNS via a Discovery Proxy to discover services on the Ethernet/Wi-Fi side.

@dakhnod
Copy link
Author

dakhnod commented Nov 1, 2024

Ah, so the following apply?

  1. I don't need to have avahi running on my thread devices
  2. I don't need to configure avahi as reflector, since the BR does the mDNS bridging?

Do I still have to request .local addresses?

@jwhui
Copy link
Member

jwhui commented Nov 2, 2024

  1. I don't need to have avahi running on my thread devices

Correct.

  1. I don't need to configure avahi as reflector, since the BR does the mDNS bridging?

The BR needs an mDNS service to perform DNS-SD/mDNS queries and responses. ot-br-posix has example integrations with avahi and mDNSResponder.

Do I still have to request .local addresses?

Thread devices use default.service.arpa to discover services within the Thread and Ethernet/Wi-Fi networks.

@dakhnod
Copy link
Author

dakhnod commented Nov 4, 2024

Thanks, this is highly informative and probably the way to go!

Still, I would be grateful to know if anything stop mdns from properly working.
Is it no possible to send multicast packets to ff02::fb?

@jwhui
Copy link
Member

jwhui commented Nov 19, 2024

Still, I would be grateful to know if anything stop mdns from properly working.
Is it no possible to send multicast packets to ff02::fb?

mDNS was largely designed for networks where broadcast is relatively efficient (i.e. Ethernet). On constrained networks like Thread, there is not much capacity for multicast traffic.

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

No branches or pull requests

2 participants