Problems with local network DNS after update

After the recent updates to my Turris Omnia, I’m having problems with DNS lookups for local computers. At first looking up hostnames for non-static DHCP leases did not work, and I was getting errors saying:

Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 3: import: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 4: import: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 5: import: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 6: from: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 7: import: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 8: import: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 9: import: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 10: from: not found
Oct 22 10:21:26 damma dnsmasq-script[8079]: /usr/lib/dnsmasq/dhcp-script.sh: /etc/resolver/dhcp_host_domain_ng.py: line 13: syntax error: unexpected "("
Oct 22 10:21:26 damma dnsmasq[8079]: script process exited with status 2

That seems to have been resolved by disabling and reenabling “Enable DHCP clients in DNS” in reForis. After that, lookups for for local computers work, but only for lookups in the format <hostname>.<networkname>, not lookups for just <hostname> (although just <hostname> does work for infinite-duration static leases).

Also, lookups for the router’s own hostname, as <hostname>.<networkname>, is broken, instead returning an IP address for a DHCP lease with an empty hostname (which particular one it returns seems to change occasionally).

1 Like

I also found out about this today. What a coincidence.

Despite the log, noone’s confirmed it causing some real issue so far.

Can confirm this. I imported hostnames from /etc/hosts. Routername is not able to be looked up and i have to add separte lines for . and

Workaround: go to Reforis, Network Settings, DNS. Uncheck “Enable DHCP clients in DNS”, save. Then check “Enable DHCP clients in DNS” and save. After that, this issue seems to be fixed.

Simpler workaround from console: remove line option dhcpscript '/etc/resolver/dhcp_host_domain_ng.py' from /etc/config/dhcp and then call /etc/init.d/resolver restart.

I tried that. It turned out to only be a temporary solution, as later it has stopped resolving some hosts again.