Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DNS server returns NXDOMAIN on non-existing AAAA records #5088

Closed
2 tasks done
radhus opened this issue Nov 29, 2020 · 2 comments
Closed
2 tasks done

DNS server returns NXDOMAIN on non-existing AAAA records #5088

radhus opened this issue Nov 29, 2020 · 2 comments

Comments

@radhus
Copy link

radhus commented Nov 29, 2020

  • I have tried with the latest version of my channel (Stable or Edge)
  • I have uploaded Diagnostics
  • Diagnostics ID: 3DDF88CF-907D-4BF1-8BEF-3FD8E7207349/20201129181726

Expected behavior

Resolving a domain name which doesn't have an AAAA record should return no response.

Example from dig towards Google DNS:

$ dig @8.8.8.8 github.com AAAA

; <<>> DiG 9.10.6 <<>> @8.8.8.8 github.com AAAA
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 15515
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 512
;; QUESTION SECTION:
;github.com.			IN	AAAA

;; AUTHORITY SECTION:
github.com.		838	IN	SOA	ns-1707.awsdns-21.co.uk. awsdns-hostmaster.amazon.com. 1 7200 900 1209600 86400

;; Query time: 33 msec
;; SERVER: 8.8.8.8#53(8.8.8.8)
;; WHEN: Sun Nov 29 19:08:27 CET 2020
;; MSG SIZE  rcvd: 123

Actual behavior

DNS server inside Docker for Mac returns NXDOMAIN (as compared to status NOERROR above):

$ docker run --rm -ti alpine:edge sh -c 'apk add bind-tools >/dev/null 2>&1 && dig github.com AAAA'

; <<>> DiG 9.16.8 <<>> github.com AAAA
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 8937
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;github.com.                    IN      AAAA

;; Query time: 0 msec
;; SERVER: 192.168.65.1#53(192.168.65.1)
;; WHEN: Sun Nov 29 18:09:49 UTC 2020
;; MSG SIZE  rcvd: 28

Information

  • macOS Version: 10.14.6

While this might have worked in most cases, I see big issues running late edge versions of Alpine Linux which contains musl libc version 1.2.1+. In 1.2.1 this commit was introduced, which I think is the culprit of the problems. In my understanding, musl will query for both A and AAAA records, and if either of them return NXDOMAIN it will treat the whole domain as not-existing.

musl is probably doing the right thing here, and I cannot find other DNS servers that returns NXDOMAIN like this.

This is potentially related to these issues?

Diagnostic logs

Docker for Mac: 2.5.2 (50165)
Engine: 20.10.0-rc1

Steps to reproduce the behavior

Run docker run --rm -ti alpine:edge sh -c 'apk add bind-tools >/dev/null 2>&1 && dig github.com AAAA' and see if the DNS server returns NOERROR (correct) or NXDOMAIN (incorrect - hence reproduced) as status.

@stephen-turner
Copy link
Contributor

Thanks, this is a dupe of #5020.

@docker-robott
Copy link
Collaborator

Closed issues are locked after 30 days of inactivity.
This helps our team focus on active issues.

If you have found a problem that seems similar to this, please open a new issue.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows.
/lifecycle locked

@docker docker locked and limited conversation to collaborators Dec 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants