tennisguy
06-15-2001, 05:04 AM
Hello,
I recently got a dedicated server with PHP 4.00 installed via compile.
I would like to upgrade to 4.05. What is the best way to do this? Could I simply download the source to 4.05 and compile it over the 4.00 or do I first have to UNINSTALL 4.00 first? If so, how would I uninstall 4.00?
Or, could I simple install an rpm of 4.05 over the 4.00 or would I still have to first uninstall the 4.00?
I am on RH6.2 and Apache 1.3.12
Your help is greatly appreciated!
drhonk
06-16-2001, 12:15 AM
If your apache is compiled to support module .. and your php 4.0 is installed as a module .. you can just compile the new php and install it as a module replacement.
Go to http://www.php.net and read the installation document .. it has a good step by step installation documentation.
freakysid
06-19-2001, 01:47 PM
You can tell how your php was compiled (as a static or dynamic apache module) by looking at the output of phpinfo(). If you haven't done this before, you just create a script with the code below and call it from your browser:
<?php phpinfo() ?>
One of the items of info shown is the configure command. If the configure command is --with-apxs then php was compiled as a dynamic module. As drhonk says, all you need to do is recompile the php as a dynamic module and Apache should load the new module dynamically.
If the configure command has --with-apache then Apache will have been compiled with php as a static module. You will have to recompile Apache as well as php.
It is easier to compile php as a dynamic module however it will be a little more efficient if compiled as a static module. This is also a straightforward guide http://hotwired.lycos.com/webmonkey/00/44/index4a_page4.html?tw=programming
tennisguy,
I don't see why you have to upgrade to 4.005 , makes no difference anyway :-)
But, If you do upgrade, here is the general idea of compiling php.
1. configure php
2. compile php
3. configure apache and have the --where_php_is=../php4.005
4. compile apache
5. install apache
:)
Purty easy eh?!