Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 24 Apr 2007 10:47:26 +0300
From:      Cheffo <cheffo@FreeBSD-BG.org>
To:        Robert Watson <rwatson@FreeBSD.org>
Cc:        freebsd-performance@freebsd.org, Ivan Voras <ivoras@fer.hr>
Subject:   Re: apache httpd performance
Message-ID:  <462DB60E.90608@FreeBSD-BG.org>
In-Reply-To: <20070423233713.M58942@fledge.watson.org>
References:  <462A31A9.5080207@FreeBSD-BG.org> <f0e5lc$u4d$1@sea.gmane.org> <462B8898.5090306@FreeBSD-BG.org> <20070423233713.M58942@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Robert Watson wrote:
> 
> On Sun, 22 Apr 2007, Stefan Lambrev wrote:
> 
>> I'm using my laptop to run ab in both test, and 2 totally different 
>> servers :) That's why I do not pretend that the benchmark is done the 
>> right way.
>>
>> The linux host is with pentium 4 single core processor, The freebsd 
>> host is amd64 athlon 3200+ (2GHz) - single core too
>>
>> Both servers share same dns server(s), so I do not think that the DNS 
>> can be issue.
>>
>> I'm using 3com network card - 100mbps - xl.
>>
>> I'll test with accf_http and will report back. If there is a problem 
>> (as I'm still not sure that there is) I'll make more accurate 
>> benchmark and will try to find where is the problem (with your help) :)
> 
> If the hardware used for the servers and clients isn't identical between 
> the two tests, then the results are at best misleading.  In this case, 
> assuming I understand your hardware description correctly, the 
> significant differences in server hardware make any comparison utterly 
> meaningless.  We'd be better off ignoring the Linux results entirely and 
> simply try instead to optimize your FreeBSD performance.  If you want to 
> do side-by-side OS comparisons, you need to use the same hardware 
> configurations in an otherwise identical software configuration.
> 
> If this is 6.x, try setting net.isr.direct to 1.  If running threaded 
> apps, try using libthr instead of libpthread.  If using uniprocessor 
> hardware, make sure you are using a UP kernel rather than an SMP kernel.

I know this and I ignore totally results under linux :)

My big surprise was that CPU: AMD Athlon(tm) 64 Processor 3200+ 
(2002.57-MHz K8-class CPU) can't handle 100 concurrent requests normally 
e.g. the load on the servers goes very high, and the server does not 
respond very well during the test.

Just to be sure that linux do NOT outperforming freebsd :) I get pentium 
D dual core + 2x160GB sata HDDs, and gigabit intel (em) network card.

I installed linux ubuntu 7 on disk1 and freebsd 6.2 on disk2, and can 
confirm that with default settings freebsd outperforms linux:
35K request/30sec (freebsd) vs 34K requests/30sec (ubuntu).

What I noticed is that freebsd 6.2 comes very tunned and most 
recommended settings are already set.

And results are here:

FreeBSD shitler.cmotd.com 6.2-RELEASE FreeBSD 6.2-RELEASE #0: Mon Apr 23 
16:19:19 UTC 2007     root@shitler.mitler.org:/usr/obj/usr/src/sys/SMP  i386

Server Software:        Apache/1.3.37
Server Hostname:        192.168.2.16
Server Port:            80

Document Path:          /manual/
Document Length:        9364 bytes

Concurrency Level:      100
Time taken for tests:   30.000 seconds
Complete requests:      35289
Failed requests:        0
Broken pipe errors:     0
Total transferred:      345387971 bytes
HTML transferred:       330718551 bytes
Requests per second:    1176.30 [#/sec] (mean)
Time per request:       85.01 [ms] (mean)
Time per request:       0.85 [ms] (mean, across all concurrent requests)
Transfer rate:          11512.93 [Kbytes/sec] received


Linux shitler 2.6.20-15-generic #2 SMP Sun Apr 15 07:36:31 UTC 2007 i686 
GNU/Linux

Server Software:        Apache/1.3.34
Server Hostname:        192.168.2.13
Server Port:            80

Document Path:          /manual/
Document Length:        9364 bytes

Concurrency Level:      100
Time taken for tests:   30.035 seconds
Complete requests:      34162
Failed requests:        0
Broken pipe errors:     0
Total transferred:      335024120 bytes
HTML transferred:       320109432 bytes
Requests per second:    1137.41 [#/sec] (mean)
Time per request:       87.92 [ms] (mean)
Time per request:       0.88 [ms] (mean, across all concurrent requests)
Transfer rate:          11154.46 [Kbytes/sec] received

I'll test with net.isr.direct=1, but I do not think I can get better 
results, because the bottle neck is my 100mbps switch :)

Next step will be to install centos (where I can install apache without 
problems as ubuntu have some problems and I was forced to use pre-build 
apache) , build custom kernel for freebsd, and I'll make tests on 
gigabit network.

Once I reach best results with both OSes, I'll make some charts with 
different concurrency :)

Thanks for the tips.



-- 

Best Wishes,
Stefan Lambrev
ICQ# 24134177



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?462DB60E.90608>