Wpress Error
When website is posted to the front page of Digg, the amount of requests to the server will usually take down small sites running on relatively low end hardwares (small RAM, slow CPU, HDD). To prevent this from happening to your site (specifically, WP blogs), there are things you can do to maximize what low end hardwares can manage, and therefore prevent the Digg Effect.

1) Cache it: WP-Cache 2.0

A very-easy-to-install-and-use plugin. By creating cached pages, it reduce the php code parsed by the web server, and also eliminate the query to mysql database. Both speeds up the page load dramatically.

2) eAccelerator: cache php pages at compiled level, which means your php codes will stil be executed. Much faster than no cache at all.

3) Apache 2: MPM Worker

Using this method in Apache will help a bit since version 1.3 wasn’t design with threading in mind while 2.0 has included this new feature along with Caching methods that i can help alot. This quote from apache.org regarding Mpm Worker ” This Multi-Processing Module (MPM) implements a hybrid multi-process multi-threaded server. By using threads to serve requests, it is able to serve a large number of requests with less system resources than a process-based server. Yet it retains much of the stability of a process-based server by keeping multiple processes available, each with many threads.” In order to use the php module, you need to compile it with thread safety.

4) Random Notes

Some of the tips i’m listing here have been used on various different wordpress sites which i manage but the one miss fact that people forget is that hardware plays big key to how you handle this. The average home computer isn’t able to sustain this amount of traffic in long term period thats why i’m true fan of the Dell Power edge Line - 750’s, SC1425’s , 1850’s , and 1950’s when dealing with the beast wordpress you want to try and keep the os and everything and applications as lean as possible. In the various setups i’ve used Freebsd 5 - 6 and Beta 7 all work well if your box is tuned for it. I do notice that linux has slight gain in performance but this is due to the fact that mysql out of the box is well tuned for Linux vs BSD but if you try new method that was introduced by jeremy.zawodny on his blog by enabling libthr.

For FreeBSD 6 tests show that using libthr gives the best performance (search on the net for some benchmarks).
To use libthr, just download the precompiled mysql for FreeBSD 6, and add the following lines to your /etc/libmap.conf :

[mysqld]
libpthread.so.2 libthr.so.2
libpthread.so libthr.so

After that restart your mysqld, and from then on it should be using libthr.

If that still doesn’t help — then copy your page and make it static and add rule to your .htaccess to force it to the static page..

well thats it for my tips. ;-)

Leave a Reply

You must be logged in to post a comment.



Site Navigation