Memories gone wild

I just started a VPS after being on a shared plan for years. I moved to the VPS because DH said my WordPress site was exceeding the allowed server load (which I believe is 90M for shared hosting).

So as with every new VPS user the default is set to 2300M the first week for free and the minimum amount you must purchase is 150M (with bursts to 300M). So I though ‘great!’ As DH recommends I test this first week, determine how much server capacity I would need and to adjust accordingly.

I was able to install HyperCache for caching and got the memory usage to hover below 150M which is great.

Now the problem, without adding any new plugins or server taxing features my memory usage zoomed up to 2000M! I had moved my resources down to 304M so the server stopped working, I got thrown 500 errors, etc. I submit a support ticket and they say wp-cron and some cached pages users are viewing are causing the memory load.

So I disable all my plugins, I modify wp-cron.php by eliminating two lines
if ( $_GET[‘check’] != wp_hash(’187425′) )
to try and get wp-cron to behave.

My memory usage zoomed up past 4000M! And this is with almost zero cpu usage, the website is delivering error 500s. I set a redirect to a static page for those errors.

Now it looks like my memory usage is below 150M again but my WordPress site is unreachable. Can’t get in via wp-admin nor hit the site itself. I disabled the front page by adding a static page so I know users are NOT hitting the front page to trigger any php code. The load on the memory/cpu should be minimal.

I have other WordPress blogs on this VPS and they are all running fine. Granted the one I have that’s down is more complex but I disabled much of it and it’s still unresponsive. Even with 4G memory, reboots, removal of plugins, etc. still no go.

Anyone see this kind of thing before? DH claims 600M is plenty for a Top 100 Blog. Mine is far from top 100 yet even with 4000M it won’t run. And my week is up in less than a day and there’s no way I’m gonna pay for 4G/month at $400 when even that doesn’t work.

I pointed out to tech support this page:
They said that wasn’t the problem but I’m having my doubts. They also said SuperCache isn’t a problem anymore either (contrary to posts on the web) but when I enabled it my memory usage zoomed up to 350M, with Hypercache it stayed below 150M.

Here’s my site which is down:
There’s a screen snapshot on there somewhat of what it looks like when it’s up.

There is are two “shiny new” new articles in the wiki that my help you get a handle on what is happening with this:

These articles contain some very clear and detailed information about how various configurations react in the handling of memory, and has some guidance as to how to keep a WP site running in a predictable amount of memory, specifically on a PS.

I suggest giving those a study, and see if there isn’t a clue there as to how you might proceed to get this under control.

–DreamHost Tech Support

So what is it? Is SuperCache good or bad on my VPS?

From the DreamHost Wiki:
WP-Super Cache: This is an improvement over WP-Cache and it provides a great performance boost. Unfortunately at least some Dreamhost users and Dreamhost PS users have had trouble getting recent versions of Super Cache to work properly. It also may require some knowledge about editing your .htaccess file.

I’ll try again with it, when I installed it before my memory usage shot up.

Again, I can’t even reach my WordPress Dashboard at this time.

Super-cache has always worked well for me. Remember that the wiki is editable by anyone, and everyone might not have the same experience. Lately, I have taken to using Hyper cache, and I am very happy with it.

Any of these are far better than wp-cache or using no cache at all.

If you can’t reach your dashboard at all, try the old trick of ssh’ing in and renaming your wp-content/plugins directory (maybe to something like “plugins_disabled”, which will effectively disable all your plugins, and will often let you at the dashboard.

–DreamHost Tech Support

Okay, got the site back up. Not sure why it wouldn’t come up when I had plenty of free memory or why after six days it went from 122M memory use to 4GB. Crazy stuff.

Whacked some WordPress installs, phpBB installs, plugins, activated xcache, fast cgi and a few other things.

Couldn’t have done it without SSH’ing in with the terminal to watch stats in real-time. Hopefully I can optimize further and get the numbers down lower.