DNS not working for openwrt router itself after installing adguardhome

DNS is working for lan devices but DNS is not working for openwrt router itself. And I am unable to run opkg update. I selected lan interface only during adguardhome setup for dns.

root@OpenWrt:~# nslookup google.com
nslookup: write to '127.0.0.1': Connection refused
nslookup: write to '::1': Connection refused
;; connection timed out; no servers could be reached

cat /etc/resolv.conf
search lan
nameserver 127.0.0.1
nameserver ::1

cat /etc/config/dhcp

config dnsmasq
        option domainneeded '1'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option cachesize '0'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option localservice '1'
        option ednspacket_max '1232'
        option port '54'
        option noresolv '1'
        list server '10.12.12.1'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv4 'server'
        option dhcpv6 'server'
        option ra 'server'
        list ra_flags 'managed-config'
        list ra_flags 'other-config'
        list dhcp_option '3,10.12.12.1'
        list dhcp_option '6,10.12.12.1'
        list dhcp_option '15,lan'
        list dns 'fd23:8947:12ed::1'

config dhcp 'wan'
        option interface 'wan'
        option ignore '1'

config odhcpd 'odhcpd'
        option maindhcp '0'
        option leasefile '/tmp/hosts/odhcpd'
        option leasetrigger '/usr/sbin/odhcpd-update'
        option loglevel '4'
 cat /etc/config/network

config interface 'loopback'
        option device 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config globals 'globals'
        option ula_prefix 'fd23:8947:12ed::/48'
        option packet_steering '2'

config device
        option name 'br-lan'
        option type 'bridge'
        list ports 'eth0'

config interface 'lan'
        option device 'br-lan'
        option proto 'static'
        option ipaddr '10.12.12.1'
        option netmask '255.255.255.0'
        option ip6assign '60'

config device
        option type '8021q'
        option ifname 'eth1'
        option vid '10'
        option name 'eth1.10'

config device
        option type '8021q'
        option ifname 'eth1'
        option vid '20'
        option name 'eth1.20'
        option multicast '1'

config interface 'wan'
        option proto 'pppoe'
        option device 'eth1.10'
        option username ''
        option password ''
        option ipv6 'auto'

config interface 'iptv'
        option proto 'static'
        option device 'eth1.20'
        option ipaddr '10.10.10.1'
        option netmask '255.255.255.0'

config interface 'accessmodem'
        option proto 'static'
        option device 'eth1'
        option ipaddr '192.168.1.5'
        option netmask '255.255.255.0'
ubus call system board
opkg list-installed adguardhome
1 Like
ubus call system board
{
        "kernel": "6.6.73",
        "hostname": "Network",
        "system": "ARMv8 Processor rev 3",
        "model": "Raspberry Pi 4 Model B Rev 1.1",
        "board_name": "raspberrypi,4-model-b",
        "rootfs_type": "ext4",
        "release": {
                "distribution": "OpenWrt",
                "version": "24.10.0",
                "revision": "r28427-6df0e3d02a",
                "target": "bcm27xx/bcm2711",
                "description": "OpenWrt 24.10.0 r28427-6df0e3d02a",
                "builddate": "1738624177"
        }
}
 opkg list-installed adguardhome
adguardhome - 0.107.53-r1

thank you so much. :smiley:

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