switch from apache2 to apache1
mdeggers at earthlink.net
Tue Jan 18 18:22:46 UTC 2005
On Tue, 2005-01-18 at 14:35 +0100, Rakotomandimby (R12y) Mihamina wrote:
> How to switch cleanly from apache2 to apache1 on FC2 ?
> I mean I dont want to remove all the dependancy (php and the others),
> remove apache2, install apache1 then reinstall the needed stuf (php and
> the ohers). I want to do a direct switch.
> How should I manage it ?
You will have to change all of your dependencies, especially something
like PHP. Apache 2 has a significantly different module interface which
is not compatible with Apache 1. This means that modules compiled for
Apache 2 will not function in Apache 1 just as modules compiled with
Apache 1 will not run under Apache 2.
Apache 2 offers a lot of advantages over Apache 1, so I am not sure why
you would want to go back.
One reason might be PHP. There is a recommendation on the PHP web site
to not use PHP with Apache 2, and to not use PHP 5 in production.
These concerns are primarily due to a potential lack of thread safety in
the PHP modules and the potential use of threads in Apache 2 MPMs
(multi-processing modules). Since the PHP core team does not supply the
modules, they will not vouch for thread safety.
I think however that the default MPM on UNIX (and Linux) is prefork.
According to the documentation, this MPM is a nonthreaded preforking web
server, much like Apache 1. While you don't get the benefits of
threading, you do get the thread safety that PHP is concerned with.
I build my Apache server from scratch, so I don't know how Fedora builds
its server. You can look at http://localhost/server-info/ if you have
that configured. You can also run httpd -l to get a list of compiled-in
modules. Either will tell you what multiprocessing module is being
Look for prefork.c in the httpd -l output. This tells you that you have
the prefork MPM. On httpd://localhost/server-info/ look for a line that
reads something like the following:
MPM Information: Max Daemons: 150 Threaded: no Forked: yes
If you are using a module other than prefork, then there are thread
safety concerns with non-core PHP modules / libraries. If you are using
prefork (the default under Linux), then you SHOULD be OK.
There was a debate over on Slashdot a while ago concerning this. The
general consensus was that the PHP folks made a potentially inflammatory
statement concerning the use of PHP and Apache 2 in production. Saying
something like "We do not vouch for the thread safety of third party
libraries" would have be more to the point.
That said, I think that the PHP folk should create an environment that
single threads suspect library calls until provided proof from the
library authors that these libraries are thread safe. Throwing the baby
out with the bathwater (PHP or Apache 2 with non thread safe libraries)
seems to be a bit extreme.
There are other interesting ways of creating dynamic web sites that do
not run into these problems. Here are some of them.
Perl ( http://www.cpan.org )
mod_perl ( http://perl.apache.org/ )
Mason ( http://www.masonhq.com/ )
ASP ( http://www.apache-asp.org )
Python ( http://www.python.org/ )
mod_python ( http://www.modpython.org/ )
ASP.NET ( http://www.go-mono.com ) via XSP
Tomcat ( http://jakarta.apache.org/tomcat/ )
Velocity ( http://jakarta.apache.org/velocity/ )
I think there's a Scheme / Lisp module as well, but I'm not sure about
Sorry for the long rambling. I hope this answers your question and
gives you lots of paths for creating dynamic web sites.
just my two cents . . . .
More information about the users