From owner-freebsd-questions Thu Nov 1 14:30:53 2001 Delivered-To: freebsd-questions@freebsd.org Received: from leon.amaretti.net (leon.amaretti.net [195.224.53.47]) by hub.freebsd.org (Postfix) with ESMTP id 2272637B406 for ; Thu, 1 Nov 2001 14:30:49 -0800 (PST) Received: from pc-62-30-126-16-cr.blueyonder.co.uk ([62.30.126.16] helo=globalnet.co.uk) by leon.amaretti.net with esmtp (Exim 3.16 #1) id 15zQJ4-000Ch6-00 for freebsd-questions@freebsd.org; Thu, 01 Nov 2001 22:27:26 +0000 Message-ID: <3BE1CD17.57006E87@globalnet.co.uk> Date: Thu, 01 Nov 2001 22:30:47 +0000 From: John Ekins Reply-To: jre@globalnet.co.uk X-Mailer: Mozilla 4.76 [en] (X11; U; FreeBSD 4.4-RELEASE i386) X-Accept-Language: en-GB, en MIME-Version: 1.0 To: freebsd-questions@freebsd.org Subject: thttpd with php on FreeBSD compared with Linux Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello, I believe this is the right list for this sort of question, other I apologise and am happy to be directed elsewhere. I am comparing FreeBSD with Linux for running thttpd with php. The test server is a dual processor PIII 550MHz with 512MB RAM. The FreeBSD version is 4.4 Release (with SMP kernel) and soft updates enabled, the Linux version Redhat 7.2 (SMP) with ext3. The page I'm testing just contains which will be familiar to anyone who runs php. I used ab (ab -n 5000 -c 10 http://spooky/) which comes with Apache to do the test and here's what I saw: FreeBSD: Finished 5000 requests Server Software: Server Hostname: spooky Server Port: 80 Document Path: / Document Length: 32589 bytes Concurrency Level: 10 Time taken for tests: 104.921 seconds Complete requests: 5000 Failed requests: 0 Broken pipe errors: 0 Total transferred: 163200000 bytes HTML transferred: 162945000 bytes Requests per second: 47.65 [#/sec] (mean) Time per request: 209.84 [ms] (mean) Time per request: 20.98 [ms] (mean, across all concurrent requests) Transfer rate: 1555.46 [Kbytes/sec] received ----- Linux: Finished 5000 requests Server Software: Server Hostname: spooky Server Port: 80 Document Path: / Document Length: 31535 bytes Concurrency Level: 10 Time taken for tests: 62.436 seconds Complete requests: 5000 Failed requests: 0 Broken pipe errors: 0 Total transferred: 157930000 bytes HTML transferred: 157675000 bytes Requests per second: 80.08 [#/sec] (mean) Time per request: 124.87 [ms] (mean) Time per request: 12.49 [ms] (mean, across all concurrent requests) Transfer rate: 2529.47 [Kbytes/sec] received ----- That is quite some difference. The file system shouldn't have much impact, and thttpd is single threaded, single process so SMP shouldn't make any difference as I far as I know. Can anyone offer comments as to why there is such a big difference, and suggestions on how to improve this? Thanks, John. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message