So which is faster, Apache 1.3.x or Apache 2.0.x? - DFWstangs Forums
 
LinkBack Thread Tools Display Modes
post #1 of 1 (permalink) Old 02-12-2005, 10:33 AM Thread Starter
\(_o)/
 
AbecX's Avatar
 
Join Date: Nov 2001
Location: Las Colinas
Posts: 25,373
So which is faster, Apache 1.3.x or Apache 2.0.x?

So as not to tamper any results, I ran the http test from my redhat box at work agasint my colo box. I setup apache1 to run @ abecx.net:8080 ( loads the dfwls1 site ) and apache2 running on dfwls1.com:80. I compiled apache1 with dso support, then compiled in php.

I compiled php using the following commmands, I ran make clean ; make distclean to make sure no previous settings got in teh way.

I took these from phpinfo(); on both sites to verify that each site was using the correct php setup:

Apache1 1.3.33:
httpd: ./configure --prefix=/usr/local/apache --enable-module=rewrite --enable-shared=rewrite

php: './configure' '--with-apxs=/usr/local/apache/bin/apxs'
'--with-gd' '--with-zlib-dir=/usr/include' '--with-jpeg'
'--with-jpeg-dir=/usr/lib'


Apache2 2.0.52:
httpd: ./configure --prefix=/usr/local/apache2

php: './configure' '--with-apxs2=/usr/local/apache2/bin/apxs'
'--with-gd' '--with-zlib-dir=/usr/include' '--with-jpeg'
'--with-jpeg-dir=/usr/lib'




I used a page that had a healthy dose of php and mysql content to run the webserver tests. The pages also output in gzip format.


Web Server Content:

Results: Apache 1 is faster at generating php content.

A1: Average Time: 0.169 ms
Page generated in 0.17251396 seconds (80.89% PHP - 19.11% MySQL) with 19 queries.
Page generated in 0.16948390 seconds (80.48% PHP - 19.52% MySQL) with 19 queries.
Page generated in 0.17486000 seconds (81.52% PHP - 18.48% MySQL) with 19 queries.
Page generated in 0.16796803 seconds (80.91% PHP - 19.09% MySQL) with 19 queries.
Page generated in 0.16655111 seconds (80.17% PHP - 19.83% MySQL) with 19 queries.

A2: Average Time: .201 ms
Page generated in 0.19330096 seconds (74.62% PHP - 25.38% MySQL) with 43 queries.
Page generated in 0.22861004 seconds (80.14% PHP - 19.86% MySQL) with 43 queries.
Page generated in 0.19704008 seconds (75.71% PHP - 24.29% MySQL) with 43 queries.
Page generated in 0.19964790 seconds (74.23% PHP - 25.77% MySQL) with 43 queries.
Page generated in 0.18974495 seconds (74.75% PHP - 25.25% MySQL) with 43 queries.




The test page for tcp connection has a good mixture of random php code, mysql calls, and also outputs content in gzip format. I ran a test that would do 2,000 total connections with 50 new connections attempting to connect per second.

TCP connection:

Results: Apache 2 is faster with opening and replying with to tcp connection requests.

Now, rather then just pasting you the raw results, I'll go over each of the major points of the test.

Apache1:
This is the total time it took to run all requests
a1- Total Time: 39.992s - 2000 Requests 2000 Replies
a2- Total Time: 29.993s - 2000 Requests 2000 Replies

This shows how long it took from sending the request to get a reply back from the web server
a1- Reply time [ms]: response 5.4
a2- Reply time [ms]: response 5.4

This shows how long it took for each http request to be compelted:
a1- Connection time [ms]: min 11.4 avg 12.6 max 41.3 median 12.5 stddev 1.6
a2- Connection time [ms]: min 11.2 avg 12.3 max 35.1 median 11.5 stddev 1.3


#----------#
# Raw Data #
#----------#

Apache 1 w/ DSO support using php 4.3.10:
Maximum connect burst length: 1

Total: connections 2000 requests 2000 replies 2000 test-duration 39.992s

Connection rate: 50.0 conn/s (20.0 ms/conn, <=3 concurrent connections) Connection time [ms]: min 11.4 avg 12.6 max 41.3 median 12.5 stddev 1.6 Connection time [ms]: connect 3.4 Connection length [replies/conn]: 1.000

Request rate: 50.0 req/s (20.0 ms/req)
Request size [B]: 60.0

Reply rate [replies/s]: min 50.0 avg 50.0 max 50.0 stddev 0.0 (7
samples)
Reply time [ms]: response 5.4 transfer 3.8 Reply size [B]: header 176.0 content 5978.0 footer 2.0 (total 6156.0) Reply status: 1xx=0 2xx=2000 3xx=0 4xx=0 5xx=0

CPU time [s]: user 14.76 system 24.54 (user 36.9% system 61.4% total
98.3%)
Net I/O: 303.5 KB/s (2.5*10^6 bps)

Errors: total 0 client-timo 0 socket-timo 0 connrefused 0 connreset 0
Errors: fd-unavail 0 addrunavail 0 ftab-full 0 other 0

--------------------------------------------------------------------------

Apache2 using php 4.3.10
Maximum connect burst length: 1

Total: connections 2000 requests 2000 replies 2000 test-duration 39.993s

Connection rate: 50.0 conn/s (20.0 ms/conn, <=2 concurrent connections) Connection time [ms]: min 11.2 avg 12.3 max 35.1 median 11.5 stddev 1.3 Connection time [ms]: connect 3.1 Connection length [replies/conn]: 1.000

Request rate: 50.0 req/s (20.0 ms/req)
Request size [B]: 65.0

Reply rate [replies/s]: min 50.0 avg 50.0 max 50.0 stddev 0.0 (7
samples)
Reply time [ms]: response 5.4 transfer 3.7 Reply size [B]: header 190.0 content 5978.0 footer 0.0 (total 6168.0) Reply status: 1xx=0 2xx=2000 3xx=0 4xx=0 5xx=0

CPU time [s]: user 13.83 system 24.87 (user 34.6% system 62.2% total
96.8%)
Net I/O: 304.4 KB/s (2.5*10^6 bps)

Errors: total 0 client-timo 0 socket-timo 0 connrefused 0 connreset 0
Errors: fd-unavail 0 addrunavail 0 ftab-full 0 other 0

AbecX is offline  
Sponsored Links
Advertisement
 
Reply

Bookmarks

Quick Reply
Message:
Options

Register Now



In order to be able to post messages on the DFWstangs Forums forums, you must first register.
Please enter your desired user name, your email address and other required details in the form below.

User Name:
Password
Please enter a password for your user account. Note that passwords are case-sensitive.

Password:


Confirm Password:
Email Address
Please enter a valid email address for yourself.

Email Address:
OR

Log-in










Thread Tools
Show Printable Version Show Printable Version
Email this Page Email this Page
Display Modes
Linear Mode Linear Mode



Posting Rules  
You may post new threads
You may post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On

 
For the best viewing experience please update your browser to Google Chrome