Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 7 Sep 2000 02:28:50 +0200 (CEST)
From:      Marc Schneiders <marc@oldserver.demon.nl>
To:        freebsd-advocacy@freebsd.org
Subject:   Re: [THTTPD] thttpd - reach file open limit of 4096 (fwd)
Message-ID:  <Pine.BSF.4.21.0009070221240.4396-100000@unclad.freebeastie.org>

next in thread | raw e-mail | index | archive | help
The message below (from the thttpd mailing list) indicates that Apache
is not the only webserver to favour FreeBSD. Especially the comment on
Linux is, ehum, interesting.

For those who don't know: thttpd does not have all the special
features that apache has. But it is much and much nicer on CPU and
memory. It is smaller. Quite a few large sites seem to run it as an
images server. Others use it for everything. It also does throttling,
which I will not try to explain.

You can compile in some modules, PHP for sure. Haven't looked at
others.

The latest version is in the ports. 

-- Marc Schneiders --- marc@venster.nl ---
marc@schneiders.org

FreeBSD unclad.freebeastie.org 5.0-CURRENT (SMP)
NetBSD vax.freebeastie.org 1.4Y

---------- Forwarded message ----------
Date: Tue, 05 Sep 2000 23:36:12 -0700
From: Jef Poskanzer <jef@acme.com>
To: thttpd@bomb.acme.com
Subject: Re: [THTTPD] thttpd - reach file open limit of 4096

>I have some HEAVY linux (redhat) servers..
>each one serving 4-7Mbits of 20-40k images..
>(I would like to push them to 20Mbits each)

That's only ~100 hits/sec, ~10 million/day.  Not that huge.

Just last week on this list we learned that thttpd on Linux runs into
this system-wide open file limit because Linux keeps an open file handle
for mmapped data.  Even though thttpd closes the file handle, the
kernel keeps it open.  That's pretty broken, but what are ya gonna do.

So, my suggestions:

1) Switch to FreeBSD.  Seriously, you won't regret it.  For major web
serving, it just kicks Linux's ass in every way.

2) If you're not willing to do that, then try recompiling thttpd
with the following line inserted towards the front of mmc.c:
    #undef HAVE_MMAP
This will make it use malloc instead of mmap, so it will be somewhat
slower but there's no chance of kernel files left open.  Let me know
if that fixes it, and I'll add the suggestion to the thttpd notes page.
---
Jef

         Jef Poskanzer  jef@acme.com  http://www.acme.com/jef/



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




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