Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 21 Jun 1997 03:26:48 -0600 (MDT)
From:      Marc Slemko <marcs@znep.com>
To:        sthaug@nethelp.no
Cc:        hackers@FreeBSD.ORG
Subject:   Re: gethostbyname() and fds >255 
Message-ID:  <Pine.BSF.3.95.970621031533.21696N-100000@alive.znep.com>
In-Reply-To: <23110.866883503@verdi.nethelp.no>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 21 Jun 1997 sthaug@nethelp.no wrote:

> > > For comparison, it works fine on BSD/OS 2.1.  Does it work in -current? 
> > 
> > It would appear to:
> > 
> > 396: host = 198.161.84.2 (valis.worldgate.com)
> > 397: host = 198.161.84.2 (valis.worldgate.com)
> > 398: host = 198.161.84.2 (valis.worldgate.com)
> > 399: host = 198.161.84.2 (valis.worldgate.com)
> > root@make-> uname -a
> > FreeBSD make.ican.net 3.0-CURRENT FreeBSD 3.0-CURRENT #0: Mon Jun 16 13:10:14 EDT 1997     jkh@make.ican.net:/a/local/src/sys/compile/MAKE  i386
> > 
> > It does indeed fall over on my 2.2-stable system.
> 
> The problem is in res_send(). In lib/libc/net/res_send.c line 577 in
> FreeBSD-current we have:

Sigh.  Yes, that's it.  I found it an hour or so ago looking through
things.  For a test, rebuilding libc with FD_SETSIZE=1024 then linking it
against my test program worked fine.  

That isn't very nice.  It appears the only reason it works in -current
(well, it will break at 1024 fds there...) is that FD_SETSIZE has been
increased.

Guess I'll have to double check what else was broken when FD_SETSIZE was
increased and make a patch for 2.2 that I can point people to.  My biggest
concern in this is that Apache 1.2 will not work with >~255 fds used for
logs without recompiling libc with a larger FD_SETSIZE. 






Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.95.970621031533.21696N-100000>