Page 25 - Open Soource Technologies 304.indd
P. 25

Unit 1: Introduction to PHP



                                                                                                  Notes
             Set-up
             I had compared two blog systems: this one and WordPress 2.5 with a patched WP-Cache-2
             add on. I used following configuration:

              1.  Web Server lighttpd 1.4.13
              2.  Interface FastCGI
              3.  PHP 5.2

              4.  Bytecode cacher: XCache 1.2.1
              5.  Database MySQL 5.0
              6.  Caching for WP: WP-Cache-2 with an additional performance patch that caches
                 alreadydeflated versions of page in order to reduce requirement of re-compressing
                 on cache hit.

              7.  Hardware: AMD Athlon XP 64bit, 1G RAM
              8.  OS: Linux, Debian Etch 64bit.
             I prepared two blogs that were filled up with 1000 articles  each. Each article had  10
             comments, all the articles were organized in 10 categories in each blog.
             Tests
             First I run load tests with disabled caching system.

             Then the cache was enabled and cleaned before each test run. Each time, the cache was
             “warmed up” with 100 requests of different pages. Then CMS was loaded by http_load
             with 1000 requests from 5 concurrent connection. The client was patched in order to send
             a header: Accept-Encoding: gzip, deflate in order to fetch compressed pages: the real live
             situation.
             For each run, the cache included a certain percent of new pages (in order to achieve a
             correct hit/miss ratio) and the rest were taken from the 100 “warm pages”.
             Results

             CMS       No cache fetches per second ratio   Warm up time
             WordPress:             7.6                    13.0 s
             CppCMS:                310                    0.28 s

               Miss ratio (%)   WordPress      CppCMS
                     0              711           2300
                     1              370           2160
                     3              176           1940
                     5              118           1790
                     10              64           1450
                     15              41           1210
                     20              33           1075
                     30              20           795
                     40              13           570
                     50              13           570
                                                                                 Contd...



                                             LOVELY PROFESSIONAL UNIVERSITY                                    19
   20   21   22   23   24   25   26   27   28   29   30