Networking Forums

Networking Forums > Computer Networking > Linux Networking > extremely long connect times

Reply
Thread Tools Display Modes

extremely long connect times

 
 
tomg_tt
Guest
Posts: n/a

 
      03-19-2007, 05:37 PM
I have a client application that needs to handle many connections to
remote servers. I have a thread handler to deal with the multiple
calls to connect() so that the main system can continue working during
this (long) system call. During load testing I find that about 8 to
10 percent of the calls to connect() have not returned after 30
seconds (at which time I assume they aren't going to complete and I
close the socket). There are, however, other connections to the same
host that are initiated and complete in that time frame. When I break
into the application and look at the backtrace, everything looks
'normal' (there is still a call to connect in the trace), and looking
at netstat says that the socket is in the SYN_SENT state.

Is there any way I can diagnose why so many calls to connect() don't
seem to complete? Am I being unreasonable that I should expect every
call to complete? I am testing with a locally connected server to
remove the possible vagaries of the internet.

TIA

Tom

 
Reply With Quote
 
 
 
 
Rick Jones
Guest
Posts: n/a

 
      03-19-2007, 05:53 PM
What sort of connection churn rate between any pair of IPs are we
talking about here?

If the connection rate between two IPs, a well-known port and a set of
client ports happens to go faster than:

sizeof(clientportpsace)/lengthof(TIME_WAIT) you can have a situation
where a client attempts to establish a new TCP connection while an old
connection of the same name remains in TIME_WAIT.

rick jones
--
oxymoron n, commuter in a gas-guzzling luxury SUV with an American flag
these opinions are mine, all mine; HP might not want them anyway...
feel free to post, OR email to rick.jones2 in hp.com but NOT BOTH...
 
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Very long ping times and slow downloads on 1MB ADSL Martin Underwood Broadband 4 01-31-2007 03:47 PM
adhoc causes reboot to take about 3 times as long Charlie Wireless Networks 0 07-08-2006 12:24 AM
Long login times into 2k domain Hescominsoon Windows Networking 1 11-24-2005 12:23 PM
LONG VPN reconnect times (plus VPN VERY slow) - PLEASE HELP ch Windows Networking 1 10-15-2004 08:49 AM
Logon Times long with XP, Short with NT Mark Windows Networking 2 07-13-2004 11:13 PM



1 2 3 4 5 6 7 8 9 10 11