Litespeed vBulletin index.php benchmarks - Part 1

Discussion in 'LiteSpeed Cache' started by eva2000, Jan 25, 2011.

  1. eva2000

    eva2000 Member

    Just installed vB 3.8.6 PL1 test forum on test server to benchmark Litespeed v4.0.19. Only testing the front vB index.php page first.

    Results are very much bottlenecked by MariaDB 5.2.4 MySQL server connection unlike standalone test.php or test.txt static file testing already done.

    Summary
    • Litespeed again came out on top with least memory usage and serving up to 100,000 requests with 1,000 concurrency with no failed requests.
    • Nginx with php-fpm in TCP form came out in second place but had more failed requests as the concurrency and requests size increased. Update: Seems failed requests due to content length varying so not really failed requests see explanation here.
    • Nginx with php-fpm unix socket form for some reason couldn't even pass >5 concurrency level without php failing with 502 gateway error messages/upstream timeouts.
    • Apache kicked the bucket at 100,000 requests and cpu load was very high as was average memory usage.

    Apachebench


    [​IMG]

    Raw numbers here


    Server config
    ran Unixbench 5.1.2 as per http://www.webhostingtalk.com/showthread.php?t=924581 to see how it compares.

    • VirtualBox CentOS 5.5 64bit Guest
    • Xeon W3540 @3408Mhz (Assigned 2 cores only) - linux reports @3375Mhz
    • 16MB allocated GPU memory
    • 1GB out of 6GB DDR3-1550Mhz
    • 20GB out of 640GB Samsung SATAII

    Code:
    ========================================================================
       BYTE UNIX Benchmarks (Version 5.1.2)
    
       System: localhost.localdomain: GNU/Linux
       OS: GNU/Linux -- 2.6.18-194.32.1.el5 -- #1 SMP Wed Jan 5 17:52:25 EST 2011
       Machine: x86_64 (x86_64)
       Language: en_US.utf8 (charmap="UTF-8", collate="UTF-8")
       CPU 0: Intel(R) Xeon(R) CPU W3540 @ 2.93GHz (6750.1 bogomips)
              Hyper-Threading, x86-64, MMX, Physical Address Ext, SYSENTER/SYSEXIT, SYSCALL/SYSRET
       CPU 1: Intel(R) Xeon(R) CPU W3540 @ 2.93GHz (6733.8 bogomips)
              Hyper-Threading, x86-64, MMX, Physical Address Ext, SYSENTER/SYSEXIT, SYSCALL/SYSRET
       21:45:27 up  1:11,  2 users,  load average: 0.00, 0.01, 0.00; runlevel 5
    
    ------------------------------------------------------------------------
    Benchmark Run: Sun Jan 23 2011 21:45:27 - 22:09:32
    2 CPUs in system; running 1 parallel copy of tests
    
    Dhrystone 2 using register variables       19101079.5 lps   (10.0 s, 7 samples)
    Double-Precision Whetstone                     3771.0 MWIPS (10.0 s, 7 samples)
    Execl Throughput                               4394.2 lps   (30.0 s, 2 samples)
    Pipe Throughput                             1457951.0 lps   (10.0 s, 7 samples)
    Pipe-based Context Switching                  29373.4 lps   (10.0 s, 7 samples)
    Process Creation                              13113.2 lps   (30.0 s, 2 samples)
    Shell Scripts (1 concurrent)                   7997.6 lpm   (60.0 s, 2 samples)
    Shell Scripts (16 concurrent)                   901.5 lpm   (60.0 s, 2 samples)
    Shell Scripts (8 concurrent)                   1756.9 lpm   (60.0 s, 2 samples)
    System Call Overhead                        1211587.2 lps   (10.0 s, 7 samples)
    
    System Benchmarks Partial Index              BASELINE       RESULT    INDEX
    Dhrystone 2 using register variables         116700.0   19101079.5   1636.8
    Double-Precision Whetstone                       55.0       3771.0    685.6
    Execl Throughput                                 43.0       4394.2   1021.9
    Pipe Throughput                               12440.0    1457951.0   1172.0
    Pipe-based Context Switching                   4000.0      29373.4     73.4
    Process Creation                                126.0      13113.2   1040.7
    Shell Scripts (1 concurrent)                     42.4       7997.6   1886.2
    Shell Scripts (16 concurrent)                     ---        901.5      ---
    Shell Scripts (8 concurrent)                      6.0       1756.9   2928.1
    System Call Overhead                          15000.0    1211587.2    807.7
                                                                       ========
    System Benchmarks Index Score (Partial Only)                          916.9
    
    ------------------------------------------------------------------------
    Benchmark Run: Sun Jan 23 2011 22:09:32 - 22:33:38
    2 CPUs in system; running 2 parallel copies of tests
    
    Dhrystone 2 using register variables       37996013.0 lps   (10.0 s, 7 samples)
    Double-Precision Whetstone                     7678.6 MWIPS (9.7 s, 7 samples)
    Execl Throughput                               8655.7 lps   (29.9 s, 2 samples)
    Pipe Throughput                             2863704.1 lps   (10.0 s, 7 samples)
    Pipe-based Context Switching                 739539.5 lps   (10.0 s, 7 samples)
    Process Creation                              25690.5 lps   (30.0 s, 2 samples)
    Shell Scripts (1 concurrent)                  14271.1 lpm   (60.0 s, 2 samples)
    Shell Scripts (16 concurrent)                  1001.8 lpm   (60.1 s, 2 samples)
    Shell Scripts (8 concurrent)                   1990.0 lpm   (60.0 s, 2 samples)
    System Call Overhead                        2279039.9 lps   (10.0 s, 7 samples)
    
    System Benchmarks Partial Index              BASELINE       RESULT    INDEX
    Dhrystone 2 using register variables         116700.0   37996013.0   3255.9
    Double-Precision Whetstone                       55.0       7678.6   1396.1
    Execl Throughput                                 43.0       8655.7   2012.9
    Pipe Throughput                               12440.0    2863704.1   2302.0
    Pipe-based Context Switching                   4000.0     739539.5   1848.8
    Process Creation                                126.0      25690.5   2038.9
    Shell Scripts (1 concurrent)                     42.4      14271.1   3365.8
    Shell Scripts (16 concurrent)                     ---       1001.8      ---
    Shell Scripts (8 concurrent)                      6.0       1990.0   3316.7
    System Call Overhead                          15000.0    2279039.9   1519.4
                                                                       ========
    System Benchmarks Index Score (Partial Only)                         2226.9
    
    Last edited: Jan 27, 2011
  2. eva2000

    eva2000 Member

    With some help from Litespeed folks, got litespeed's inbuilt cache feature setup to work with vBulletin's boost/varnish plugin - basically just import/install product-boostv1.xml‎ on your vB 3.8.x or vB 4.0.x forums and setup Litespeed cache options in Litespeed admin console and drop in some vB specific .htaccess rewrite code and you're set.

    The speed boost for guest visitors is crazy - between >16x to 123x times faster in different apachebench config tests!

    Now to retest apachebench with above same settings for requests and concurrency with Litespeed inbuilt cache enabled resulted in Litespeed inbuilt cached tests being up to 721x times faster than Apache, or 91x times faster than Litespeed alone without the inbuilt cache enabled! :eek: Look at the cpu load for cached tests and no php memory usage at all :)

    [​IMG]

    Litespeed admin console cache policy and settings

    * need to create cache path directory /lscache

    Code:
    Cache Storage Settings
    
    Storage Path: /lscache
    Max Object Size: 262144
    
    Enable Cache:No
    Cache Request with Query String:Yes
    Cache Request with Cookie:Yes
    Cache Response with Cookie:Yes
    Ignore Request Cache-Control:Yes
    Ignore Response Cache-Control:Yes
    .htaccess used provided vB forum installed in domain/doc root

    Code:
    RewriteEngine on
    
    RewriteRule test.php - [E=Cache-Control:max-age=45]
    RewriteRule hello.php - [E=Cache-Control:max-age=45]
    
    #RewriteCond %{HTTP_HOST} !^www\.domain\.com$
    #RewriteRule /forum/(.*)$ http://www.domain.com/forum/$1 [R=301,L]
    
    
    RewriteCond %{HTTP_COOKIE} !zzimloggedin=yes
    RewriteCond %{HTTP_COOKIE} !zzuserid=
    RewriteCond %{HTTP_COOKIE} !zzpassword=
    RewriteCond %{REQUEST_METHOD} ^HEAD|GET$
    RewriteCond %{QUERY_STRING} !s=[a-fA-F0-9]{32}
    RewriteCond %{QUERY_STRING} !product=vbnexus
    RewriteCond %{REQUEST_URI} !^(login|register|usercp|private|profile|cron|image|search)\.php$
    RewriteCond %{REQUEST_URI} !^admincp
    RewriteRule ^(.*\.php)?$ - [L,E=Cache-Control:max-age=120]
    
    To confirm Litespeed Cache is working check the file header for X-LiteSpeed-Cache = hit

    for index.php header via Firefox Firebug addon

    Code:
    Content-Encoding	gzip
    Vary	Accept-Encoding
    Date	Wed, 26 Jan 2011 16:40:00 GMT
    Server	LiteSpeed
    Connection	Keep-Alive
    Keep-Alive	timeout=5, max=100
    [B]X-LiteSpeed-Cache	hit[/B]
    Content-Length	6406
    X-Powered-By	PHP/5.3.5
    Content-Type	text/html; charset=ISO-8859-1
    Cache-Control	private
    Pragma	private
    Check /lscache directory contents

    Code:
     ls -alhR /lscache
    /lscache:
    total 48K
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 .
    drwxr-xr-x 28 root   root   4.0K Jan 26 23:28 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 0
    drwx------  3 nobody nobody 4.0K Jan 27 01:44 1
    drwx------  3 nobody nobody 4.0K Jan 27 01:35 2
    drwx------  3 nobody nobody 4.0K Jan 27 01:39 6
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 7
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 9
    drwx------  3 nobody nobody 4.0K Jan 27 01:39 a
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 b
    drwx------  3 nobody nobody 4.0K Jan 27 02:39 e
    
    /lscache/0:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 9
    
    /lscache/0/9:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 8
    
    /lscache/0/9/8:
    total 20K
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    -rw------- 1 nobody nobody 9.9K Jan 27 01:45 0987cec6
    
    /lscache/1:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:44 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:44 a
    
    /lscache/1/a:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:44 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:44 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 01:44 9
    
    /lscache/1/a/9:
    total 12K
    drwx------ 2 nobody nobody 4.0K Jan 27 01:44 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:44 ..
    -rw------- 1 nobody nobody  201 Jan 27 01:44 1a977843
    
    /lscache/2:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:35 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:35 9
    
    /lscache/2/9:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:35 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:35 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 02:39 c
    
    /lscache/2/9/c:
    total 16K
    drwx------ 2 nobody nobody 4.0K Jan 27 02:39 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:35 ..
    -rw------- 1 nobody nobody 6.5K Jan 27 02:39 29c52684
    
    /lscache/6:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:39 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:39 4
    
    /lscache/6/4:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:39 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:39 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 01:46 8
    
    /lscache/6/4/8:
    total 36K
    drwx------ 2 nobody nobody 4.0K Jan 27 01:46 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:39 ..
    -rw------- 1 nobody nobody  25K Jan 27 01:46 6483cafa
    
    /lscache/7:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 1
    
    /lscache/7/1:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 4
    
    /lscache/7/1/4:
    total 16K
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    -rw------- 1 nobody nobody 7.0K Jan 27 01:45 714e2f9d
    
    /lscache/9:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 4
    
    /lscache/9/4:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 a
    
    /lscache/9/4/a:
    total 20K
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    -rw------- 1 nobody nobody  11K Jan 27 01:45 94a971a0
    
    /lscache/a:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:39 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:39 e
    
    /lscache/a/e:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:39 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:39 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 01:39 9
    
    /lscache/a/e/9:
    total 20K
    drwx------ 2 nobody nobody 4.0K Jan 27 01:39 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:39 ..
    -rw------- 1 nobody nobody 8.2K Jan 27 01:39 ae962e7b
    
    /lscache/b:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 01:45 8
    
    /lscache/b/8:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 d
    
    /lscache/b/8/d:
    total 16K
    drwx------ 2 nobody nobody 4.0K Jan 27 01:45 .
    drwx------ 3 nobody nobody 4.0K Jan 27 01:45 ..
    -rw------- 1 nobody nobody 5.9K Jan 27 01:45 b8d74ed3
    
    /lscache/e:
    total 12K
    drwx------  3 nobody nobody 4.0K Jan 27 02:39 .
    drwxrwxrwx 11 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------  3 nobody nobody 4.0K Jan 27 02:39 0
    
    /lscache/e/0:
    total 12K
    drwx------ 3 nobody nobody 4.0K Jan 27 02:39 .
    drwx------ 3 nobody nobody 4.0K Jan 27 02:39 ..
    drwx------ 2 nobody nobody 4.0K Jan 27 02:39 d
    
    /lscache/e/0/d:
    total 12K
    drwx------ 2 nobody nobody 4.0K Jan 27 02:39 .
    drwx------ 3 nobody nobody 4.0K Jan 27 02:39 ..
    -rw------- 1 nobody nobody  201 Jan 27 02:39 e0ddf880
    Note: To be able to use Litespeed Inbuilt Cache feature you need >2 cpu Litespeed license. VPS and 1 CPU Licenses don't have the Inbuilt Cache supported.
    Last edited: Feb 1, 2011
  3. eva2000

    eva2000 Member

    Torture testing Litespeed Inbuilt cache against vB 3.8.6 PL1 front index.php page with apachebench at:

    • 5000 concurrency level + 1 million requests (virtualized server allocated 1GB memory) - cache timeout was set at 120 seconds but test run lasted 127.45 seconds, so the tail end caught some php load. PHP averaged around 10MB per process.
    • 5000 concurrency level + 1.5 million requests (virtualized server allocated 2GB memory) - cache timeout was set at 480 seconds while test ran only for 163.91 seconds, so well within cache timeout so no PHP usage.

    Try the above with apache and only 1-2GB memory :D

    Not a single failed request !

    5000 concurrency + 1 million requests

    Apachebench = 7,846.05 rps - over 240x times apache's performance handling 100x times the number of requests and 25x times the concurrency


    Code:
    ab -k -n 1000000 -c 5000 http://192.168.56.101/index.php
    This is ApacheBench, Version 2.0.40-dev <$Revision: 1.146 $> apache-2.0
    Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
    Copyright 2006 The Apache Software Foundation, http://www.apache.org/
    
    Benchmarking 192.168.56.101 (be patient)
    Completed 100000 requests
    Completed 200000 requests
    Completed 300000 requests
    Completed 400000 requests
    Completed 500000 requests
    Completed 600000 requests
    Completed 700000 requests
    Completed 800000 requests
    Completed 900000 requests
    Finished 1000000 requests
    
    
    Server Software:        LiteSpeed
    Server Hostname:        192.168.56.101
    Server Port:            80
    
    Document Path:          /index.php
    Document Length:        19841 bytes
    
    Concurrency Level:      5000
    Time taken for tests:   127.452598 seconds
    Complete requests:      1000000
    Failed requests:        0
    Write errors:           0
    Keep-Alive requests:    418171
    Total transferred:      20142500003 bytes
    HTML transferred:       19874423323 bytes
    Requests per second:    7846.05 [#/sec] (mean)
    Time per request:       637.263 [ms] (mean)
    Time per request:       0.127 [ms] (mean, across all concurrent requests)
    Transfer rate:          154335.11 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0   48  66.1     22     800
    Processing:    89  571 694.6    567   21904
    Waiting:       10  208 680.4    171   21283
    Total:        109  619 702.5    618   21904
    
    Percentage of the requests served within a certain time (ms)
      50%    618
      66%    665
      75%    690
      80%    705
      90%    756
      95%    871
      98%   1066
      99%   1191
     100%  21904 (longest request)
    
    CPU Load

    Code:
    top - 16:27:02 up 23 min,  3 users,  load average: 9.43, 3.15, 1.56
    Tasks: 136 total,   2 running, 134 sleeping,   0 stopped,   0 zombie
    Cpu(s): 29.8%us, 15.0%sy,  5.0%ni, 19.3%id, 29.2%wa,  0.3%hi,  1.3%si,  0.0%st
    Mem:   1026824k total,  1015532k used,    11292k free,      444k buffers
    Swap:  2064376k total,   667332k used,  1397044k free,    30628k cached
    5000 concurrency + 1.5 million requests​

    Apachebench = 9,151.34 rps - 280x times apache's performance with 150x times number of requests and 25x times the concurrency.

    Code:
    ab -k -n 1500000 -c 5000 http://192.168.56.101/index.php
    This is ApacheBench, Version 2.0.40-dev <$Revision: 1.146 $> apache-2.0
    Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
    Copyright 2006 The Apache Software Foundation, http://www.apache.org/
    
    Benchmarking 192.168.56.101 (be patient)
    Completed 150000 requests
    Completed 300000 requests
    Completed 450000 requests
    Completed 600000 requests
    Completed 750000 requests
    Completed 900000 requests
    Completed 1050000 requests
    Completed 1200000 requests
    Completed 1350000 requests
    Finished 1500000 requests
    
    
    Server Software:        LiteSpeed
    Server Hostname:        192.168.56.101
    Server Port:            80
    
    Document Path:          /index.php
    Document Length:        19841 bytes
    
    Concurrency Level:      5000
    Time taken for tests:   163.910341 seconds
    Complete requests:      1500000
    Failed requests:        0
    Write errors:           0
    Keep-Alive requests:    657470
    Total transferred:      30208037959 bytes
    HTML transferred:       29804908545 bytes
    Requests per second:    9151.34 [#/sec] (mean)
    Time per request:       546.368 [ms] (mean)
    Time per request:       0.109 [ms] (mean, across all concurrent requests)
    Transfer rate:          179976.66 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0   42  53.5     17     309
    Processing:   121  501 114.0    550     864
    Waiting:       12  154  62.7    156     534
    Total:        134  544 148.4    597    1016
    
    Percentage of the requests served within a certain time (ms)
      50%    597
      66%    645
      75%    666
      80%    678
      90%    708
      95%    730
      98%    757
      99%    784
     100%   1016 (longest request)
    
    CPU Load

    Code:
    top - 17:42:28 up  1:02,  3 users,  load average: 2.86, 1.33, 0.50
    Tasks: 103 total,   4 running,  99 sleeping,   0 stopped,   0 zombie
    Cpu0  : 29.5%us, 18.2%sy,  0.0%ni, 19.5%id,  4.0%wa,  0.0%hi, 28.8%si,  0.0%st
    Cpu1  : 29.6%us, 14.3%sy,  0.0%ni, 35.5%id,  2.0%wa,  0.7%hi, 17.9%si,  0.0%st
    Mem:   2059524k total,  2037892k used,    21632k free,      184k buffers
    Swap:  2064376k total,    92112k used,  1972264k free,    38816k cached
    Last edited: Jan 27, 2011
  4. eva2000

    eva2000 Member

    :: Jan 28th, 2011: Correction to findings
    I have to revise my findings a bit for Nginx in above tests. The failed requests seem to be from content length varying between apachebench requests and not due to failure requests related to connections/exceptions errors. Content length varies due to dynamic nature of php pages tested as as long as content length reported by apachebench as Document Length is nearly the same, it still means a successfully served request regardless.

    However, not sure why litespeed did have any of these errors vBulletin index.php page tests. The reason I came across this is because I have been able to implement same litespeed cache method for use on wordpress as well. However, litespeed apachebench testing wordpress pages results in same failed request due to content length varying between requests. So I guess as long as apachebench Document Length is varying only slightly in size, you can ignore the failed requests if they are due to content length as reality is the php page would have been served.

    Example: testing wordpress page non-cached nginx, litespeed and apache with only apachebench testing 2 requests and 1 concurrent all reported failed request due to content/document length

    Failed request due to content/document length

    Code:
    Failed requests:        1
       (Connect: 0, Length: 1, Exceptions: 0)
    Code:
    ab -k -n 2 -c 1 http://192.168.56.101/wp/?p=1417
    This is ApacheBench, Version 2.0.40-dev <$Revision: 1.146 $> apache-2.0
    Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
    Copyright 2006 The Apache Software Foundation, http://www.apache.org/
    
    Benchmarking 192.168.56.101 (be patient).....done
    
    
    Server Software:        nginx
    Server Hostname:        192.168.56.101
    Server Port:            80
    
    Document Path:          /wp/?p=1417
    Document Length:        39934 bytes
    
    Concurrency Level:      1
    Time taken for tests:   0.186644 seconds
    Complete requests:      2
    Failed requests:        1
       (Connect: 0, Length: 1, Exceptions: 0)
    Write errors:           0
    Keep-Alive requests:    0
    Total transferred:      80258 bytes
    HTML transferred:       79804 bytes
    Requests per second:    10.72 [#/sec] (mean)
    Time per request:       93.322 [ms] (mean)
    Time per request:       93.322 [ms] (mean, across all concurrent requests)
    Transfer rate:          417.91 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0    0   0.0      0       0
    Processing:    92   93   1.4     94      94
    Waiting:       91   92   2.2     94      94
    Total:         92   93   1.4     94      94
    
    Percentage of the requests served within a certain time (ms)
      50%     94
      66%     94
      75%     94
      80%     94
      90%     94
      95%     94
      98%     94
      99%     94
     100%     94 (longest request)
    Code:
    ab -k -n 2 -c 1 http://192.168.56.101/wp/?p=1417
    This is ApacheBench, Version 2.0.40-dev <$Revision: 1.146 $> apache-2.0
    Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
    Copyright 2006 The Apache Software Foundation, http://www.apache.org/
    
    Benchmarking 192.168.56.101 (be patient).....done
    
    
    Server Software:        LiteSpeed
    Server Hostname:        192.168.56.101
    Server Port:            80
    
    Document Path:          /wp/?p=1417
    Document Length:        39739 bytes
    
    Concurrency Level:      1
    Time taken for tests:   0.157730 seconds
    Complete requests:      2
    Failed requests:        1
       (Connect: 0, Length: 1, Exceptions: 0)
    Write errors:           0
    Keep-Alive requests:    0
    Total transferred:      80100 bytes
    HTML transferred:       79648 bytes
    Requests per second:    12.68 [#/sec] (mean)
    Time per request:       78.865 [ms] (mean)
    Time per request:       78.865 [ms] (mean, across all concurrent requests)
    Transfer rate:          494.52 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0    0   0.0      0       0
    Processing:    78   78   0.0     78      78
    Waiting:       68   68   0.0     68      68
    Total:         78   78   0.0     78      78
    
    Percentage of the requests served within a certain time (ms)
      50%     78
      66%     78
      75%     78
      80%     78
      90%     78
      95%     78
      98%     78
      99%     78
     100%     78 (longest request)
    Code:
    ab -k -n 2 -c 1 http://192.168.56.101/wp/?p=1417
    This is ApacheBench, Version 2.0.40-dev <$Revision: 1.146 $> apache-2.0
    Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
    Copyright 2006 The Apache Software Foundation, http://www.apache.org/
    
    Benchmarking 192.168.56.101 (be patient).....done
    
    
    Server Software:        Apache/2.2.3
    Server Hostname:        192.168.56.101
    Server Port:            80
    
    Document Path:          /wp/?p=1417
    Document Length:        39772 bytes
    
    Concurrency Level:      1
    Time taken for tests:   0.188623 seconds
    Complete requests:      2
    Failed requests:        1
       (Connect: 0, Length: 1, Exceptions: 0)
    Write errors:           0
    Keep-Alive requests:    0
    Total transferred:      80605 bytes
    HTML transferred:       80097 bytes
    Requests per second:    10.60 [#/sec] (mean)
    Time per request:       94.312 [ms] (mean)
    Time per request:       94.312 [ms] (mean, across all concurrent requests)
    Transfer rate:          413.52 [Kbytes/sec] received
    
    Connection Times (ms)
                  min  mean[+/-sd] median   max
    Connect:        0    0   0.0      0       0
    Processing:    94   94   0.0     94      94
    Waiting:       49   49   1.0     50      50
    Total:         94   94   0.0     94      94
    
    Percentage of the requests served within a certain time (ms)
      50%     94
      66%     94
      75%     94
      80%     94
      90%     94
      95%     94
      98%     94
      99%     94
     100%     94 (longest request)
    Last edited: Jan 28, 2011
  5. dihuta

    dihuta Member

    Very nice Benchmark.
    Still can not make Guest Cache working with VBSEO.
  6. eva2000

    eva2000 Member

    Thanks. Looks like after wordpress + litespeed cache, vB + vBSEO + litespeed cache would be next on my list of things to conquer as alot of the private clients including myself use vBSEO with vB.

    I finally managed to get Varnish VCL tuned to work with vBulletin 3.8.6 PL1 as well, so updated the above table to include Apache + Varnish 2.1.5 vB index.php tests to the list as well as update the table column to remove failed requests in the calculation of adjusted rps for nginx.

    [​IMG]

    Looks like when you include mysql backend as a factor in testing vB index.php page, litespeed cache just edges out Apache + Varnish. Unlike, with php based test.php file where Apache + Varnish took the lead - although it seems i hit a litespeed cache memory leak bug in those tests.
    Last edited: Jan 28, 2011
  7. dihuta

    dihuta Member

    Thank you.
    Hope to see VBSEO + Litespeed cache soon.
  8. fastproxy

    fastproxy New Member

    Thanks for the nice guide,

    i got the cache working, i have a server using haproxy/nginx as load balancer before litespeed webserver.
    Code:
    Server	nginx
    Date	Tue, 15 Feb 2011 19:08:16 GMT
    Content-Type	text/html; charset=utf-8
    Connection	keep-alive
    Content-Encoding	gzip
    Vary	Accept-Encoding, User-Agent
    X-LiteSpeed-Cache	hit
    Content-Length	22072
    X-Powered-By	PHP/5.2.14
    Cache-Control	private
    Pragma	private
    X-UA-Compatible	IE=7
    but some how some pages show i logged in as someone else account?look like the page i was loading belong to someone else.

    Is there something missing?
    I am using VBB 3.8.6


    Update:

    I found the problem, it was the .htaccess i copy from your but forgot to edit according to my server:
    Thanks
    Last edited: Feb 15, 2011
  9. eva2000

    eva2000 Member

    yeah vb cookie prefix needs setting for your specific forum :)

Share This Page