lwIP - A Lightweight TCP/IP stack - Bugs: bug #58571, DNS host list is global even for...
You are not allowed to post comments on this tracker with your current authentication level.
bug #58571: DNS host list is global even for multiple netifs
Submitter: | Ashley Duncan <ashesman> | ||
Submitted: | Sun 14 Jun 2020 11:03:31 PM UTC | ||
Category: | DNS | Severity: | 3 - Normal |
Item Group: | Change Request | Status: | None |
Privacy: | Public | Assigned to: | None |
Open/Closed: | Open | Planned Release: | None |
lwIP version: | 2.1.1 |
Jump to the original submission
Mon 26 Oct 2020 02:40:31 PM UTC, comment #9: |
Freddie Chopin <freddie_chopin> |
Mon 26 Oct 2020 02:22:34 PM UTC, comment #8: As I've stumbled into exactly the same problem, I've taken the liberty to take the patch posted earlier by Ashley and update it to the latest lwIP master. It should now apply easily, with no errors or rejects. I've also allowed myself to improve it slightly:
|
Freddie Chopin <freddie_chopin> |
Wed 24 Jun 2020 11:06:15 PM UTC, comment #7: I have attached the patch file below. The patch is for STABLE-2.1.2 release.
|
Ashley Duncan <ashesman> |
Wed 24 Jun 2020 05:21:43 AM UTC, comment #6:
|
Simon Goldschmidt <goldsimon> |
Wed 24 Jun 2020 05:17:57 AM UTC, comment #5: I have made what I think is a simple solution to this issue by allowing (as an option) separate DNS servers per netif. Minimal code changes were required. When the option is turned off, there are no actual code changes outside of dns.c/h. When turned on the changes to external modules are minor. The changes to dns.c are also minor.
|
Ashley Duncan <ashesman> |
Wed 17 Jun 2020 10:27:06 PM UTC, comment #4: Windows allows manually or automatically setting two DNS servers per network interface. No idea what linux/unix does.
|
Ashley Duncan <ashesman> |
Wed 17 Jun 2020 09:52:16 PM UTC, comment #3: Hi,
|
Sylvain Rochet <gradator> |
Wed 17 Jun 2020 08:43:00 PM UTC, comment #2: The netif is a PPP connection to a u-Blox W152 WiFi module. When the PPP connection is established to the module, it appears to negotiate a DNS address and set it. The DNS address is actually just the IP address of the module on the PPP connection. However, the module has no internet connection to the outside world until you send it commands (on a UDP port over the PPP link) to tell it to make the WiFi link. Additionally the module is also a Bluetooth device which is controlled over the same UDP port. Sometimes we wish to only use it for Bluetooth and never enable the WiFi.
|
Ashley Duncan <ashesman> |
Wed 17 Jun 2020 07:59:22 PM UTC, comment #1: The list of DNS servers is global in other OSes, too. Why does your netif add DNS servers without being connected to the internet at all? |
Simon Goldschmidt <goldsimon> |
Sun 14 Jun 2020 11:03:31 PM UTC, original submission:
I have stumbled across a problem today where DNS resolution was failing when using multiple netifs. I tracked it down to the use of a global dns_servers array that is updated by the last netif that gets given a DNS address, even if that netif has no internet connection. Other netifs can then not perform DNS resolution even though they have a valid internet connection.
|
Ashley Duncan <ashesman> |
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 3 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2020-10-26 | freddie_chopin | Attached File | - | Added 0001-Introduce-LWIP_DNS_SERVERS_PER_NETIF-option.patch, #50109 | |
2020-10-26 | freddie_chopin | Attached File | - | Added 0001-Introduce-LWIP_DNS_SERVERS_PER_NETIF-option.patch, #50107 | |
2020-06-24 | ashesman | Attached File | - | Added dnsserverpernetif.patch, #49370 |
Powered by Savane 3.13-758e.
Corresponding source code
Too many spaces between the option name and default value in opt.h (;
I'm uploading updated version.
(file #50109)