odhcpd
odhcpd copied to clipboard
odhcpd: (interface) DNS search domains are ignored
if I have e.g.
config interface 'lan'
option device 'br-lan'
option proto 'static'
option ip6assign '64'
list ip6class 'local'
list ip6class 'wan6'
list ipaddr '192.168.1.1/24'
list dns_search 'jinglebollocks'
and I have DHCP config A e.g.
config dhcp 'lan'
option interface 'lan'
option start '100'
option limit '150'
option dhcpv4 'server'
option leasetime '10m'
option ra 'hybrid'
option dhcpv6 'hybrid'
option ra_default '1'
option ndp 'relay'
list ra_flags 'home-agent'
option ra_mininterval '5'
option ra_maxinterval '60'
option preferred_lifetime '7m'
and later DHCP config B (as A but with domains) e.g.:
config dhcp 'lan'
...
list domain 'congabonga'
The GUI in 23.05.0 says for Announced DNS domains
that: If left unspecified, the local device DNS search domain will be announced.
The ICMPv6 RA do not contain DNSSL Option Type 31 with jinglebollocks
. But if I set DHCP config B, ICMPv6 RA contain DNSSL Option Type 31 with congabonga
:
ICMPv6 Option (DNS Search List Option congabonga)
Type: DNS Search List Option (31)
Length: 4 (32 bytes)
Reserved
Lifetime: 180
Domain Names: congabonga
Padding
Can anyone else verify if this behaviour is also present?
Which is correct: the described behaviour or actual?
I met the same problem in 21.02.
I didn't add a network.lan.dns_search
but set dhcp.@dnsmasq[0].domain
instead. Hosts in LAN can obtain the DNS search list from DHCP(v4), but a wireshark capture of IPv6 traffic shows no DNS search list, neither in Router Advertisement nor DHCPv6 reply message. If I add a dhcp.lan.domain
, the search domain will show up in both the RA and DHCPv6 reply.
I'd expect a DNS search list in both the RA and DHCPv6 reply if one of dhcp.lan.domain
, network.lan.dns_search
or dhcp.@dnsmasq[0].domain
is configured. Should there be any conflict, a precedence rule (e.g., dhcp.lan.domain
> network.lan.dns_search
> dhcp.@dnsmasq[0].domain
) may apply.
BTW, I can't see any difference between dhcp.lan.domain
and network.lan.dns_search
. Should we merge them?