Adguardhome as DNS public #2058

Closed
opened 2026-03-04 01:44:18 -05:00 by deekerman · 1 comment
Owner

Originally created by @VGzsysadm on GitHub (Oct 24, 2020).

Greetings.

I have a problem with the docker image of Adguardhome working as DNS public.

Using the following docker-compose.yml

version: '3.8'
services:
  adguardhome:
    restart: always
    build:
      context: adguard_home
      dockerfile: Dockerfile
    container_name: adguardhome
    ports:
      - "53:53"
      - "67:67"
      - "68:68"
      - "8001:80"
      - "10443:443"
      - "853:853"
      - "3002:3000"
    volumes:
      - /srv/adguardhome/adguard_home/work:/opt/adguardhome/work
      - /srv/adguardhome/adguard_home/confdir:/opt/adguardhome/conf

And the following Dockerfile
FROM adguard/adguardhome

I'm just using the default configuration for the adguardhome from docker image, i can create the user and access through an haproxy. But when i point my desktop to my remote adguardhome through the IP public, there's no DNS resolution.

nslookup is always DNS request timed out

Verifications i do
Inside my contenidor i have external resolution

/opt/adguardhome/work # nslookup google.com
Server:         127.0.0.11
Address:        127.0.0.11:53

Non-authoritative answer:
Name:   google.com
Address: 172.217.21.238

Non-authoritative answer:
Name:   google.com
Address: 2a00:1450:4001:819::200e

Inside the dockerhost i have resolution.

Port 53 are open directly to the ip address,

Testing this same situation inside my local network works without any kind of problem so i supose that something is wrong in my remote config.

Anyone tested this situation in his environment?

This is the log output, i can't see any error

2020/10/24 14:42:39 1#117 [info] Starting the DNS proxy server
2020/10/24 14:42:39 1#117 [info] Ratelimit is enabled and set to 20 rps
2020/10/24 14:42:39 1#117 [info] The server is configured to refuse ANY requests
2020/10/24 14:42:39 1#117 [info] DNS cache is enabled
2020/10/24 14:42:39 1#117 [info] Creating the UDP server socket
2020/10/24 14:42:39 1#117 [info] Listening to udp://[::]:53
2020/10/24 14:42:39 1#117 [info] Creating the TCP server socket
2020/10/24 14:42:39 1#117 [info] Listening to tcp://[::]:53
2020/10/24 14:42:39 1#182 [info] Entering the UDP listener loop on [::]:53
2020/10/24 14:42:39 1#183 [info] Entering the tcp listener loop on [::]:53
2020/10/24 14:42:41 1#184 [debug] GET /control/access/list
2020/10/24 14:42:41 1#186 [debug] GET /control/stats
2020/10/24 14:42:41 1#186 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin...
2020/10/24 14:42:41 1#186 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin
2020/10/24 14:42:41 1#186 [debug] Stats: prepared data in 792.543µs
2020/10/24 14:42:41 1#188 [debug] GET /control/stats_info
2020/10/24 14:42:41 1#190 [debug] GET /control/clients/find?ip0=93.176.165.29
2020/10/24 14:42:42 1#119 [debug] GET /control/safebrowsing/status
2020/10/24 14:42:42 1#121 [debug] GET /control/stats_info
2020/10/24 14:42:42 1#123 [debug] GET /control/filtering/status
2020/10/24 14:42:42 1#205 [debug] GET /control/querylog_info
2020/10/24 14:42:42 1#207 [debug] GET /control/parental/status
2020/10/24 14:42:43 1#209 [debug] GET /control/safesearch/status
2020/10/24 14:42:44 1#192 [debug] GET /control/dns_info
2020/10/24 14:42:44 1#225 [debug] GET /control/access/list
2020/10/24 14:42:46 1#227 [debug] GET /control/access/list
2020/10/24 14:42:46 1#229 [debug] GET /control/stats_info
2020/10/24 14:42:46 1#231 [debug] GET /control/stats
2020/10/24 14:42:46 1#231 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin...
2020/10/24 14:42:46 1#231 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin
2020/10/24 14:42:46 1#231 [debug] Stats: prepared data in 308.242µs
2020/10/24 14:42:46 1#233 [debug] GET /control/clients/find?ip0=93.176.165.29
2020/10/24 14:44:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a]
2020/10/24 14:44:55 1#34 [debug] Clients: removed 0 client aliases
2020/10/24 14:44:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output
2020/10/24 14:51:57 1#242 [debug] GET /control/status
2020/10/24 14:51:57 1#128 [debug] GET /control/stats
2020/10/24 14:51:57 1#128 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin...
2020/10/24 14:51:57 1#128 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin
2020/10/24 14:51:57 1#257 [debug] GET /control/stats_info
2020/10/24 14:51:57 1#127 [debug] GET /control/profile
2020/10/24 14:51:57 1#128 [debug] Stats: prepared data in 709.238µs
2020/10/24 14:51:57 1#246 [debug] GET /control/clients/find?ip0=93.176.165.29
2020/10/24 14:51:57 1#248 [debug] GET /control/tls/status
2020/10/24 14:51:58 1#250 [debug] GET /control/access/list
2020/10/24 14:54:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a]
2020/10/24 14:54:55 1#34 [debug] Clients: removed 0 client aliases
2020/10/24 14:54:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output
2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin...
2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin
2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).flushUnitToDB(): Flushing unit 445430
2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).deleteUnit(): bolt DeleteBucket: bucket not found
2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).commitTxn(): tx.Commit
2020/10/24 15:02:33 1#258 [debug] GET /control/status
2020/10/24 15:02:34 1#213 [debug] GET /control/stats_info
2020/10/24 15:02:34 1#260 [debug] GET /control/access/list
2020/10/24 15:02:34 1#216 [debug] GET /control/stats
2020/10/24 15:02:34 1#216 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin...
2020/10/24 15:02:34 1#216 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin
2020/10/24 15:02:34 1#262 [debug] GET /control/tls/status
2020/10/24 15:02:34 1#216 [debug] Stats: prepared data in 1.761947ms
2020/10/24 15:02:34 1#264 [debug] GET /control/profile
2020/10/24 15:02:34 1#254 [debug] GET /control/clients/find?ip0=93.176.165.29
2020/10/24 15:04:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a]
2020/10/24 15:04:55 1#34 [debug] Clients: removed 0 client aliases
2020/10/24 15:04:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output
2020/10/24 15:13:27 1#268 [debug] GET /control/status
2020/10/24 15:13:27 1#238 [debug] GET /control/stats
2020/10/24 15:13:27 1#238 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin...
2020/10/24 15:13:27 1#238 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin
2020/10/24 15:13:27 1#238 [debug] Stats: prepared data in 935.475µs
2020/10/24 15:13:27 1#240 [debug] GET /control/access/list
2020/10/24 15:13:27 1#274 [debug] GET /control/tls/status
2020/10/24 15:13:27 1#271 [debug] GET /control/profile
2020/10/24 15:13:27 1#256 [debug] GET /control/stats_info
2020/10/24 15:13:27 1#276 [debug] GET /control/clients/find?ip0=93.176.165.29
2020/10/24 15:14:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a]
2020/10/24 15:14:55 1#34 [debug] Clients: removed 0 client aliases
2020/10/24 15:14:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output

