About the Author

Chris Shiflett

Chris Shiflett is an author and speaker who leads the web application security practice at OmniTI.


PHP and Apache 2 Slashdotted

Slashdot is running a story about the recent PHP and Apache 2 discussion - Is Apache 2.0 Worth the Switch for PHP?. I feel compelled to clarify (and support) Rich's main point, because it seems to be missed by quite a few people.

He believes that we shouldn't be actively discouraging people from upgrading to Apache 2. Otherwise, we should work together to fix whatever problems exist. This is mostly a reaction to the PHP documentation, which states:

Do not use Apache 2.0.x and PHP in a production environment neither on Unix nor on Windows.

To be fair, Apache 2 is more proven than PHP 5, but there doesn't seem to be the same level of discouragement for upgrading to PHP 5. In short, I think Rich has a point. Let people decide for themselves whether something is stable enough for their needs. Opinions expressed in the PHP documentation seem more authoritative than suggestive.

This has nothing to do with whether there is a compelling reason to upgrade to Apache 2 or whether PHP can guarantee thread safety - the question being raised is whether there is a compelling reason not to use Apache 2 with PHP, and if there is, what is it?

I personally think Rich has nothing but good intentions and wants to see PHP and Apache 2 working as well together as PHP and Apache always have.

More information:

About This Post

PHP and Apache 2 Slashdotted was posted on Tue, 21 Dec 2004 at 22:39:29 GMT.

4 Comments

1. Adam Trachtenberg's GravatarAdam Trachtenberg said:

In general, I agree with you and Rich. However, if you're looking "compelling reasons" here are the two I can think of :

1) The PHP Apache 2 SAPI modules don't have as much testing and burn in as the Apache 1 SAPI module.

2) None of the PHP code developers use Apache 2, so it's harder to fix Apache 2 SAPI bugs if they're reported.

Tue, 21 Dec 2004 at 23:18:12 GMT Link


2. Lukas's GravatarLukas said:

regarding the point that apache2 is more proven than php5. you miss the point actually. the point is that we know how to fix php5 and have a vested interest to do so. since few (none?) of the core php guys use apache2 in production the same cannot be said about apache2. this is the reason why apache2 is not recommended in whatever mode you can run it in.

Wed, 22 Dec 2004 at 03:50:37 GMT Link


3. Andi Gutmans's GravatarAndi Gutmans said:

Not saying that I completely disagree. I think it's important for PHP to support Apache 2 handler pre-fork. And many people are using it in production environments. However, I wouldn't compare the Apache 2 upgrade to a PHP 5 upgrade. PHP 5 comes with lots of very useful features, whereas Apache 2, well, isn't exactly a big step up for the average PHP user.

Wed, 22 Dec 2004 at 04:15:59 GMT Link


4. Ilia Alshanetsky's GravatarIlia Alshanetsky said:

If hundreds of people come to you complaining about implementation of your product on a certain platform. It only makes sense that you warn people about inherent dangers/instability of using that platform until the issue is resolved.

I am very happy to hear many people say that PHP and Apache 2 works for them, I wrote a fair bit of code in Apache 2 SAPIs :-). But, the fact it works for some does not mean it works for all and the reports I see on PHP's bug system clearly demonstrate Ap2/PHP is not yet on par with Ap1/PHP.

Wed, 22 Dec 2004 at 15:50:58 GMT Link


Post A Comment

Personal Details and Comment

Style Guide

Line breaks are converted to paragraphs. Also use:

  • <a href="" title="">text</a>1
  • <em>text</em>
  • <blockquote><p>text</p></blockquote>
  • <code>2  <?php  if ($foo) {      $foo = TRUE;  }  ?></code>
  1. Note: <code> can be used inline (e.g. in paragraphs) or in a block as shown. Include whitespace and newlines in blocks.

Please enter Chris (my first name) below. This is a primitive spam prevention technique, and I apologize for the inconvenience.

Preview and Submit

Upcoming Talks

O'Reilly Open Source Convention

21 - 25 Jul 2008

At Oregon Convention Center, Portland, Oregon.

ZendCon

15 - 18 Sep 2008

In Santa Clara, California.

PHP Appalachia

11 - 14 Oct 2008

At Big Bear Lodge, Gatlinburg, Tennessee.

New Comments

Amir wrote:

Hi chris! Please check this and guide me: http://forums.devnetwork.net/viewtopic.php?f=34&t=8...

Posted in
Nathan Bentley wrote:

Hi Chris, A great tutorial, which should help a lot of people! We implemented something simil...

Posted in
Daniel S wrote:

Just recently I sold my 1.gen Macbook(core duo version). And to be honest, I don't miss it for on...

Posted in Top X List of Mac OS X Annoyances
Buke Beyond wrote:

I agree it is ridiculous that php is doing this. I am using php for generating commands for othe...

Posted in PHP Stripping Newlines
Davis Ford wrote:

I agree, although I have a list of many more annoyances. However, rather than complain about the...

Posted in Top X List of Mac OS X Annoyances

Browse Comments