[Standards] s2s and gracelessly broken streams
Chris Mullins
chris.mullins at coversant.net
Tue Apr 3 11:50:16 CDT 2007
Dave Cridland Wrote:
> I'm curious as to where you get these figures from. Aside
> from anything else, your 100k figure appears to contradict
> your 65k figure above.
Hours and Hours of network testing to figure out the practical limits of
"how many connections can a server handle". We're lucky enough to have
partners (HP, AMD) who give us access to labs with very big machines to
test on. We've been able to test on a wide variety of hardware (x86,
x64, IA64) and Windows versions. Some of our tests were pure socket
tests, other were using our Server.
The 100k figure requires additional IP Addresses.
All the numbers that I've mentioned are for Windows - the various Unix
flavors are outside my area of knowledge.
> Assuming around a 60k limit because of memory limitations
> on 32-bit architectures implies that each TCP connection
> uses something approaching 30kBytes, which seems,
> somehow, rather high to me.
It depends on a number of factors. For example, in Windows (x86), the
limitations are imposed by the size of the Non-Pages Memory Pool deep in
the Windows Kernel. Each async socket that's opened reserves a little
bit of this memory, a when this memory is exhausted, you're out of luck.
You can get around this by NOT doing async sockets, but this has other
limitations and drawbacks.
These numbers also change depending on hardware - many new network cards
support TCP Offloading and the new TCP Chimney stuff:
http://www.microsoft.com/whdc/device/network/TCP_Chimney.mspx
> It's quite practical to have every outgoing
> connection use the same source port number
> on the same source IP address - some
> protocols, like FTP, even mandate this.
I don't know as I've ever done this, but you're right - it's certainly
possible.
In all the network programming I've been a part of, letting the O/S
choose the outgoing port has been what we've done. I sometimes specify
the local address from which to send, but even then I try to let the O/S
worry about this, as it has a lot more knowledge (route tables, etc)
than I've got.
Many high level programming Interfaces won't let you do this, so I'm not
sure how practical it is.
--
Chris Mullins
More information about the Standards
mailing list