Installing and enabling the Wp-Cache plugin is the first thing an average wordpress user can do to help ease the load on the server, and thus avoid a slashdotting. You can get WP-cache here. But you may be asking yourself, “Self, I thought wordpress had ‘Built-in Caching‘… why do I need WP-Cache2?“
David Chatit (wordpress stud) answered this very question for me on the Wordpress forums:
…WP-Cache (or Staticize) has ALWAYS been THE answer for potential high-load scenarios — and still is.
The new WP2 object caching mechanism has somewhat minimal impact on overall performance. Maybe under extremely high loads it’d help some, but nothing of the magnitude of WP-Cache. [source]
You especially need to have this plugin working if you have any other plugins which filter the_content in someway. Many popular plugins do this (adsense deluxe) so even if you aren’t sure, it doesn’t hurt to have wp-cache installed and enabled.
Many people have problems installing this plugin, so here is my guide on how to get it working. The instructions posted on the plugin’s page read like this:
- Upload to your plugins folder, usually wp-content/plugins/ and unzip the file, it will create a wp-content/plugins/wp-cache/ directory.
- If you have Gzip Compression enabled turn it off (in Options->Reading).
- Activate the plugin on the plugin screen.
- Go to “Options” administration menu, select “WP-Cache” from the submenu, the plugin will try to autoconfigure everything. The plugin will try to autoconfigure everything and guide you through the process. In case of failure –normally due to the lack of files’ privilegies– it tell you and give the instructions to solve the problems.
If you have followed these instructions and don’t get any errors when viewing pages or changing the options in the Admin portion of Wp-cache, then consider yourself blessed. However, you still need to make sure that the plugin is actually working. You can do this by (I assume you are using FireFox):
- Load up your homepage
- Hold SHIFT down and refresh the page using the refresh button on the Firefox toolbar [this loads the page fresh again, skipping an internally cached version of the page]
- View the page source and look for this at the end of the file (your numbers will be different):
<!-- Dynamic Page Served (once) in 0.205 seconds -->
<!-- Cached page served by WP-Cache -->
I followed the above steps and everything was hunky dorry, no errors, nothing. But no cache either. I did not see anything in my html source. After I slept on the issue, and poked around the web I discovered that the problem was a permissions error. If you are also having this problem, here is what to check:
- Create the symbolic link and make sure that it has the correct permisions (777)
- Make sure wp-content has 777
- Make sure wp-content/cache/ has 777
- Make sure wp-content/plugins/wp-cache has 777
- Make sure the symbolic link /wp-content/advanced-cache.php has 777
- Add define(’WP_CACHE’, true); in wp-config.php, located in the blog root
Once installed, I went over these 6 steps to get WP-Cache working.
09 Mar 06
10:50 am
[...] How to use caching in WordPress so your site doesn’t go down if you’re linked from the Digg homepage. [...]
12 Mar 06
12:39 pm
[...] I’m trying to get a handle on how to tune apache a bit better now. I’ve found a few articles that offer some guidelines or tips aimed at bloggers (and one on setting up wp-cache too), just haven’t sorted it all out yet. Spent an hour going through the httpd.conf and commenting out a bunch of modules that I’m reasonably sure I didn’t need to have loaded. That alone made a huge difference in memory usage. Again, for my sort of volume, this isn’t overly critical but maybe someday I’ll write something truly interesting to the rest of the world. Tags: apache, hamachi, linux vpn Possibly Related Posts: [...]
15 Mar 06
1:17 pm
Whenever I enable wp-cache onlye the background image and header HTML tags load. Then I view the source of the page none of the code for the actual body of the page loads. Have you ever heard of this happening?
15 Mar 06
1:53 pm
Brett, no I have never heard of this happening. But then, I haven’t been looking for an answer to that problem… things you could check (besides the permission issues mentioned above, which you should check also) are that you have the latest wordpress and latest wp-cache. Alternatively, make sure you have the version of wp-cache that matches the version of wordpress you are using. The WP-cache author seems to reply to questions as well, maybe fire off an email to her.
Without seeing what happens its really hard to tell with this stuff. My guide above helped me, but it won’t necessarily help you for your problem. What do you think?
15 Mar 06
5:23 pm
Im running WP 2.0.2 and I have version 2.0.17 of WP-Cache installed. I am also running K2 Beta2 r163 though I do not think K2 is the cause of this. Here are some screenshots to show you what is happening.
My site as it appears normally:
http://www.flickr.com/photos/gatewayy/113034225
Screenshot of the options that appeared after activation:
http://www.flickr.com/photos/gatewayy/113034226
This is my site after activating the plugin:
http://www.flickr.com/photos/gatewayy/113034227
Settings after activation:
http://www.flickr.com/photos/gatewayy/113034228
I have checked everything that permissions wise besides the sybolic link, I can’t remember that command, any thoughts?
16 Mar 06
9:51 am
Run this command in your blogs root directory (the same directory with wp-config.php in it):
16 Mar 06
11:44 am
[gatewayy@andromeda www]$ ln -s wp-content/plugins/wp-cache/wp-cache-phase1.php wp-content/advanced-cache.php
ln: `wp-content/advanced-cache.php’: File exists
[gatewayy@andromeda www]$
Looks like I am good in that regards.
21 Apr 06
9:11 pm
Digg Defender: A Plugin For Wordpress…
An article I wrote about well-designed blogs got more than 1,200 diggs yesterday, causing an influx of some 20,000 to 30,000 new visitors, each pulling down the following page elements:
10 large images totalling 969,582 bytes
CSS and JS totalling 21,6…
06 May 06
1:50 am
That’s a great plugin. I had to install it because of a slow server.
11 Aug 06
6:05 pm
[...] Well, for one, we have enabled a Wordpress plugin called ‘wp-cache‘ that will aid in the distribution of heavily viewed content in the future. This was suggested by the tech, Brad, at our host. It’s currently enabled, and I’m pleasantly surprised to see it seems to be working well so far. [...]
16 Oct 06
4:28 pm
You should not propagate to use file permissions 777 at first try. The right file permissions are 755. If it doesn’t work, try 775, at last, try 777 if nothing else works. Indeed, if you set file permissions to 777 without trying a more secure permission setup first, you simply open a wide door to hackers.
Please, be responsible for yourself, and for your readers. File permissions 777 are not the normal ones, it is very risky because it means that everybody have read and write access to your files. If it is the only solution left, it also means that your webserver is not well configured. Try to settle this with your webhost, or change it for a more secure one.
Sorry for being paranoid, but hackers are looking for these holes.
20 Oct 06
1:35 pm
[...] MaxPower [...]
23 Oct 06
11:21 pm
[...] If you are on a Linux or Unix host, installation is pretty straightforward. [...]
25 Oct 06
9:13 pm
For more advanced users who seek optimum site performance and minimum bandwidth consumption , I have made an modification to WP-Cache 2.0, to generate and save pre gzipped pages to the cache and serve them to browsers that request them avoiding the need for constant re-compression.
It can help a blog to respond better in a high demand situations, decreasing both server CPU load and required bandwidth to minimum.
The required modifications are described at my blog page - Modifying WP-Cache 2.0 to generate and cache gzipped output once and serve it multiple times
It is my first contribution to the WordPress community and I am welcoming any feedback!
28 Nov 06
2:33 pm
where would i put the line for the symbolic link ????? thats the only thing i dont understad sorry if this is a stupid question
29 Nov 06
9:26 am
To make a symbolic link, you need to login to your server using SSH. Once at the command prompt, run the command shown above from your blogs root.
01 Dec 06
10:59 am
I’m still clueless on this whole symbolic link step. I hate to trouble you but could point me in the right direction so I can learn step-by-step exactly how to properly excute this process. Do I log into Cpanel? or is there some other steps to take?
Thanks in advance
03 Dec 06
12:55 am
I want to install this plugin, but I don’t have shell, and/or telnet access. The auto installation fails at my end, and it directs to create symbolic link.
Can anyone advice me, how do I install this plugin and create symbolic link?
thanks in advance.
DG…
31 Dec 06
6:14 pm
While I agree 777 (or 666 which is what I think he meant) is dangerous. I found the easiest way to install without errors is to change the wp-content.php file permissions to 666. Install WP-Cache. configure and start wp_cache. Then change the permission back to 644.
This worked like a champ for me at my blog: http://rateladder.com
26 Jan 07
10:05 pm
I can NOT change the file permission of the symbolic link ‘advanced-cache.php’ in the wp-content folder to 777 or even 775… It stays stuck on 755. When i change it and view it again it’s back on 755, whatever kinda values I’ve put in it in the first place.
I think this is the reason WP-Cache doesn’t cache for me some reason.
I’m using WP-Cache 2.0.22 and Wordpress 2.0.2 by the way, and it’s been a disaster since I can’t get this thing to work.
I don’t even know how to create a symbolic link, it is that the auto install did this. Otherwise I could create a new one with the right file permissions, but the author of this plugin apparently assumes that everyone is an expert.
So…. How can I change the file permissions of that symbolic link file??
29 Jan 07
6:07 pm
@wcp - you can’t change perms on a symlink, so don’t worry about it.
I’m having similar issues, new WP user, using wp 2.1 and wp-cache 2.0.22, no files in the wp-content/cache directory are created, followed above instructions perfectly. Most distressing, as I only get about 2-4 req/sec with my wp blog compared to 1700+ with the mt one (static html so that is expected). I have to be able to get more than 4 req/sec though, thats just crazy
29 Jan 07
7:05 pm
Adventures with Wordpress…
I set up a blog for Iambe and decided to play a bit with the Wordpress blogging engine and thought it was pretty slick compared to Movable Type and started looking at using it for this Blog. The install of……
06 Feb 07
3:02 pm
what is symbolic link ?
08 Mar 07
2:14 pm
Thank god for your site. I tried setting the symlink without having folders set up correctly and completely hosed my site. Now I am having to reactivate everything but at least it will load.
Thank you SOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo much for posting this. I was going to have a heart attack if i did not find this site.
12 May 07
11:24 pm
[...] Blogger’s status as a part of Google ensures that you’ll stay up. Unfortunately, the benefits more or less end there. Unlike other blogging software, Blogger doesn’t offer domain names, statistics or spam catchers. But you’ll survive Digg, for free. WordPress is another decent free host. Unlike Blogger, WordPress has a domain name service, non-blog pages, stats and a nifty tool called WP-Cache. WP-Cache does exactly what you think it does: it caches your blog pages so that you can serve them up faster and thus avoid crashing while you’re on the front page of Digg. These free hosts are effective, but you’ll do better by going with a paid host. They give you more flexibility, plus you don’t want your Digg visitors to think you’re a cheapo, do you? [...]
16 May 07
4:48 pm
What is supposed to actually be cached? My list of cached files is just
feed-rss and feed-rss2, that’s it just two files. Shouldn’t it be caching a lot more?
23 May 07
1:18 pm
This plugin saved us from collapse. For some reason a fairly obvious post about how to use your GMail account as a virtual hard drive got Stumbled. Amazing how many people hit the site all at once…it would have pushed us over our CPU allowance very quickly indeed without wp-cache
db
26 May 07
5:02 am
Hi,
I have the plugin installed and it’s working, but I’m having trouble configuring exceptions. I’d like the front page, category pages and our forum to remain static, is there a way to do this?
So far it seems you either cacahe everything or nothing. *_*
06 Jun 07
5:55 pm
You can create a symlink using php.

1. Create a php file: symlink.php
2. Put this code in it:
3. Upload symlink.php to your /wp-content/
4. Go to: yoursite/wp-content/symlink.php
done
06 Jun 07
5:57 pm
sorry, the code from step 2 is:
16 Jun 07
1:26 pm
And the code is???
You can put the code in the WP Pastebin and post the text for the link here. Then we can get it.
Thanks
http : / / wordpress.pastebin dot ca / new dot php
30 Jun 07
2:19 am
Make Wordpress quicker….
wp-cache with gzip compression without hacking:
One of the things I find annoying with wp-cache is that it’s not gzipped so the user experience of wordpress is helped by quicker first byte content delivery with almost zero overhead but hindere…
23 Jul 07
2:02 pm
I followed these instructions to a tee, but still the cache dir has nothing in it.
Any other tips? I’ve done everything on this site and the authors site probably 4-5 times.
24 Jul 07
3:41 am
I wanted to create a password-protected bonus page for my RSS subscribers, but the password protection conflicts with wp-cache. Anyone else see this? Moreover, anyone know how to fix it. Excluding that page doesn’t seem to make it work
db
28 Jul 07
1:33 pm
I’m having an issue where my site sometimes wont load (blank page) until i clear the cache.
Im using wp cache 2.1.1 and PHP is 4.4.
I’m hearing others are having this issue as well.
09 Aug 07
2:48 pm
[...] WP-Cache – Your blog may be new and probably you don’t require this plugin right now. However, I advised you to have it installed in advance as you never know when your post can beome an instant hit in online world resulting into a server crash. This plugin is an extremely efficient page caching system that will make your site much faster and responsive. This plugin is very useful for handling sudden bursts of traffic coming from social bookmarking sites like Digg. Reddit and Slashdot. WP-Cache basically creates static versions of your pages so that they can be served to your visitors without querying the MySQL database. It’s a must-have for all bloggers. Installing it is a bit difficult. Here is one useful installation tutorial for it. [...]
07 Feb 08
12:07 am
[...] blog article, How to: Configure WP-Cache to abate ‘the digg effect’ — MaxPower, was great in helping me configure WordPress’s WP-Cache [...]
08 Apr 08
12:46 pm
[...] lot of traffic and links, but if your site can’t stay up you will not see any of those links. Maxpower explains how you can install and configure WordPress cache, so your site will stay up for social [...]
16 May 08
11:14 pm
[...] lot of traffic and links, but if your site can’t stay up you will not see any of those links. Maxpower explains how you can install and configure WordPress cache, so your site will stay up for social [...]
18 Aug 08
10:00 pm
This is a great article. My pages use to load so slow especially during periods of even moderate traffic. I tried to install wp-cache on my original host but they ran IIS and so it failed. Now that i have moved hosts, I am a happy caching user!
06 Jul 09
5:01 am
[...] of traffic and links, but if your site can’t stay up you will not see any of those links. Maxpowerexplains how you can install and configure WordPress cache, so your site will stay up for social [...]