Oct 27, 2011

Optimizing Your WordPress Environment

INAP

WordPress is one of today’s most popular CMS/blogging platforms. Millions of websites rely on its simplicity, its wealth of capabilities and its plug-ins to manage their online presence and to ensure their website is available 24x7x365.

Although most sites don’t require a huge amount of capacity (and thereby require only a single server), high traffic sites (like several of our customers) often split traffic across multiple high-end servers, which requires their WordPress setup to be optimized and perfect: every little detail matters.

So what can you do to make sure your WordPress site runs efficiently and utilizes fewer resources?  One option is to hire dozen of developers (and spend hundreds of thousands of dollars) to optimize your code, which will result in an environment that doesn’t really look like WordPress anymore. You probably won’t be able to take advantage of the thousands of free plugins and, most importantly, you probably won’t be able to get WordPress updates (because your code is too customized). Perhaps not the best option.

A second (better) option would be to improve the underlying technology that powers WordPress: the web server, the PHP interpreter and the database server. This will allow you to continue reaping the benefits of WordPress updates and plugins, with the added benefit of having an optimized, high performance environment.

With the second option in mind, Voxel has spent several weeks developing an optimized WordPress environment that we’re now ready to share with you. What follows is the software stack that we have included (and we think it’s da BOMB).

NGINX

For web server software, we’re using NGINX. NGINX (pronounced “engine-x”) is open source web server software that is designed to provide high performance, low memory usage and high concurrency. The software is absolutely stunning – it uses a fraction of the resources other software packages (like Apache) use to deliver requests, and delivers them FASTER. On top of all that, the configuration is so simple that anyone can do it.



There are tons of references on the web about NGINX’s legendary performance, and their official English site has a great page with quotes from people who are using it for heavily loaded environments: Why Use NGINX?


Some big names out there that are leveraging the power of NGINX are: WordPressHuluGithubOhlohSourceForge,WhitePages,TorrentReactor – just to name a few.

PHP-FPM (with APC)

PHP-FPM (FastCGI Process Manager) is what we’re using as a PHP interpreter.  PHP FastCGI implementations provide a number of extra features that are especially beneficial for heavily loaded web servers. Initially it was released as a set of patches for specific PHP stock versions but since PHP version 5.3.3 it has become part of the official PHP distribution.
WordPress PHP code won’t notice a difference (and will run more smoothly).

We have also included the well-known APC in the mix, which is a robust open source framework for caching and optimizing PHP intermediate code.

PERCONA SERVER

The Percona Server is an enhanced drop-in replacement for MySQL server.  It includes an XtraDB storage engine and provides extra features, better performance and improved instrumentation for analysis of performance and usage.


The Percona Server people are also responsible for the popular MySQL Performance Blog and some other papers and tools related to MySQL.

This particular environment is not available yet but will be available soon (after we’ve completed thorough testing).  You’ll be able to provision it through our hAPI for VoxCLOUD and VoxSERVERS. The provisioning will automatically adjust your configurations to fit the server’s specs.

If you are using (or planning to use) Chef this will suit you perfectly.  Why? Because we have Chef-ized the environment allowing you to provision it using Knife.  You can read more about it James Brinkerhoff’s blog post: Bring Your Knife to Voxel’s hAPI Kitchen.

Explore HorizonIQ
Bare Metal

LEARN MORE

About Author

INAP

Read More