[Info-vax] OpenVMS async I/O, fast vs. slow
Johnny Billquist
bqt at softjar.se
Sat Nov 4 07:01:42 EDT 2023
On 2023-11-04 01:35, Jake Hamby (Solid State Jake) wrote:
> There's a ~65535 limit on TCP sockets due to limited port numbers (including with IPv6), but you can have many different IP addresses, especially with IPv6. It looks like Linux servers can scale up to a few hundred thousand simultaneous connections. The "net.core.somaxconn" sysctl on my Ubuntu server is set to 4096, for comparison with the hardcoded SOMAXCONN value of 1024 in VMS's socket.h (but only if !defined _XOPEN_SOURCE_EXTENDED, which looks like a typo bug in the header file since it has an "#ifdef _XOPEN_SOURCE_EXTENDED" block embedded in the middle of the "if !defined" block.
Nitpick: There is actually no such limit. There is for UDP, but TCP
sockets are identified by the combination of local and remote addresses
and ports. So you can have an infinite number of socket, actually.
But you cannot listen on more than 64K sockets.
Basically, the same local port number can exist for any number of TCP
sockets. The most classical example: Think of your HTTP server. It
accepts connections on port 80. Any number of connections that come in
all use port 80. So there is only ever one local port number used. But
you can have tens of thousands of connections, potentially.
As for your testing - it's all interesting and fun. But I do worry a bit
that you are using solutions and paradigms designed on the available
tools and capabilities of Linux systems, and trying to make them perform
on VMS, while VMS might actually be able to do much better using other
solutions and paradigms.
But I noticied you at least are playing around with event flags and
ASTs, so you might be doing better than that.
Johnny
More information about the Info-vax
mailing list