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

net: netgo builtin DNS resolver runs slow when resolv.conf has bogus name server entries #6579

Closed
mikioh opened this issue Oct 13, 2013 · 14 comments
Milestone

Comments

@mikioh
Copy link
Contributor

mikioh commented Oct 13, 2013

Builtin DNS resolver runs pretty slow when resolv.conf contains bogus name server
entries like the following:

nameserver 4.4.4.4 // bogus name server
nameserver 1.2.3.4 // bogus too
nameserver 8.8.8.8
@mikioh
Copy link
Contributor Author

mikioh commented Oct 13, 2013

Comment 1:

https://golang.org/cl/14441059/

@mikioh
Copy link
Contributor Author

mikioh commented Oct 13, 2013

Comment 2:

and https://golang.org/cl/14433062/

@rsc
Copy link
Contributor

rsc commented Dec 4, 2013

Comment 3:

Labels changed: added release-none, removed go1.3maybe.

@rsc
Copy link
Contributor

rsc commented Dec 4, 2013

Comment 4:

Labels changed: added repo-main.

@mikioh
Copy link
Contributor Author

mikioh commented Jan 22, 2014

Comment 5:

Labels changed: added release-go1.3, removed release-none.

@mikioh
Copy link
Contributor Author

mikioh commented Mar 28, 2014

Comment 6:

Labels changed: added release-go1.4, removed release-go1.3.

@gopherbot
Copy link

Comment 7:

CL https://golang.org/cl/14441059 references this issue.

@gopherbot
Copy link

Comment 8:

CL https://golang.org/cl/75180043 references this issue.

@gopherbot
Copy link

Comment 9:

CL https://golang.org/cl/14441059 references this issue.

@gopherbot
Copy link

Comment 10:

CL https://golang.org/cl/105110044 mentions this issue.

@gopherbot
Copy link

Comment 11:

CL https://golang.org/cl/101220044 mentions this issue.

@mikioh
Copy link
Contributor Author

mikioh commented Aug 6, 2014

Comment 12:

This issue was updated by revision 48e7533.

LGTM=alex, kevlar
R=golang-codereviews, alex, gobot, iant, minux, kevlar
CC=golang-codereviews
https://golang.org/cl/101220044

@gopherbot
Copy link

Comment 13:

CL https://golang.org/cl/128820043 mentions this issue.

@mikioh
Copy link
Contributor Author

mikioh commented Aug 30, 2014

Comment 14:

This issue was closed by revision 39a021b.

Status changed to Fixed.

@rsc rsc added this to the Go1.4 milestone Apr 14, 2015
@rsc rsc removed the release-go1.4 label Apr 14, 2015
@golang golang locked and limited conversation to collaborators Jun 25, 2016
wheatman pushed a commit to wheatman/go-akaros that referenced this issue Jun 25, 2018
Speed improvements via code cleanup, and changes to make go dns behave more like glibc resolver.  See https://groups.google.com/forum/#!topic/golang-dev/lV-0aHqxVeo

Fixes golang#6579.

Benchmark results on linux/amd64

benchmark                                  old ns/op    new ns/op    delta
BenchmarkGoLookupIP                          4831903      2572937  -46.75%
BenchmarkGoLookupIPNoSuchHost               10114105      2419641  -76.08%
BenchmarkGoLookupIPWithBrokenNameServer  20007735624   5004490730  -74.99%

benchmark                                 old allocs   new allocs    delta
BenchmarkGoLookupIP                              287          288    0.35%
BenchmarkGoLookupIPNoSuchHost                    204          102  -50.00%
BenchmarkGoLookupIPWithBrokenNameServer          410          358  -12.68%

benchmark                                  old bytes    new bytes    delta
BenchmarkGoLookupIP                            13181        13271    0.68%
BenchmarkGoLookupIPNoSuchHost                  17260         8714  -49.51%
BenchmarkGoLookupIPWithBrokenNameServer        28160        22432  -20.34%

LGTM=mikioh.mikioh
R=golang-codereviews, mikioh.mikioh, bradfitz, josharian, abursavich
CC=golang-codereviews
https://golang.org/cl/128820043
wheatman pushed a commit to wheatman/go-akaros that referenced this issue Jul 9, 2018
Speed improvements via code cleanup, and changes to make go dns behave more like glibc resolver.  See https://groups.google.com/forum/#!topic/golang-dev/lV-0aHqxVeo

Fixes golang#6579.

Benchmark results on linux/amd64

benchmark                                  old ns/op    new ns/op    delta
BenchmarkGoLookupIP                          4831903      2572937  -46.75%
BenchmarkGoLookupIPNoSuchHost               10114105      2419641  -76.08%
BenchmarkGoLookupIPWithBrokenNameServer  20007735624   5004490730  -74.99%

benchmark                                 old allocs   new allocs    delta
BenchmarkGoLookupIP                              287          288    0.35%
BenchmarkGoLookupIPNoSuchHost                    204          102  -50.00%
BenchmarkGoLookupIPWithBrokenNameServer          410          358  -12.68%

benchmark                                  old bytes    new bytes    delta
BenchmarkGoLookupIP                            13181        13271    0.68%
BenchmarkGoLookupIPNoSuchHost                  17260         8714  -49.51%
BenchmarkGoLookupIPWithBrokenNameServer        28160        22432  -20.34%

LGTM=mikioh.mikioh
R=golang-codereviews, mikioh.mikioh, bradfitz, josharian, abursavich
CC=golang-codereviews
https://golang.org/cl/128820043
This issue was closed.
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