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

DNS configuration problems, wifi.radio.dns properties can't be manually set #9712

Closed
jepler opened this issue Oct 12, 2024 · 1 comment · Fixed by #9713
Closed

DNS configuration problems, wifi.radio.dns properties can't be manually set #9712

jepler opened this issue Oct 12, 2024 · 1 comment · Fixed by #9713
Labels
bug espressif applies to multiple Espressif chips network

Comments

@jepler
Copy link
Member

jepler commented Oct 12, 2024

CircuitPython version

Adafruit CircuitPython 9.2.0-beta.1 on 2024-10-11; Adafruit MagTag with ESP32S2

Code/REPL

>>> wifi.radio.addresses
('10.0.3.28',)
>>> wifi.radio.dns
('FD5F:3F5C:FE50::1',)
>>> wifi.radio.ipv4_dns
>>> wifi.radio.ipv4_dns = ipaddress.ip_address("1.1.1.1")
>>> wifi.radio.ipv4_dns
>>> wifi.radio.dns = ('1.1.1.1',)
>>> wifi.radio.dns
('FD5F:3F5C:FE50::1',)

Behavior

I was trying to reproduce #9711 and I grabbed this recently updated magtag. I found that I couldn't resolve ANY hostnames to addresses.

It is set up with CIRCUITPY_WIFI_SSID and _PASSWORD.

The radio gets an ipv4 address but an ipv6 DNS server, which already seems pretty broken. and the DNS server can't be reset by assigning the dns or ipv4_dns properties either.

Description

If I enable ipv6 autoconfiguration, I get working DNS using the IPv6 DNS server address

Additional information

No response

@jepler jepler added the bug label Oct 12, 2024
@jepler
Copy link
Member Author

jepler commented Oct 12, 2024

Actually it appears that the address is being continuously overwritten ...

>>> wifi.radio.dns = ('10.0.2.76',); wifi.radio.dns
('10.0.2.76',)
>>> # Wait 10 seconds
>>> wifi.radio.dns
('FD5F:3F5C:FE50::1',)

This is due to the IPv6 "neighbor discovery"; my router sends a RNDSS (recursive DNS server) announcement. lwip unconditionally overwrites the DNS server list with this. IPv6 neighbor discovery cannot be runtime disabled, so it runs even if IPv6 DHCP is not enabled and the device has no IPv6 address assigned.

@tannewt tannewt added network espressif applies to multiple Espressif chips labels Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug espressif applies to multiple Espressif chips network
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants