burm Posted September 1, 2011 Posted September 1, 2011 Hi All,How does the use of eaccelerator by putting in $INFO['use_eaccelerator'] = '1'; have an effect on the cache management page? Should it still be caching things there? After enabling eaccelerator should I clear out the cache? Thanks
altenerg Posted October 26, 2011 Posted October 26, 2011 I was just about to ask similar question. Also is IPS aware that eaccelerator 9.5.3 was the last version to support content caching. Installing eaccelerator 9.6.0 or 9.6.1 and setting $INFO['use_eaccelerator'] = '1'; is 100% useless! xcache still supports both and you can monitor both from the xcache stats page. That said I still prefer EA even without content caching. I use memcached for that. Also see: http://www.litespeedtech.com/support/forum/showthread.php?t=5355
burm Posted October 26, 2011 Author Posted October 26, 2011 Interesting... Perhaps I'll give xcache a try and see if I notice any performance differences.
ThatForumGuy Posted October 26, 2011 Posted October 26, 2011 I have done a lot of testing with caching tools, and I am now running eAccelerator as a PHP Cache/PHP Optimizer(no line added for it in the conf_global file). In my testing, it is a bit faster than xcache. I am using Memcached as the content cache for IPB, and it works well and is very fast. Those two, plus using LiteSpeed, are giving me a TTFB of less than 200 ms.
burm Posted October 26, 2011 Author Posted October 26, 2011 Wow, thats pretty impressive. How much of a bump did you see when you started using memcached for the content? I'm using directadmin on my server, and adding in memcached support seems to be bit of a pain since its not an option out of the box with their custom apache tools script. I'll have to dive into it more tonight.
ThatForumGuy Posted October 26, 2011 Posted October 26, 2011 If memory serves, I was able to see about a 50ms improvement, but don't hold me to that as I cannot find my notes right now. (keep in mind that the 50 ms is an improvement in TTFB, not total page load time which is bandwidth dependent.)
burm Posted October 26, 2011 Author Posted October 26, 2011 I'm working on a linode VPS , so my memory usage is critical. But, I just tried memcached, I did notice a slight improvement, I was hoping for more to be honest. What did you set your memcache size to? (just curious) Whats your total load time for your forum index page? Maybe I just have to much crap, but mine is hovering around 4.5-5.5 seconds! (I am serving ads, facebook crapola, etc, google analytics) Thanks!
ThatForumGuy Posted October 26, 2011 Posted October 26, 2011 I have it set to 1024MB, but it never uses anywhere near that much. According to Google Webmaster Tools mine is 2.4 seconds, although it is quite a bit faster in my testing. Usually in the 1.0-1.5s range. I can make it faster by disabling more hooks, too. You might want to take a look at that. I should mention that I am using CloudFront as my CDN.
.Nuno. Posted October 26, 2011 Posted October 26, 2011 Hi, Is there any advantage of using memcache in a setup with only one server? Here's what we can read in memcache site: http://code.google.c...PHP%27s_APC,_mm"A local cache benefits over both MySQL query cache and memcached because you can store arbitrary data objects into it, and it does not have latency associated with a fetch over a network."
ThatForumGuy Posted October 26, 2011 Posted October 26, 2011 Yes, it pulls cached data faster, even if you only have one server, becasue it is pulling the cache from RAM instead of from Disk.
Grumpy Posted October 26, 2011 Posted October 26, 2011 Whats your total load time for your forum index page? Maybe I just have to much crap, but mine is hovering around 4.5-5.5 seconds! (I am serving ads, facebook crapola, etc, google analytics) I'd just like to add that you need to be careful when analyzing machine spewed "time to load page". Sometimes, it's really not meaningful. If you have 2 elements on your page (wow! what a simple page) which are your page and some crappy plugin (like facebook), and your first element loads in 1ms and 2nd loads in 15 seconds, the analyzer will say it took 15 seconds. Would people viewing the website care if the facebook plugin took 15 seconds to load? Not really. There was another person posting in this forum before where his gravatars were taking 5~8 seconds to load while rest of his page was loaded in 1.2 seconds and was saying that the time analyzers were reporting 5~8 seconds of load time which is terrible. If you care for the "SEO value" (ugh... I hate how people value search engine's experience over actual user experience) to load time be faster, you can try to make your long-time consuming plugins to load asynchronously or in an iframe. FB, for example has async load option by default since the new version (IPB loads FB plugins in iframe on default skin as far as I'm aware, but don't quote me on that).
altenerg Posted October 26, 2011 Posted October 26, 2011 I have done a lot of testing with caching tools, and I am now running eAccelerator as a PHP Cache/PHP Optimizer(no line added for it in the conf_global file). In my testing, it is a bit faster than xcache. I am using Memcached as the content cache for IPB, and it works well and is very fast. Those two, plus using LiteSpeed, are giving me a TTFB of less than 200 ms. Yup that's how I did it on Apache.
altenerg Posted October 26, 2011 Posted October 26, 2011 I'm working on a linode VPS , so my memory usage is critical. But, I just tried memcached, I did notice a slight improvement, I was hoping for more to be honest. What did you set your memcache size to? (just curious) Whats your total load time for your forum index page? Maybe I just have to much crap, but mine is hovering around 4.5-5.5 seconds! (I am serving ads, facebook crapola, etc, google analytics) Thanks! You won't see much of a performance difference unless you are always loaded with tons of simultaneous traffic/load. Keep it enabled as it reduces the amount of query calls to mysq and you can still keep query cache enable in my.cnf
altenerg Posted October 26, 2011 Posted October 26, 2011 Hi, Is there any advantage of using memcache in a setup with only one server? Here's what we can read in memcache site: http://code.google.c...PHP%27s_APC,_mm "A local cache benefits over both MySQL query cache and memcached because you can store arbitrary data objects into it, and it does not have latency associated with a fetch over a network." Yes. Cached queries run from memory instead of loading via your mysql database. That a better setup for digg, slahdot type incoming traffic.
altenerg Posted October 26, 2011 Posted October 26, 2011 Also remember that memcached object TTL is hard coded to 10 seconds. So unless you have a busy site it will often not store as much files but as long as you have a good hit rate and hits per second you can decide from there. If you want to keep cache full (items count) then I would suggest using soft cache limits. Here's what my memcached stats look on a low traffic ipb site. (<1000 pv per day)
burm Posted October 26, 2011 Author Posted October 26, 2011 Also remember that memcached object TTL is hard coded to 10 seconds. So unless you have a busy site it will often not store as much files but as long as you have a good hit rate and hits per second you can decide from there. If you want to keep cache full (items count) then I would suggest using soft cache limits. Here's what my memcached stats look on a low traffic ipb site. (<1000 pv per day) How did you get those stats? (graphical) Also what I noticed my TTFB was at around 500ms, I'd love to get it down to that 200ms range.
altenerg Posted October 26, 2011 Posted October 26, 2011 its just memcache.php But I use THIS on the backend. It has a LOT more stats than what I just uploaded:http://code.google.c...pmemcacheadmin/ Enjoy! Also, make sure you set it to only load from 127.0.0.1 or your remote IP only. I assume you already have stats page for EA? My TTFB is sometimes under 100ms at times but around 150ms - 200ms. Install Strace to see where you are loosing time. sudo apt-get install strace
burm Posted October 26, 2011 Author Posted October 26, 2011 Thanks for sharing! Sending you a pm in a sec.
altenerg Posted October 26, 2011 Posted October 26, 2011 Get PM... Here are a few things to scratch the surface to help your server deliver first byte faster. We need to know for a certainty if this is network only issue or if the backend IS indeed the hold up:1) Install and use strace to see where php is lagging, waiting, errors, etc.2) Check for bottlenecks - For PHP its often the CPU. Tune Apache2! My mysql its often RAM, tune my.cnf. Tune your network and buffer settings, etc. Now if you are even using Apache haha... are you using .htaccess? If so move ALL mod_rewrite rules into apache.conf file and set "allowoveride to none" so that you completely turn off .htaccess. Using .htaccess slow down server. (I know IPS ask you to add it loll. But it can be moved to apache2.conf for best performance). 3) Post or PM me your results for: ab -n 100 -c 20 http://forum.yoursite.com:80/ If you run that without any failed request then post results for: ab -n 1000 -c 20 http://forum.yoursite.com:80/ You'll be surprised how useful that can be! We need to see if the high TTFB is from network, your php app, waiting or mysql or slow hardware processing... combination :smile:. If you are able to run the above without error it will say a lot.4. Tune your my.cnf! Use mysqltuner and mysql primer scripts (google). Remember larger buffers and *_cache are NOT always faster :smile:
burm Posted October 26, 2011 Author Posted October 26, 2011 I'm going to post more when I get some time tonight... I am running apache. 100 Document Path: /forums/ Document Length: 221035 bytes Concurrency Level: 20 Time taken for tests: 8.935 seconds Complete requests: 100 Failed requests: 0 Write errors: 0 Total transferred: 22141200 bytes HTML transferred: 22103500 bytes Requests per second: 11.19 [#/sec] (mean) Time per request: 1786.929 [ms] (mean) Time per request: 89.346 [ms] (mean, across all concurrent requests) Transfer rate: 2420.05 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 1 2.7 0 8 Processing: 390 1723 666.9 1594 3462 Waiting: 373 1655 644.3 1548 3381 Total: 391 1725 666.1 1599 3462 Percentage of the requests served within a certain time (ms) 50% 1599 66% 1866 75% 2119 80% 2179 90% 2777 95% 3094 98% 3238 99% 3462 100% 3462 (longest request) 1000 Document Path: /forums/ Document Length: 219755 bytes Concurrency Level: 20 Time taken for tests: 82.483 seconds Complete requests: 1000 Failed requests: 468 (Connect: 0, Receive: 0, Length: 468, Exceptions: 0) Write errors: 0 Total transferred: 220119944 bytes HTML transferred: 219742944 bytes Requests per second: 12.12 [#/sec] (mean) Time per request: 1649.662 [ms] (mean) Time per request: 82.483 [ms] (mean, across all concurrent requests) Transfer rate: 2606.12 [Kbytes/sec] received Connection Times (ms) min mean[+/-sd] median max Connect: 0 0 2.3 0 19 Processing: 652 1645 452.5 1525 3783 Waiting: 627 1568 427.2 1454 3707 Total: 653 1645 452.3 1525 3783 Percentage of the requests served within a certain time (ms) 50% 1525 66% 1627 75% 1700 80% 1765 90% 1973 95% 2760 98% 3385 99% 3572 100% 3783 (longest request)
*Salvo* Posted October 26, 2011 Posted October 26, 2011 I have done a lot of testing with caching tools, and I am now running eAccelerator as a PHP Cache/PHP Optimizer(no line added for it in the conf_global file). In my testing, it is a bit faster than xcache. I am using Memcached as the content cache for IPB, and it works well and is very fast. Those two, plus using LiteSpeed, are giving me a TTFB of less than 200 ms.i've installed memcached, eAccelerator (but it uses a lot of temp space) and apc accelerator. BTW is there a way to set one of them as accelerator for IPB?
burm Posted October 26, 2011 Author Posted October 26, 2011 As a side note my TTFB is 336MS and total page load time is 2 seconds with my IP Content index page. So it must be something with the forums right?
burm Posted October 26, 2011 Author Posted October 26, 2011 i've installed memcached, eAccelerator (but it uses a lot of temp space) and apc accelerator. BTW is there a way to set one of them as accelerator for IPB? From what I understand to use memcached at all you HAVE to use that as the caching option in the global conf otherwise it goes unused.
.Nuno. Posted October 26, 2011 Posted October 26, 2011 I'm missing something here :) Is there any benchmarks that tell Memcached is faster that APC or xCache for storing data?http://stackoverflow.com/questions/1794342/memcache-vs-apc-for-a-single-server-site-data-caching Doesn't IPB uses APC/xCache to store data and as an opcode cache?
altenerg Posted October 26, 2011 Posted October 26, 2011 I'm missing something here :smile: Is there any benchmarks that tell Memcached is faster that APC or xCache for storing data?http://stackoverflow...te-data-caching Doesn't IPB uses APC/xCache to store data and as an opcode cache? Nope. xcache for example has seperate "varibles cache" which is what the globalconf cache setting for IPB is using: ; same as aboves but for variable cache xcache.var_size = 4M xcache.var_count = 1 xcache.var_slots = 8K opcode is not the same. :smile:
Recommended Posts
Archived
This topic is now archived and is closed to further replies.