From: Srinivasa Raghavan <raghav135@gmail.com>
To: musl@lists.openwall.com
Subject: Re: DNS resolution happenning only after timeout
Date: Wed, 04 Oct 2017 19:28:35 +0000 [thread overview]
Message-ID: <CAGpKtJ6vz6cqYDFJnP+tH7YBc-T_XEUWguji6_t+CR_WJ_j9ag@mail.gmail.com> (raw)
In-Reply-To: <20171004164638.4k3ozfsavcsthmhw@voyager>
[-- Attachment #1: Type: text/plain, Size: 1963 bytes --]
Hi Markus,
Thanks for the reply.
The problem is not only in nslookup, it is there in ping, tracert, curl,
node.js, wget etc. :(
I will debug and find the exact c api that is used for each of the
scenarios.
I am just wondering if there is any workaround ?
Lot of folks are facing this issue (slow dns name resolution in alpine
linux, with some dns servers) , and this may be the root cause?
Kind Regards,
Rsr
On Wed, 4 Oct 2017 at 10:16 PM, Markus Wichmann <nullplan@gmx.net> wrote:
> On Wed, Oct 04, 2017 at 07:18:10PM +0530, Srinivasa Raghavan wrote:
> > Hi Rich,
> >
> > Thanks for the reply.
> >
> > Some updates:
> > 1. Our DNS server is "Infoblox appliance".
> > 2. When we had a delay, we found that there was a "AAAA" query along with
> > "A" query.
> >
> > I did further debugging with "tcpdump" and able to narrow down on the
> > difference in behavior between "debian" and "alpine" images.
> >
> > In debian:
> > If ipv6 is disabled (net.ipv6.conf.default.disable_ipv6 = 1)
> > Then the "nslookup" (or name resolution) does *not* do a "AAAA" query
> >
>
> That's probably because glibc's DNS resolver only generates AAAA queries
> if it can create an IPv6 socket.
>
> > In alpine:
> > If ipv6 is disabled (net.ipv6.conf.default.disable_ipv6 = 1)
> > Then the "nslookup" (or name resolution) does an "AAAA" query along with
> > "A" query
> >
> > Is this intentional?
> >
> > Also, I was wondering if there was any way to disable AAAA query in name
> > resolution?
> >
>
> There does not appear to be a way without changing code. In musl, the
> function name_from_dns() will always generate both the AAAA and the A
> query unless "family" is explicitly set to one of the address families.
> No input from resolv.conf or similar is used for this. And "family"
> comes directly from the caller, i.e. nslookup. You'd have to change the
> nslookup code to only ask for IPv4 addresses.
>
> > Kind Regards,
> > Srinivasa Raghavan.
>
> Ciao,
> Markus
>
[-- Attachment #2: Type: text/html, Size: 2886 bytes --]
next prev parent reply other threads:[~2017-10-04 19:28 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-28 10:15 Srinivasa Raghavan
2017-09-28 10:28 ` Szabolcs Nagy
2017-09-28 16:55 ` Rich Felker
2017-10-04 13:48 ` Srinivasa Raghavan
2017-10-04 16:46 ` Markus Wichmann
2017-10-04 19:28 ` Srinivasa Raghavan [this message]
2017-10-04 20:18 ` Rich Felker
2017-10-04 20:39 ` Srinivasa Raghavan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAGpKtJ6vz6cqYDFJnP+tH7YBc-T_XEUWguji6_t+CR_WJ_j9ag@mail.gmail.com \
--to=raghav135@gmail.com \
--cc=musl@lists.openwall.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).