I tested already the workaround

Running on a system with 'resolved' daemon

Thanks.

Kind regards.

Originally created by @VGzsysadm on GitHub (Oct 24, 2020). Greetings. I have a problem with the docker image of Adguardhome working as DNS public. Using the following docker-compose.yml ``` version: '3.8' services: adguardhome: restart: always build: context: adguard_home dockerfile: Dockerfile container_name: adguardhome ports: - "53:53" - "67:67" - "68:68" - "8001:80" - "10443:443" - "853:853" - "3002:3000" volumes: - /srv/adguardhome/adguard_home/work:/opt/adguardhome/work - /srv/adguardhome/adguard_home/confdir:/opt/adguardhome/conf ``` And the following Dockerfile `FROM adguard/adguardhome` I'm just using the default configuration for the adguardhome from docker image, i can create the user and access through an haproxy. But when i point my desktop to my remote adguardhome through the IP public, there's no DNS resolution. nslookup is always DNS request timed out **Verifications i do** Inside my contenidor i have external resolution ``` /opt/adguardhome/work # nslookup google.com Server: 127.0.0.11 Address: 127.0.0.11:53 Non-authoritative answer: Name: google.com Address: 172.217.21.238 Non-authoritative answer: Name: google.com Address: 2a00:1450:4001:819::200e ``` Inside the dockerhost i have resolution. Port 53 are open directly to the ip address, Testing this same situation inside my local network works without any kind of problem so i supose that something is wrong in my remote config. Anyone tested this situation in his environment? This is the log output, i can't see any error 2020/10/24 14:42:39 1#117 [info] Starting the DNS proxy server 2020/10/24 14:42:39 1#117 [info] Ratelimit is enabled and set to 20 rps 2020/10/24 14:42:39 1#117 [info] The server is configured to refuse ANY requests 2020/10/24 14:42:39 1#117 [info] DNS cache is enabled 2020/10/24 14:42:39 1#117 [info] Creating the UDP server socket 2020/10/24 14:42:39 1#117 [info] Listening to udp://[::]:53 2020/10/24 14:42:39 1#117 [info] Creating the TCP server socket 2020/10/24 14:42:39 1#117 [info] Listening to tcp://[::]:53 2020/10/24 14:42:39 1#182 [info] Entering the UDP listener loop on [::]:53 2020/10/24 14:42:39 1#183 [info] Entering the tcp listener loop on [::]:53 2020/10/24 14:42:41 1#184 [debug] GET /control/access/list 2020/10/24 14:42:41 1#186 [debug] GET /control/stats 2020/10/24 14:42:41 1#186 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin... 2020/10/24 14:42:41 1#186 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin 2020/10/24 14:42:41 1#186 [debug] Stats: prepared data in 792.543µs 2020/10/24 14:42:41 1#188 [debug] GET /control/stats_info 2020/10/24 14:42:41 1#190 [debug] GET /control/clients/find?ip0=93.176.165.29 2020/10/24 14:42:42 1#119 [debug] GET /control/safebrowsing/status 2020/10/24 14:42:42 1#121 [debug] GET /control/stats_info 2020/10/24 14:42:42 1#123 [debug] GET /control/filtering/status 2020/10/24 14:42:42 1#205 [debug] GET /control/querylog_info 2020/10/24 14:42:42 1#207 [debug] GET /control/parental/status 2020/10/24 14:42:43 1#209 [debug] GET /control/safesearch/status 2020/10/24 14:42:44 1#192 [debug] GET /control/dns_info 2020/10/24 14:42:44 1#225 [debug] GET /control/access/list 2020/10/24 14:42:46 1#227 [debug] GET /control/access/list 2020/10/24 14:42:46 1#229 [debug] GET /control/stats_info 2020/10/24 14:42:46 1#231 [debug] GET /control/stats 2020/10/24 14:42:46 1#231 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin... 2020/10/24 14:42:46 1#231 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin 2020/10/24 14:42:46 1#231 [debug] Stats: prepared data in 308.242µs 2020/10/24 14:42:46 1#233 [debug] GET /control/clients/find?ip0=93.176.165.29 2020/10/24 14:44:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a] 2020/10/24 14:44:55 1#34 [debug] Clients: removed 0 client aliases 2020/10/24 14:44:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output 2020/10/24 14:51:57 1#242 [debug] GET /control/status 2020/10/24 14:51:57 1#128 [debug] GET /control/stats 2020/10/24 14:51:57 1#128 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin... 2020/10/24 14:51:57 1#128 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin 2020/10/24 14:51:57 1#257 [debug] GET /control/stats_info 2020/10/24 14:51:57 1#127 [debug] GET /control/profile 2020/10/24 14:51:57 1#128 [debug] Stats: prepared data in 709.238µs 2020/10/24 14:51:57 1#246 [debug] GET /control/clients/find?ip0=93.176.165.29 2020/10/24 14:51:57 1#248 [debug] GET /control/tls/status 2020/10/24 14:51:58 1#250 [debug] GET /control/access/list 2020/10/24 14:54:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a] 2020/10/24 14:54:55 1#34 [debug] Clients: removed 0 client aliases 2020/10/24 14:54:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output 2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin... 2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin 2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).flushUnitToDB(): Flushing unit 445430 2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).deleteUnit(): bolt DeleteBucket: bucket not found 2020/10/24 15:00:00 1#39 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).commitTxn(): tx.Commit 2020/10/24 15:02:33 1#258 [debug] GET /control/status 2020/10/24 15:02:34 1#213 [debug] GET /control/stats_info 2020/10/24 15:02:34 1#260 [debug] GET /control/access/list 2020/10/24 15:02:34 1#216 [debug] GET /control/stats 2020/10/24 15:02:34 1#216 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin... 2020/10/24 15:02:34 1#216 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin 2020/10/24 15:02:34 1#262 [debug] GET /control/tls/status 2020/10/24 15:02:34 1#216 [debug] Stats: prepared data in 1.761947ms 2020/10/24 15:02:34 1#264 [debug] GET /control/profile 2020/10/24 15:02:34 1#254 [debug] GET /control/clients/find?ip0=93.176.165.29 2020/10/24 15:04:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a] 2020/10/24 15:04:55 1#34 [debug] Clients: removed 0 client aliases 2020/10/24 15:04:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output 2020/10/24 15:13:27 1#268 [debug] GET /control/status 2020/10/24 15:13:27 1#238 [debug] GET /control/stats 2020/10/24 15:13:27 1#238 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin... 2020/10/24 15:13:27 1#238 [debug] github.com/AdguardTeam/AdGuardHome/stats.(*statsCtx).beginTxn(): db.Begin 2020/10/24 15:13:27 1#238 [debug] Stats: prepared data in 935.475µs 2020/10/24 15:13:27 1#240 [debug] GET /control/access/list 2020/10/24 15:13:27 1#274 [debug] GET /control/tls/status 2020/10/24 15:13:27 1#271 [debug] GET /control/profile 2020/10/24 15:13:27 1#256 [debug] GET /control/stats_info 2020/10/24 15:13:27 1#276 [debug] GET /control/clients/find?ip0=93.176.165.29 2020/10/24 15:14:55 1#34 [debug] github.com/AdguardTeam/AdGuardHome/home.(*clientsContainer).addFromSystemARP(): executing /sbin/arp [arp -a] 2020/10/24 15:14:55 1#34 [debug] Clients: removed 0 client aliases 2020/10/24 15:14:55 1#34 [debug] Clients: added 0 client aliases from 'arp -a' command output I tested already the workaround Running on a system with 'resolved' daemon Thanks. Kind regards.
deekerman 2026-03-04 01:44:18 -05:00
  • closed this issue
  • added the
    question
    label
Author
Owner

@ameshkov commented on GitHub (Oct 26, 2020):

I guess the easiest way would be to run the container with --network host

@ameshkov commented on GitHub (Oct 26, 2020): I guess the easiest way would be to run the container with --network host
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/AdGuardHome#2058
No description provided.