-
Notifications
You must be signed in to change notification settings - Fork 7.4k
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 does not send goodbye messages when removing services (IDFGH-1379) #3660
Comments
@liuzfesp @Alvin1Zhang , Any idea if there are plans to fix this soon? I have also noticed that there is no way to send "Announcements to Flush Outdated Cache Entries" per rfc 67662 section 10.2 |
I would guess that there is not enough time for the messages to be sent. Code is there though. If you remove the services before freeing the service, bye should be sent. It is implemented. |
Here is the method that actually does it. You can trace it in the code and see how it's organised. https://github.com/espressif/esp-idf/blob/master/components/mdns/mdns.c#L1432 |
Let me just note a workaround to have the bye packet sent on
The issue seems to be that the library tends to skip the function @me-no-dev referenced if the service has instance name configured. This should be fixed shortly. |
Has there been any progress on this issue? |
The fix is currently under review in the internal repository, sorry for the delay |
Hello, just following up on this issue. Last update was that it was under internal review 25 days ago. Appreciate any updates you can provide. |
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
…move_all() or mdns_free() Closes espressif/esp-idf#3660 * Original commit: espressif/esp-idf@a001998
Environment
Problem Description
When calling mdns_free() or mdns_remove_all_services() an mDNS goodbye message is not sent. Using an iOS device, I can see it generate announcements when it wakes up and goodbyes when it goes to sleep in WireShark. Upon mDNS init, the ESP32 sends the announcesments for all configured services as can be observed in WireShark. mDNS discovery tools such as avahi-discover or dns-sd also show the presence of the ESP.
However, when mDNS services are removed or the mDNS service is stopped using mdns_free(), goodbye messages are not seen on the network and ESP devices still show up in avahi-discover and dns-sd
Expected Behavior
Goodbye messages are sent when shutting down mDNS and devices disappear from avahi-discover.
Actual Behavior
No goodbye messages are seen, and avahi-discover still shows devices in list.
Steps to repropduce
The text was updated successfully, but these errors were encountered: