Path: utzoo!news-server.csri.toronto.edu!rutgers!usc!snorkelwacker.mit.edu!bloom-beacon!dont-send-mail-to-path-lines From: mouse@lightning.mcrcim.mcgill.EDU (der Mouse) Newsgroups: comp.windows.x Subject: Re: MAX_CLIENTS limit Message-ID: <9103090405.AA24637@lightning.McRCIM.McGill.EDU> Date: 9 Mar 91 04:05:53 GMT Sender: daemon@athena.mit.edu (Mr Background) Organization: The Internet Lines: 34 > Can anyone tell me where the maximum number of clients allowed is > defined? As someone else already noted, it's the server that's doing this (as would have to be the case); in the case of the MIT server, it does a getdtablesize() when it starts up and starts refusing new clients when it's within one or two of running out. > I currently have 18 (on a Sun 3/50 - os4.1 12Mb X11R4 twm) and on > trying to open number 19 this happens: The *server* is running under 4.1? Something weird is wrong then; 4.1 by default has the descriptor limit set to 64, I believe. You should be able to connect about 55 clients before it starts losing. Your symptom looks more like what I'd expect from a server running under release 3.5. As to what can be done about it, besides switching to an OS that allows more file descriptors per process.... I hacked on the server so that it can fork a multiplexor subprocess to alleviate this problem. This raises the effective maximum to about 30. I could make it do multiple multiplexors, but have never felt any need; I've never run out of clients since. I do not have these changes in the form of distributable diffs. If you want to take your chances with the raw code, they should be available for ftp from 132.206.1.1, in X/myX/X11R4/server/os/4.2bsd/ (you want to look at the MUX_CONN compile-time option.) der Mouse old: mcgill-vision!mouse new: mouse@larry.mcrcim.mcgill.edu