I’ve just spent today switching the BuddyPress testdrive site over to a new server. The site was previously running on some server space kindly donated by andrea_r.
The test site is closing in on 1,000 registered members, this is rising by around 50-75 per day. We didn’t want to jeopardize Andrea’s other sites, so decided it was best to move it.
I’ve now set the site up on its own VPS, which gives greater flexibility with the apache/php/mysql setup.
I thought I would share a trick to speed up your own WPMU installation. I’m by no means an expert in this area (at all) but this worked for me.
1. Upgrade Apache and PHP to the latest versions.
Many WHM/Cpanel enabled VPS accounts have a script called “easyapache” (usually in /scripts/easyapache). This will let you easily upgrade both Apache and PHP at once. Apache 2.2 from what I read has performance advantages over 2.0 and definitely 1.3.
2. Compile PHP with eAccelerator
If you’re using easyapache then you just need to check the box to add this to your PHP setup. If not, then follow the instructions on the eAccelerator docs. eAccelerator is essentially a caching tool that will significantly speed up PHP scripts. You can read more about it on wikipedia.
Once I had the latest Apache and PHP installed, along with eAccelerator, the generation time reported by WordPress was significantly reduced. On the old server this could be anywhere from 1-5 seconds, but with the new server and eAccelerator this was reduced to 0.1-0.8 seconds. A very significant performance improvement.
Have any performance tips you’d like to share?
17 responses so far ↓
Klark // October 1, 2008 at 6:46 pm
Hey Andy,
Nice work on Buddypress.
When I was setting up my site two months ago, I had installed eAccelerator like you described. But I did something extra.
I installed this plugin into /wp-content. My understanding is that this further improves performance and makes WordPress eAccelerator aware.
http://neosmart.net/dl.php?id=13
I’m new to this as well, so I’m basically learning as I go along.
ovidiu // October 2, 2008 at 3:18 am
I used that plugin as well, but I read a couple of posts stating it doesn’t work anymore with the newer aka 2.6.xx versions of wpmu.
Indeed in my cache folder, nothing was happening after upgrading wpmu.. so I had to switch to the filebased version of this plugin while still using eaccelerator which does speed up things already, I just lsot the edge of object based caching
http://neosmart.net/dl.php?id=14
Andrea // October 2, 2008 at 5:08 am
Yep, it’s getting kind of crowded on the server running more than one successful site.
I have to move some of my own stuff to their own boxes.
And I’m sure I’ll be using some of these tips. installing eaccelerator was easy – once we got past the typos.
Dr. Mike Wendell // October 2, 2008 at 7:21 am
We’re in the process of moving our mu setups onto their own rack with their own allocated boxes. We had previously put them into our regular shared hosting boxes since we only place 200-225 clients on a single box but all of the sites are growing a bit. Three (or more later on) boxes up from with the mu files and file based object cache up front, 16 addition boxes behind those for the databases and uploads. None of them are real heavy. Our largest is about 32k individual blogs that had previously been on two servers by themselves. Our *cough* adult mu installs sit on their own boxes individually since they generate a ton of bandwidth and they manage their own installs anyway.
Off loading the themes files and, later on the uploads, is something we’re looking into as well. Elad is big on this. We’ve been bugging him to work on the end user file uploads since he figured out the theme files.
We off loaded out spam solution onto another box as well. We’re running Spam Assassin on a separate box and send comment checking to that using a modified version of wp-spamassassin. We were using a donated license of Akismet but, well, let’s just say it wasn’t a solution for us or our clients. Typepad Antispam works as well but I’m sure you’ll edit out this line. Spam Karma 2 and (Oh I forget the name of the other one.) shouldn’t be running on the same box. That’s just asking for trouble and processor load.
Dealing with splogs and blocking IP addresses that continue to set up those splogs are a plus as well. Folks don’t realize how much traffic a splog can receive. Ditto on ip addresses that continue to send comment spam.
I’m sure I’m forgetting stuff. Maybe I should do this as an article myself.
ovidiu // October 2, 2008 at 7:39 am
@drmike:
I had a closer look at the plugin I mentioned for offloading upload files to S3 (http://tantannoodles.com/toolkit/wordpress-s3/), and found a sample configuration file. It seems you can pre configure the values to be used for wpmu there and that should make it run as a wpmu plugin as opposed to its normal usage under wp.
Free Webscriptz » Archivo del Blog » Better WPMU Performance with eAccelerator // October 2, 2008 at 3:30 pm
[...] Source:Better WPMU Performance with eAccelerator [...]
Simple Station Web Design // October 11, 2008 at 11:08 am
Hey andy – just a small tip here. My small team has been writing steadily more complex apps over the past year and we’ve really come to rely on APC (http://us.php.net/apc) as our PHP caching solution. We’ve been writing web apps using the Zend Framework and we’ve done some performance benchmarks and found that APC really is substantially faster than both eAccellerator and Zend Optimizer.
Dr. Mike Wendell // October 11, 2008 at 5:47 pm
ovidiu , thanks for that. I just have to sit down and try it someday. With the number of boxes we have, it;s not a high priority right now.
Trent // November 9, 2008 at 8:14 pm
I personally have been having great success with xcache. Any particular reason you went with eAcellerator Andy?
ben // March 13, 2009 at 12:00 pm
Hi Andy,
You now have 4,500 + members, impressive!
How is your vps holding up.
How much ram is it running. This will give me a good idea for some of my own sites.
I’m also wondering which to go with, xcache or eAccelerator….. hmmm…
Cheers,
Mahmut ÜNAL // April 9, 2009 at 8:49 am
RokecokJept // May 26, 2009 at 12:42 am
Бошка разболелась. Надо что-то делать в своем бизнесе… Кстати – перерегистрация ООО – весьма актуальная тема на сегодняшний момент. Не проспать бы. Задачу указано разрешить за полгода. Мда…
бесплатные фильмы // May 26, 2009 at 5:19 am
Никогда не спорьте с умным: люди могут не заметить между вами разницы!
букет // June 2, 2009 at 2:32 am
А какие вы предпочитаете цветы?
oricluber // June 5, 2009 at 9:44 pm
oriclub
dns records tools // July 1, 2009 at 10:18 am
Do you want know your see php request variables – for free?
GEO base services // July 1, 2009 at 12:04 pm
Cool servise – Trace ip tools