Solved

PHP 4 - Linux Red Hat Enterprise 5

Posted on 2009-05-10
4
948 Views
Last Modified: 2013-12-13
Hi All,
I installed Red Hat Enterprise 5 for our webserver.
I need to install PHP version 4 for our web server as it does not support version 5.
Where do i get PHP 4 supported by Red Hat Enterprise 5?

Thank you
0
Comment
Question by:c00kie88
  • 2
4 Comments
 
LVL 2

Expert Comment

by:lavinpj1
ID: 24352214
PHP4 is EOL and should not be used. Why does the server not support PHP5, surely it can be compiled from source?

Phil
0
 
LVL 2

Accepted Solution

by:
jccs0519 earned 250 total points
ID: 24358811
Yea, you should be able to recompile from sources.

http://www.php.net/manual/en/install.unix.apache2.php

I'm running RedHat 8, RedHat Enterprise Linux 3 and I have both php4 and php5 version running before.
0
 

Author Comment

by:c00kie88
ID: 24360787
Hi all,

Just spoken to the web developer, apparently it's not possible to convert our coding to be compatible to PHP 5 as a lot of work will be required.
Is there any PHP 4 rpm that i can find that compatible with Red Hat Enterprise 5?
0
 
LVL 2

Expert Comment

by:jccs0519
ID: 24553770
You probably won't find any php4 rpm for RHEL5, but if you have support contract w/ Redhat you might ask them to see if they have it.  If not, then just get the php4 sources from php.net and follow this link http://www.php.net/manual/en/install.unix.apache2.php

to compile from sources.  The instruction is for php5, but php4 is pretty similar as I remember.

Depending on the how the RHEL5 pre-installed apache2 is configured, you may need to install a new version of apache in /usr/local/apache2.  May seems hard, but if you follow the instruction, it's not bad.   Here is very simplified instruction but should give you a guideline.

1. Download Apache2 (may need Apache 1, depending on the php4 requirement)
2. Unpack and configue, make, install
3. Download php4 (http://us3.php.net/get/php-4.4.9.tar.gz/from/a/mirror)
4. Unpack and configure,make, install based on the apache installation you just compiled
5. Disable stocked apache server on RHEL5
6. Start apache in /usr/local/apache2 then move your site to the new apache location, then you're done.

Another wild idea is run whatever server version you have on top of RHEL5 inside a virtualization.  If your server is powerful enough, you probably won't suffer much in performance, even if you suffer a little performance hit, but you gain in compatibility of your php codes.  You can use VirtualBox, it's free.

That being said, I'm pretty sure you can compile php4 on RHEL5.  Google and found this: http://blog.stuartherbert.com/php/2007/04/04/getting-php-4-running-on-redhat-enterprise-linux-5/
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses four methods for overlaying images in a container on a web page
Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now