Friday, June 12, 2009

Installing XAMPP on 64bit RHEL

Today I had to install Apache on 64bit RHEL mahine.
Since my machines did't have compiler installed, I got a binary distribution (rpm) and tried install hoping it would be a quick fix.

And the reponse I got was:

[root@localhost apache]# rpm -ivh httpd-2.2.2-1.x86_64.rpm

warning: httpd-2.2.2-1.x86_64.rpm: Header V3 DSA signature: NOKEY, key ID 751d7f27 error: Failed dependencies:
apr >= 1.2.0 is needed by httpd-2.2.2-1.x86_64
apr-util >= 1.2.0 is needed by httpd-2.2.2-1.x86_64
libapr-1.so.0()(64bit) is needed by httpd-2.2.2-1.x86_64
libaprutil-1.so.0()(64bit) is needed by httpd-2.2.2-1.x86_64
libcrypto.so.4()(64bit) is needed by httpd-2.2.2-1.x86_64
liblber-2.2.so.7()(64bit) is needed by httpd-2.2.2-1.x86_64
libldap-2.2.so.7()(64bit) is needed by httpd-2.2.2-1.x86_64
libpq.so.3()(64bit) is needed by httpd-2.2.2-1.x86_64
libssl.so.4()(64bit) is needed by httpd-2.2.2-1.x86_64

I googled and got some information from this blog
I went ahead and downloaded XAMPP package for linux, installed and ran it and what I got was:

[root@localhost lampp]# ./lampp start
XAMPP is currently only availably as 32 bit application. Please use a 32 bit compatibility library for your system.

Essentially, it was saying lampp was meant for only 32bit applications and my OS was 64bit,
to be precise Linux 2.6.18-53.el5 #1 SMP Wed Oct 10 16:34:19 EDT 2007 x86_64 x86_64 x86_64 GNU/Linux

searching on the web I could only find workarounds for ubuntu and not anything for RHEL.

The workaround for RHEL was to commented out the 64bit check in the lampp executable script as:

=================
# XAMPP is currently 32 bit only
#case `uname -m` in
# *_64)
# if /opt/lampp/bin/php -v > /dev/null 2>&1
# then
# :
# else
# $de && echo "XAMPP gibt es zur Zeit nur als 32-Bit Applikation. Bitte verwende eine 32-Bit Kompatibilitaetsbibliothek fuer Dein System."
# $de || echo "XAMPP is currently only availably as 32 bit application. Please use a 32 bit compatibility library for your system."
# exit
# fi
# ;;
#esac
================

Once that is done, I had no issues in starting my Apache, Mysql and PHP engines.

[root@localhost lampp]# ./lampp start
Starting XAMPP for Linux 1.7.1...
XAMPP: Starting Apache with SSL (and PHP5)...
XAMPP: Starting MySQL...
XAMPP: Starting ProFTPD...
XAMPP for Linux started.

3 comments:

Paul said...

The trick is on the lampp executable. commented out the 64bit check and worked fine.
Thanks for the hint.

Anonymous said...

commented out. worked like a champ
cheers

Anonymous said...

Thank you so much finally got it working