well, i don’t have an answer right now. But wordpress + plugins is a memory nightmare.
A quick test from a blog not even live yet. I’ve got cforms, podpress, syndicate and a couple custom plugins enabled.
The real culprit behind wordpress memory issue looks to be the options table. WordPress immediately loads all options into a global options array. (just put die(print_r($GLOBALS)) in an init hook of a plugin)
So i did the following test.
index.php i did an echo memory_get_usage();
then in my init hook of a custom plugin I repeated the echo and then threw a die() so I would see the results.
Before wordpress starts. php prints ~50kb of memory used. after the init is done, php is using 10mb of memory!
Now this is with those plugins setup. I’ve got 5 forms setup in cforms. It looks like a design problem in the allowed usage of the options table. cform puts all its configured tables into the options table. This is really bad. While it might be ok for a site with very little traffic, its death if you get any decent traffic.
Also keep in mind, that was just in the init hook. wordpress hadn’t even looked up categories and posts yet.
If none of these cache plugins takeover before wordpress loads options, then they won’t save any memory.
To harp a little more on the memory. That means php will load 10mb+ of memory into the apache process. I’m not gonna go deep into apache processes, but if you have high traffic, you might have over 80 processes running for apache. Each “live” process will expand its memory need and keep that memory until it dies. so if php demands more memory, that process will keep that memory for its life cycle.
I’ll be looking into this in the coming weeks as I have a new client who gets 50k hits a day on his blog and this memory issues is really killing his server.
some more tests to run would be a default wp install and see what its base memory needs are. I really am beginning to feel that the wordpress devs should start educating their users on this. They could curve some of this by guiding plugin authors to not use the options table and keep their own options in their own table and not to load them in globals.
Wanted to share these finds with you.
best of luck, I’ll try and remember to post my findings if I can solve this.