Mike's blog post led to a few vB customers posting over at litespeedtech.com's support forums asking if Litespeed had any caching feature similar to Varnish which can be used to boost vBulletin forum performance. Turns out Litespeed web server has it's own inbuilt cache feature similar to Varnish which can be utilised to boost vBulletin performance which is only available in Litespeed 2+ cpu licenses and above. The Litespeed free standard edition and 1 cpu licenses don't have the cache feature. These same vB customers also found that NginX web server also has similar fastcgi_cache feature.
As I am also a NginX and Litespeed user, I set out to test all available solutions
- Apache+Varnish - managed to get Varnish 2.1.5 to work with vB 3.8.6 PL1 with some changes to Mike's Varnish VCL file which was based on older Varnish 2.0.x
- Litespeed Cache - thanks to NiteWave over litespeedtech.com support forums for outlining how to use Mike's Boost plugin XML file with Litespeed Cache
- NginX FastCGI Cache - unfortunately, having difficulties getting this to work with NginX choking with 502 gateway errors and upstream timeout errors.
So ended up testing various combinations with Apachebench on 3 types of files
- test.txt static ascii art file - for non-cached tests
- test.php basic php file - for cached tests
- vBulletin 3.8.6 PL1 index.php page for cached tests
1. test.txt static ascii art file - for non-cached tests
Baseline for test.txt comparison between Apache vs Nginx vs Litespeed in non-cached environment
2. test.php basic php file - for cached tests
Litespeed 4.0.19 Cache had a memory leak which was later fixed and patched, so table below has both before and after fix results as well as tuned Litespeed settings results http://www.litespeedtech.com/support...ead.php?t=4638. Also updated table to add Litespeed + Varnish for comparisons.
3. vBulletin 3.8.6 PL1 index.php page for cached tests
Finally, testing vB 3.8. PL1 index.php page which factors in mysql end connection with non-cached tests. Cached tests bypass the mysql connection saving your mysql database end resources http://www.litespeedtech.com/support...3233#post23233
- Results are jaw dropping amazing for Varnish caching to boost Apache's performance in vBulletin index.php page tests from 32 requests/sec to 16,765 requests/. While Litespeed webserver's Cache feature is taking performance to the next level at 22,399 requests/sec in vBulletin index.php tests and surpassing 28,000 requests/sec in basic test.php php file tests. Once you factor in Litespeed's non-cached performance and scalability you can see that Litespeed is leading the way.
- Note, you have to remember both Varnish and Litespeed Cache boost is for guest visitors only. Logged in visitors would still need to depend on the inherit performance of each respective web servers - Apache, Litespeed and NginX. Update: This assumes using Varnish VCL in it's out of box configuration state but you can also change Varnish VCL settings for per user caching with hashed cookies so you don't need vB boost plugin for Varnish in per user cache VCL configuration. One such implementation of Varnish VCL in per user configuration is Unixy's Cpanel Varnish plugin - you can read differences and my thoughts here.
- Litespeed web server's Cache feature is still in it's infancy with further developments to come which is something I look forward to testing.
- Once I figure out how to get NginX FastCGI caching working will also run tests and do an update, so subscribe to this blog post if you want to keep updated
- Unfortunately, Litespeed Cache feature conflicts or doesn't seem to work with vBSEO .htaccess right now. Not sure when or if it will work. Secured a test vBSEO license, so will see if it can be made to work. But for now Litespeed Cache feature in Litespeed web server would have to work with vBulletin forums which don't use vBSEO. But Litespeed web server itself (with cache feature disabled) runs vBSEO fine like on Apache web server. Update: Mar 23rd, 2011: Update: Looks like Litespeed cache feature finally works with vBSEO see these 2 threads here and here.
- Jan 30th, 2011: Added to test.php php tests, Litespeed + Varnish configuration
- Feb 1st, 2011: Varnish VCL config thread posted
- Feb 7th, 2011:
- Still working on vBSEO at http://www.litespeedtech.com/support...ead.php?t=4650
- Litespeed cache instructions at http://www.litespeedtech.com/support...ead.php?t=4625 and seems they updated their blog with instructions too at http://blog.litespeedtech.com/2011/0...uilt-in-cache/
- Mar 1st, 2011: Litespeed v4.0.20 is out with a new response header to better distinguish between what pages to cache etc and with a slight change in vB Boost Plugin xml file it will work with the new response header http://vbtechsupport.com/127/
- Mar 23rd, 2011: Update: Looks like Litespeed cache feature finally works with vBSEO see these 2 threads here and here.