ot-br-posix
ot-br-posix copied to clipboard
[openwrt] add mdns support
Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. The current OpenWRT build doesn't publish Thread mDNS.
Describe the solution you'd like A clear and concise description of what you want to happen. Integrate with mdnsd
Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered. Integrate with umdns
Additional context Add any other context or screenshots about the feature request here.
Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. The current OpenWRT build doesn't publish Thread mDNS.
Describe the solution you'd like A clear and concise description of what you want to happen. Integrate with mdnsd
Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered. Integrate with umdns
Additional context Add any other context or screenshots about the feature request here.
Hi, do i need any more configuration after installing umdns? Thank you.
@mrninhvn mdns support on OpenWRT platform is missing, it will be great if you could contribute!
@mrninhvn mdns support on OpenWRT platform is missing, it will be great if you could contribute!
I still don't quite understand, How will the lack of mdns affect? I have 2 border routers, 1 running on openwrt and 1 running on raspberry, openwrt border router cannot run alone without the raspberry router.
@mrninhvn mdns support on OpenWRT platform is missing, it will be great if you could contribute!
Hi, Can you tell me what is missing exactly and what did we have to implement if we need to make it working on OpenWRT ?
Currently I have a problem but I don't really know if it's related to it.
My setup:
- Openthread Border Router is running on a OpenWRT device.
- Matter controller is running on the same OpenWRT device.
Problem:
When I commision a Matter device in the openthread network: it fails when the matter stack try to discover the device just after the ConnectNetworkResponse
(succeed).
In fact, this is the moment when the device is connected to the thread network and the Matter stack try to discover the device using mDNS to finish the commissioning.
Notes:
- The device is in the thread network because I can ping it (with
fd11:22:xxxx
IPV6) - When I try to discover the device, i get no results:
avahi-browse _matter._tcp -r
- The
avahi-daemon
display messages like this sometimes:
sendmsg() to ff02::fb failed: Network is unreachable
Questions:
- Why mDNS packets are not transmit to the thread network like other packets ?
- Do we really need
OTBR_MDNS
to do it ? - Why ?
@mrninhvn
I have 2 border routers, 1 running on openwrt and 1 running on raspberry, openwrt border router cannot run alone without the raspberry router.
What do you mean openwrt border router cannot not run? What's the phenomenon? What's you detail setup?
@caipiblack you need to provide an implementation of the mdns.hpp interface for openWRT. Just as mdns_avahi.cpp for Linux/Raspberry Pi and mdns_mdnssd.cpp for Mac OS. You should use OTBR_MDNS
to specify which mDNS implementation should be used for your platform when building OTBR.
@caipiblack For why we need a mDNS implementation:
- The Thread interface doesn't process multicast packets to handle mDNS queries.
- In Thread network, we use the unicast SRP protocol to register services to the Border Router. This is for avoiding multicast packets in Thread network as it will exhaust battery of end devices.
- End devices' SRP services are registered to a SRP server running on the Border Router.
- There is an Advertising Proxy which helps publish the SRP services on the infrastructure link (e.g. WiFi and Ethernet) as mDNS services.
- Hosts (or mobile devices) on the infrastructure link uses mDNS queries to discover the services registered by end devices.
- The
Advertising Proxy
requires a mDNS implementation to publish the SRP services on the infrastructure link.
What do you mean openwrt border router cannot not run? What's the phenomenon? What's you detail setup?
I got same problem with @caipiblack, thread device can ping to router, but can't ping to wifi device and vice versa.
Update:
Since this pull-request ot-br-posix works with avahi backend for mDNS stuffs.
We can also discover thread devices using avahi-browse from the router or the LAN network of the router.
Is there anything else to check ? Is there still something to do ?
@caipiblack , thanks for helping to address this issue.
We can also discover thread devices using avahi-browse from the router or the LAN network of the router.
This validates the Advertising Proxy, where Thread devices can publish services and devices on the LAN can discover those services.
Is there anything else to check ?
We should also validate the other direction - Discovery Proxy, where Thread devices can discover services on published by devices on the LAN.
Closing stale issue.