evristzam / ndt

Automatically exported from code.google.com/p/ndt
Other
0 stars 0 forks source link

Running ndt web100srv without dns/ etc/hosts entries take an unnecessarily long time - tests sometimes fail #73

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.Run ndt without a dns server or any entries in /etc/hosts for client or 
0.0.0.0
2.Connect with a client and you will see pauses between tests
3.The accumulated delay can be be enough to make all the test timeout and fail 
completely.

What is the expected output? What do you see instead?
Tests run fully and completely without delays/ timeouts.
Client failure upon timeout looks like this

[root@machine3 ~]# time web100clt -n 172.20.1.2 -ll Testing network path for configuration and performance problems -- Using IPv4 address Checking for Middleboxes . . . . . . . . . . . . . . . . . . Done checking for firewalls . . . . . . . . . . . . . . . . . . . Done running 10s outbound test (client to server) . . . . . 941.55 Mb/s running 10s inbound test (server to client) . . . . . . Protocol error - missed text message! S2C throughput test FAILED! Protocol error - missed prepare message! META test FAILED! Protocol error - expected results! got '', msgtype=2

real 2m8.677s user 0m0.392s sys 0m3.194s


As opposed to what it should look like

[root@machine3 ~]# time web100clt -n 172.20.1.2 -ll Testing network path for configuration and performance problems -- Using IPv4 address Checking for Middleboxes . . . . . . . . . . . . . . . . . . Done checking for firewalls . . . . . . . . . . . . . . . . . . . Done running 10s outbound test (client to server) . . . . . 941.55 Mb/s running 10s inbound test (server to client) . . . . . . 922.28 Mb/s sending meta information to server . . . . . Done

... results here ...

real 0m32.601s user 0m0.858s sys 0m5.643s


Even running with the clients IP in /etc/hosts but not 0.0.0.0 takes about 50 
seconds for a test to complete successfully.

What version of the product are you using? On what operating system?
Debian wheezy Linux, ndt build based on latest svn r796.

Please provide any additional information below.
This is caused by the I2util library looking up every(?) connection with 
getnameinfo, running server on debian wheezy I experience a 5 second timeout 
before missing entries fall back to IP address.

The quick fix for this is to add the NI_NUMERICSERV flag to the I2Util 
getnameinfo call. I don't feel that resolving hostnames is that important 
especially as most of the time they are not being printed to the user.

Attached are server output running debug level 6 with times to complete the 
_I2AddrSetNodePort() (which does the getnameinfo call) function logged. i2MONO 
diff: is the real time - i2CPU diff: is CPU time - NAME IS: is the name it 
resolved to.

Original issue reported on code.google.com by rsanger...@gmail.com on 16 Jan 2013 at 12:05

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by jslawin...@soldevelo.com on 25 Jun 2014 at 8:23