[solved] DNS won't work on Openwrt host, but work on all network

I installed AdGuard Home on OpenWRT. I also have two other instances on other LAN machines (all synced with Adguard Sync). I put all three IPs in DHCP Advanced (i.e. 6,ip1,ip2,ip3) in LAN interface config on OpenWRT.

Now, this works great for every machine on the LAN, but for some reason the host OpenWRT router cannot ping any non-ip address in the internet.

cat /etc/resolv.conf

search lan
nameserver 127.0.0.1
nameserver ::1

or add the routers LAN IP to resolv.conf.

Adding anything to resolve.conf is just a temporary fix, as the file gets regenerated upon every reboot. But adding 127.0.0.1 to /etc/adguardhome.yaml did the trick. Thanks.

If your problem is solved, please consider marking this topic as [Solved]. See How to mark a topic as [Solved] for a short how-to.
Thanks! :slight_smile:

that is correct, but if you do it through LuCI, it'll become permanent by writing to /var/resolv.conf.d/resolv.conf.auto during boot.

you could also add echo "nameserver 192.168.1.1" >> /etc/resolv.conf to your /etc/rc.local

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.