[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: Limit number of TCP connections? (2)

On Sun, Mar 27, 2005 at 09:29:08AM -0800, Ron Davis wrote:
> "Fatal Error: Can't bind to because WSAENOBUFS. No buffer
> space available."
> According to:
> http://msdn.microsoft.com/library/en-us/winsock/winsock/windows_sockets_error_codes_2.asp?FRAME=true
> ...WSAENOBUFS means: "No buffer space available. An operation on a
> socket could not be performed because the system lacked sufficient
> buffer space or because a queue was full."
> I already changed this registry setting:
> HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\VxD\MSTCP
> changed: MaxConnections=100 to 256
> This doesn't help. 
> Win 98SE

Hi Ron,

Thanks for letting us know. This max-sockets problem has been
bugging us on Windows for a while now.

Here are some more hints:

When you set the registry entry for MaxConnections, did you set it as
a string or a dword? Apparently it has to be a string on 98/ME but a
DWORD on 95.

I'm also told you need to reboot after changing your registry entry.

It's possible that 256 is still too small for what you're trying to do;
have you tried, say 1024 or 2048? Note that this max is apparently shared
by every application running.

Looks like NT/XP/2000 is doing fine in terms of max connections, it's
just 95/98/98SE/ME that are based on DOS and intended for a single human
running only client apps. That probably helps explain why some win32
people have been doing fine: they're running NT.

Check out http://bugs.noreply.org/flyspray/index.php?do=details&id=98 for
more discussion of this bug and some other approaches for dealing with it.