homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Visit PubCon.com
Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

PHP + nGinx + Wordpress = ?

 12:44 am on Jan 22, 2011 (gmt 0)

Since I'm migrating to a new server, I thought I'd give nGinX a try. The hype is that nGinX solves many of the problems that make Apache slow... I've been on LAMP for a long time... Now I'm curious what "LNMP" can do.

Some initial observations & questions:

1) nGinX was *very* easy to set up. I had it installed and serving a few virtual domains in less than 10 minutes. That's awesome.

2) seems like my usual "yum php" etc isn't going to cut it. nGinX requires something called "PHP-FPM"?

3) Will an app written for PHP on Apache run equally well (functionally) on nGinx? What about all my favourite PECL modules, like JSON and memcache, mysql et al

4) Wordpress does some funny stuff to .htaccess - will that work on nGinX? Several of my sites have a WP blog attached; if WordPress won't work out of the box, that's a deal breaker.



 3:15 pm on Feb 3, 2011 (gmt 0)

Nobody seems to be using nGinX ... except you :)
What did you discover?

On the other hand, Apache + XCache [xcache.lighttpd.net] has been a popular choice for some regarding performance issues. I've not found Apache to be the bottleneck so much as it is the fat apps like PEAR, PECL, WordPress, etc. that can bring a server to it's knees sometimes.


 6:44 pm on Feb 3, 2011 (gmt 0)

I discovered that:

yes, Nginx will run PHP-FPM (FastCGI Process Manager), which they claim to work just like yer vanilla PHP that plays nice with Apache. Getting that working is "easy" (in air-quotes), as long as you can decipher the geekspeak and twisted instructions for which the Linux blogosphere is reknowned.

Some have gotten Wordpress to work on Nginx, and have blogged about it. HOWEVER, the standard WP install (the famous one-minute install) does not do the job. After installing WP, there's a pile of reconfiguration that needs to be done, particularly with all the URL rewriting that makes WP tick.

So, it's possible, but far from trivial.

The additional work involved in getting PHP to work, then getting WP to work on top of that, convinces me that right now is not the time I want to be experimenting with Nginx. I'll save that exploration for a different project.

I haven't been experiencing any performance problems on my current server; it's a nice fat dedicated VPS with plenty of RAM. But I'm slowly migrating to a rackspace cloud instance, and I was curious if I could get the same good performance with Nginx - on a smaller machine with less memory and CPU. Doing more with less, so to speak.


 9:07 pm on Feb 3, 2011 (gmt 0)

Nobody seems to be using nGinX ... except you :)

According to the latest netcraft web survey nginx [engine-x] market share is growing faster than that of any other web server, even though it is still small relative to Apache or Microsoft IIS.

Apache 59.13%
Microsoft 21.00%
nginx 7.50%

In my view nginx is the best choice for a proxy to serve static content like css and images on websites under heavy load.


 5:33 pm on Feb 4, 2011 (gmt 0)

Nobody seems to be using nGinX ... except you :)

I meant in the PHP Forum here because of the lack of response. I was being facetious.

Yes, I read the stats too. Oddly enough, on that same page there is a claim that WP itself is stated to be running nGinX ...

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved