ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

How fast is yout HelloWorld.html ?

May 03, 2010 6:27pm

Subscribe [6]
  • #1 / May 03, 2010 6:27pm

    Mareshal

    230 posts

    Because here(http://ellislab.com/forums/viewthread/154045/) with WanWizard, tried to find out which HelloWorld.html is faster I propose a simple test.

    1. Create a simple HTML page which will contain only “Hello CodeIgniter”.
    2. Save it on your local webserver.
    3. Open your Console(Windows) or Terminal(Linux).

    Because I have XAMPP and Windows I have this path.

    D:\xampp\apache\bin\

    4. Once you got here type this command

    ab -c 100 -n 10000 <a href="http://localhost/hello.html">http://localhost/hello.html</a>

    5. Paste here the results like this, ONLY THIS PART

    Concurrency Level:      100
    Time taken for tests:   7.209 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Total transferred:      3910000 bytes
    HTML transferred:       120000 bytes
    Requests per second:    1387.08 [#/sec] (mean)
    Time per request:       72.094 [ms] (mean)
    Time per request:       0.721 [ms] (mean, across all concurrent requests)
    Transfer rate:          529.64 [Kbytes/sec] received

    I got 1387 requests per second in 7.2 seconds. Can you get more than this?

    Let’s see.

  • #2 / May 03, 2010 7:07pm

    WanWizard

    4475 posts

    I wonder if this excercise is really useful.

    My fedora development environment ships by default with an httpd.conf for use in a desktop environment. That default produces:

    Concurrency Level:      100
    Time taken for tests:   80.781 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Total transferred:      3110311 bytes
    HTML transferred:       180018 bytes
    Requests per second:    123.79 [#/sec] (mean)
    Time per request:       807.808 [ms] (mean)
    Time per request:       8.078 [ms] (mean, across all concurrent requests)
    Transfer rate:          37.60 [Kbytes/sec] received

    However, if I copy the httpd.conf from one of my virtual machines that I use for staging (running CentOS) to my laptop, my fedora laptop produces:

    Concurrency Level:      100
    Time taken for tests:   3.768 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Total transferred:      3110933 bytes
    HTML transferred:       180054 bytes
    Requests per second:    2653.67 [#/sec] (mean)
    Time per request:       37.684 [ms] (mean)
    Time per request:       0.377 [ms] (mean, across all concurrent requests)
    Transfer rate:          806.19 [Kbytes/sec] received

    All a matter of how you tune Apache…

  • #3 / May 03, 2010 7:10pm

    Mareshal

    230 posts

    I’ll get back tomorrow with another bench. I only got default xampp zip, no tuning, clean. 😛

  • #4 / May 03, 2010 7:32pm

    n0xie

    1381 posts

    Learn to config servers.

    Server Software:        Apache/2.2.12
    Server Hostname:        localhost
    Server Port:            80
    
    Document Path:          /hello.html
    Document Length:        283 bytes
    
    Concurrency Level:      100
    Time taken for tests:   0.576 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Non-2xx responses:      10002
    Total transferred:      4860972 bytes
    HTML transferred:       2830566 bytes
    Requests per second:    17347.74 [#/sec] (mean)
    Time per request:       5.764 [ms] (mean)
    Time per request:       0.058 [ms] (mean, across all concurrent requests)
    Transfer rate:          8235.05 [Kbytes/sec] received
  • #5 / May 03, 2010 7:36pm

    n0xie

    1381 posts

    And now using CodeIgniter:

    Server Software:        Apache/2.2.12
    Server Hostname:        testsite.tld
    Server Port:            80
    
    Document Path:          /hello
    Document Length:        281 bytes
    
    Concurrency Level:      100
    Time taken for tests:   0.740 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Non-2xx responses:      10000
    Total transferred:      4840000 bytes
    HTML transferred:       2810000 bytes
    Requests per second:    13508.75 [#/sec] (mean)
    Time per request:       7.403 [ms] (mean)
    Time per request:       0.074 [ms] (mean, across all concurrent requests)
    Transfer rate:          6384.99 [Kbytes/sec] received
  • #6 / May 03, 2010 7:45pm

    elambiguo

    22 posts

    Mine….

    Server Software:      Apache/2.2.14<br /> Server Hostname:      localhost<br /> Server Port:        80</p> <p>Document Path:      /index.html<br /> Document Length:      44 bytes</p> <p>Concurrency Level:    100<br /> Time taken for tests:  8.720 seconds<br /> Complete requests:    10000<br /> Failed requests:      0<br /> Write errors:        0<br /> Total transferred:    4230000 bytes<br /> HTML transferred:    440000 bytes<br /> Requests per second:  1146.73 [#/sec] (mean)<br /> Time per request:    87.204 [ms] (mean)<br /> Time per request:    0.872 [ms] (mean, across all concurrent requests)<br /> Transfer rate:      473.70 [Kbytes/sec] received</p> <p>Connection Times (ms)<br />           min mean[+/-sd] median   max<br /> Connect:      0   0   2.1     0     16<br /> Processing:    0   86 90.7   78   889<br /> Waiting:      0   69 22.3   78   655<br /> Total:      0   87 90.7   78   889</p> <p>Percentage of the requests served within a certain time (ms)<br />   50%    78<br />   66%    78<br />   75%    78<br />   80%    78<br />   90%    94<br />   95%  109<br />   98%  437<br />   99%  562<br /> 100%  889 (longest request)

    Laptop Compaq CQ61-230ss Pentium Dual Core T4200 4GB Ram
    Xampp 1.7.3
    Windows 7 Home Premium 32 Bits

  • #7 / May 04, 2010 12:36am

    Mareshal

    230 posts

    WOW n0xie…what is your config? and really, how you did it?

  • #8 / May 04, 2010 6:27am

    steelaz

    252 posts

    Default WAMP setup on Windows 7

    Concurrency Level:      100
    Time taken for tests:   3.089 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Total transferred:      2740000 bytes
    HTML transferred:       50000 bytes
    Requests per second:    3237.50 [#/sec] (mean)
    Time per request:       30.888 [ms] (mean)
    Time per request:       0.309 [ms] (mean, across all concurrent requests)
    Transfer rate:          866.28 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0    0   1.6      0      16
    Processing:    16   30   7.2     31      78
    Waiting:        0   25   8.5     31      78
    Total:         16   31   7.1     31      78
    
    Percentage of the requests served within a certain time (ms)
      50%     31
      66%     31
      75%     31
      80%     31
      90%     31
      95%     31
      98%     47
      99%     62
     100%     78 (longest request)
  • #9 / May 05, 2010 2:14am

    kilishan

    183 posts

    Here’s mine. Default MAMP install (PHP 5.2.11) on an iMac (2Ghz Core 2 Duo) with 3GB ram.

    Concurrency Level:      10
    Time taken for tests:   0.020 seconds
    Complete requests:      60
    Failed requests:        0
    Write errors:           0
    Total transferred:      14762 bytes
    HTML transferred:       732 bytes
    Requests per second:    2965.89 [#/sec] (mean)
    Time per request:       3.372 [ms] (mean)
    Time per request:       0.337 [ms] (mean, across all concurrent requests)
    Transfer rate:          712.61 [Kbytes/sec] received

    And n0xie…would definitely love to hear your tips about server tuning!

  • #10 / May 06, 2010 6:03pm

    Yorick Peterse

    537 posts

    Cheated using my live server instead of my local one:

    Benchmarking localhost (be patient)
    Completed 1000 requests
    Completed 2000 requests
    Completed 3000 requests
    Completed 4000 requests
    Completed 5000 requests
    Completed 6000 requests
    Completed 7000 requests
    Completed 8000 requests
    Completed 9000 requests
    Completed 10000 requests
    Finished 10000 requests
    
    
    Server Software:        nginx/0.7.64
    Server Hostname:        localhost
    Server Port:            80
    
    Document Path:          /hello.html
    Document Length:        18 bytes
    
    Concurrency Level:      10
    Time taken for tests:   1.096 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Total transferred:      3000300 bytes
    HTML transferred:       180018 bytes
    Requests per second:    9121.94 [#/sec] (mean)
    Time per request:       1.096 [ms] (mean)
    Time per request:       0.110 [ms] (mean, across all concurrent requests)
    Transfer rate:          2672.71 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0    0   0.1      0       1
    Processing:     0    1   0.1      1       3
    Waiting:        0    1   0.1      1       2
    Total:          1    1   0.1      1       3
    
    Percentage of the requests served within a certain time (ms)
      50%      1
      66%      1
      75%      1
      80%      1
      90%      1
      95%      1
      98%      1
      99%      1
     100%      3 (longest request)

    Local server:

    Benchmarking localhost (be patient)
    Completed 1000 requests
    Completed 2000 requests
    Completed 3000 requests
    Completed 4000 requests
    Completed 5000 requests
    Completed 6000 requests
    Completed 7000 requests
    Completed 8000 requests
    Completed 9000 requests
    Completed 10000 requests
    Finished 10000 requests
    
    
    Server Software:        Apache
    Server Hostname:        localhost
    Server Port:            80
    
    Document Path:          /hello.html
    Document Length:        18 bytes
    
    Concurrency Level:      10
    Time taken for tests:   1.516 seconds
    Complete requests:      10000
    Failed requests:        0
    Write errors:           0
    Total transferred:      2500000 bytes
    HTML transferred:       180000 bytes
    Requests per second:    6595.97 [#/sec] (mean)
    Time per request:       1.516 [ms] (mean)
    Time per request:       0.152 [ms] (mean, across all concurrent requests)
    Transfer rate:          1610.34 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0    0   0.2      0       1
    Processing:     0    1   0.9      1      38
    Waiting:        0    1   0.9      1      38
    Total:          1    1   0.9      1      38
    
    Percentage of the requests served within a certain time (ms)
      50%      1
      66%      2
      75%      2
      80%      2
      90%      2
      95%      2
      98%      2
      99%      3
     100%     38 (longest request)
  • #11 / May 06, 2010 6:05pm

    Mareshal

    230 posts

    All of you have super computers?

  • #12 / May 06, 2010 6:08pm

    steelaz

    252 posts

    Core 2 Quad Q8300 @ 2.5 GHz, 8 GB RAM, running Windows 7 Ultimate 64-bit

  • #13 / May 06, 2010 6:09pm

    Yorick Peterse

    537 posts

    All of you have super computers?

    A good combination of software and configuration is more important. I could use Nginx to squeeze every single bit out of a small box and still make it pretty damn fast 😊

    By the way, my server config is a Dual core Xeon (I believe) running at 1.8Ghz (dedicated) with 1128MB RAM, of which most is used for buffers 😊

    Local config is a Core 2 Duo 2.8Ghz with 4Gb of RAM.

  • #14 / May 06, 2010 6:11pm

    Mareshal

    230 posts

    My i3 is a baby standing near a giant xeon 😊)

  • #15 / May 06, 2010 6:42pm

    n0xie

    1381 posts

    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    model name    : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz
    MemTotal: 12324028 kB
    
    Running stock Ubuntu with some minor Apache tweaks on SSD.

    This is my dev box mind you 😉

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases