From owner-freebsd-questions Tue Apr 17 1:51:28 2001 Delivered-To: freebsd-questions@freebsd.org Received: from mta5.snfc21.pbi.net (mta5.snfc21.pbi.net [206.13.28.241]) by hub.freebsd.org (Postfix) with ESMTP id 918CA37B43F for ; Tue, 17 Apr 2001 01:51:24 -0700 (PDT) (envelope-from john@timogen.com) Received: from timogen.com ([64.166.85.192]) by mta5.snfc21.pbi.net (Sun Internet Mail Server sims.3.5.2000.01.05.12.18.p9) with ESMTP id <0GBX007Y8HX9GX@mta5.snfc21.pbi.net> for questions@FreeBSD.ORG; Tue, 17 Apr 2001 01:51:10 -0700 (PDT) Date: Tue, 17 Apr 2001 01:54:25 -0700 From: John Calderon Subject: Re: request for 'too many open files' To: Willie Kim Cc: questions@FreeBSD.ORG, oscars@mail.utexas.edu Reply-To: john@timogen.com Message-id: <3ADC04C1.F3BB25E4@timogen.com> MIME-version: 1.0 X-Mailer: Mozilla 4.75 [en] (Windows NT 5.0; U) Content-type: text/html; charset=us-ascii Content-transfer-encoding: 7bit X-Accept-Language: en References: Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG umm your reply  looks funny but this guy has the same question ( more or less )
I just copied and pasted
I think ulimit will set your soft limit and FD_SETSIZE will change the hard/kernel limit for BSD 3.0

don't know for 4.0
but usually there are work arrounds instead of increasing this. like usually spliting open files and opening multiple servers to do part of the dns work like
one dns server to handle internal addresses, one for reverse ips, one for regular dns.

hope this helps
john

Subject:
        Maxusers and max open files
   Date:
        Mon, 09 Apr 2001 13:22:59 -0500
   From:
        Oscar Ricardo Silva <oscars@mail.utexas.edu>
     To:
        questions@FreeBSD.ORG
 
 
 

I know that the max number of open files is related to the maxusers number
in the kernel config file.  /usr/src/sys/conf/param.c indicates:

#define NPROC (20 + 16 * MAXUSERS)
#ifndef MAXFILES
#define MAXFILES (NPROC*2)
#endif
int     maxproc = NPROC;                        /* maximum # of processes */
int     maxprocperuid = NPROC-1;                /* maximum # of processes
per user */
int     maxfiles = MAXFILES;                    /* system wide open files
limit */
int     maxfilesperproc = MAXFILES;             /* per-process open files
limit */

So, that means that if I want to raise the max number of open files, I need
to change MAXUSERS in the kernel and recompile.  At the same time, I don't
want to place to much overhead on the machine to where it becomes unusable.

Any thoughts on what the usable limit is for MAXUSERS?  The machine I'm
asking about is currently running FreeBSD 4.0. acting as a dns cache server
for our campus (approx. 50,000 hosts) and is running djbdns-1.05.  We had
problems this weekend where the dnscache portion of the djbdns package
reported that it could not open more files.  I would like to raise the
number (currently, max number of open files set to 4136, maxusers 128) but
don't want to suffer to much of a performance hit.

I've tried looking for more information on open files and max number of
open files but have only found one or two sentences in the FreeBSD
handbook.  Any other resources for this kind of information?  I found the
piece of code above but admit that I'm not a programmer.

Any information would be extremely appreciated.
 

Oscar
 

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message

Willie Kim wrote:

Hello there!...
I know this is a kind of danky to ask for it..but i need these problems to be solved for our company though...so, do me a favor, would u?....i wish you'd help me out for these requestions even though it's sort of late in different time between your country and my country..
 lately my company is participating in BMT(Benchmarking Test) for the cache, nas project, and so forth..but we got the some problems during testing..
actually we're using the PolyMix-3  from the FreeBDS in this time but some errors came up consecutively during the test like it said....
>1023/1023(267) unsupported HTTP status code...
>whenever we use the FreeBSD to increase the numbers with polymix-3, I am getting  >a lot of "Too many open files" error messages from Connection.con  like that..
>too many open files ....like that
besides we're using our domestic hardware brand which is Sambo CPU...and also we're using the  CacheFlow and other products...we thought the reasons this wasn't working properly was the environment of networking area....like memory part, ICE, or something...
anyway, we'll figure out these problems compromised with other company ...because other competitions work on this problem too...
anyway, if you have some knowledgements about these problem, would you be willing to send email back to me asap...I'll be looking forwarding to hearing from you soon..
well, I'll really appreciate as you can respond my requestions..
Have a great day and take care! Thanks, sir. Willie H. Kim.
To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message