Solved

PHP 4 - Linux Red Hat Enterprise 5

Posted on 2009-05-10
4
945 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

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

This article will explain how to display the first page of your Microsoft Word documents (e.g. .doc, .docx, etc...) as images in a web page programatically. I have scoured the web on a way to do this unsuccessfully. The goal is to produce something …
Part of the Global Positioning System A geocode (https://developers.google.com/maps/documentation/geocoding/) is the major subset of a GPS coordinate (http://en.wikipedia.org/wiki/Global_Positioning_System), the other parts being the altitude and t…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

705 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

20 Experts available now in Live!

Get 1:1 Help Now