Jump to content
Froxlor Forum
  • 0

WordPress on a small VPS recommended stack?


sporkman

Question

I have to get about 5 or 6 low-traffic WP sites on a small (1GB RAM) VPS.  Which web stack is the most efficient (mainly thinking of the memory footprint)? I'm a little put off by apache, but I've only used it with mod-php (and then I stick Varnish in front of it if needed). I think the alternatives are now more varied - apache worker w/fpm, etc...

Any recommendations before I just start playing around with the various froxlor options?

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

Yeah, I'm working with the dumb, stock apache w/o FPM and it's actually not that bad at all.

My concern was really that I haven't really tested much with apache in the last decade or so, but I did recently play around with nginx and a bunch of variations and was able to settle on a stack that seemed like a good fit for WP + a 1-2GB VPS.  I'm just going to share a bit of that here because some of it is really not nginx-specific, but this is all WordPress-specific...

  • Varnish is a bit of a pain and did not seem to be worth the trouble
  • For caching at the http level, I found the built-in nginx caching to be almost indistinguishable (and easier to configure) than varnish
  • Don't forget to enable the opcode cache! What a nice surprise to see that turning it on in Froxlor enables a nice built-in opcache monitor page
  • PHP7 showed a general decrease in CPU usage, and the "stock" opcode cache is fine
  • After a few days, mysqltuner does do a pretty decent job, but I did kind of crank anything that gobbles RAM down a bit because...
  • A WordPress "object cache" makes a really substantial difference, in fact, for logged-in users (who do not get web caching), this was the most obvious speed bump I found. I used Redis and a very simple WP plugin that has a big "clear cache" button along with automatic purging when making edits.

So my takeaway is that the WP object cache is really a big deal - you don't need to give Redis a ton of RAM, and it lets you dial down mysql's RAM usage a bit. Basically, as you know, WP bangs on the database a lot. If you install the super-helpful "Query Monitor" plugin (this or something else is essential when comparing hosting stacks), you'll see just how ridiculous the situation is. The WP object cache is basically an intelligent database cache that's orders of magnitude faster than MySQL and for reads, doesn't hardly touch MySQL. And since Froxlor seems to be very "hands-off" with things outside it's control, adding Redis isn't at all a big deal. You can manually add a password/namespace for a customer and they can load that info into whatever plugin they're using...

Link to comment
Share on other sites

Pretty darn happy so far with php in worker mode with php-fpm via mod_proxy_fcgi (or is it fastcgi_proxy? or fcgid_proxy? anyhow, the "newest/best" one marked as being needed Deb Stretch in PHP-FPM config page).

I have a few customers that don't even use PHP, is there a way to avoid starting up php-fpm processes for them?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.



×
×
  • Create New...