I
FINALLY managed to update a test server using SME 8.0 to use PHP 5.5 without causing MySQL to fail after reading through some of the links here. Here is what I had to do in order to do it.
First create a new yum repository for Webtatic EL5 (not the CentOS version listed in the SME extra yum repositories documentation since that one doesn't include PHP 5.5) as follows:
/sbin/e-smith/db yum_repositories set webtatic-el5 repository \
Name 'webtatic - EL5' \
MirrorList 'http://mirror.webtatic.com/yum/el5/$basearch/mirrorlist' \
EnableGroups no \
GPGCheck yes \
GPGKey http://repo.webtatic.com/yum/RPM-GPG-KEY-webtatic-andy \
Visible no \
status disabled
signal-event yum-modify
Next install the yum replace add on from the new repository:
yum install yum-plugin-replace --enablerepo=webtatic-el5
Now you can upgrade your version of PHP to version 5.5.9 as follows:
yum replace php --replace-with=php55w --enablerepo=webtatic-el5
If you need phpMyAdmin like I did then before doing the "signal-event post-upgrade; signal-event reboot" perform one more install:
yum install php55w-mcrypt --enablerepo=webtatic-el5
The php-gettext needed by phpMyAdmin is apparently already included in the php55w-common rpm so you won't have to install it separately. Other PHP add ons such as php55w-pear are available in the Webtatic EL5 repository if you need them, you can view the list at
http://us-east.repo.webtatic.com/yum/el5/ choosing the i386 or x86_64 directories as appropriate for your server. Of course to use phpMyAdmin with this you will have to forgo the SME contribution and download the current version directly from
http://www.phpmyadmin.netTo make phpMyAdmin usable:
1) Create a new ibay specifically for phpMyAdmin (I would suggest calling it phpmyadmin) and set it with the appropriate access permissions being sure to enable dynamic content (i.e. PHP). Then delete the index.html file from the html folder of this new ibay.
2) Load the complete phpMyAdmin file set you've just downloaded into the html folder of the new ibay. The root directory for phpMyAdmin should be the ibay's html folder so load the entire CONTENTS of the phpMyAdmin folder you've downloaded into it and not the phpMyAdmin folder itself.
3) Create a new folder in /etc called phpMyAdmin and set permissions on it to at least 775.
4) Create a folder in /etc/e-smith/templates-custom named phpMyAdmin and then inside that create a folder named config.inc.php
5) Inside the new /etc/e-smith/templates-custom/phpMyAdmin/config.inc.php folder create three files, an EMPTY file named template-begin, an EMPTY file named template-end and one other file (I used the "10config" name used by the smeserver-phpmyadmin contribution where this comes from) containing the following:
<?php
/*
* Generated configuration file
* Generated by: phpMyAdmin 2.9.0.2 setup script by Michal Čihař <michal@cihar.com>
* Version: $Id: setup.php,v 1.36.2.3.2.1 2006/10/03 13:11:08 nijel Exp $
* Date: Thu, 12 Oct 2006 16:17:17 GMT
*/
/* Servers configuration */
$i = 0;
/* Server localhost (config:root) [1] */
$i++;
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['extension'] = 'mysql';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['compress'] = false;
$cfg['Servers'][$i]['auth_type'] = 'config';
$cfg['Servers'][$i]['user'] = 'root';
$cfg['Servers'][$i]['password'] = '{
open (PW, "/etc/openldap/ldap.pw")
|| die "Could not read LDAP password.\n";
my $pw = <PW>;
chomp ($pw);
close PW;
$OUT .= "$pw";
}';
/* End of servers configuration */
?>
6) expand-template /etc/phpMyAdmin/config.inc.php
7) You should now have a config.inc.php inside the /etc/phpMyAdmin folder you created. If can figure out how to get your phpMyAdmin to directly access this file you are set to go. Otherwise, do like I did and just copy the password from the file and then log in to phpMyAdmin as root using this password. In that case the very first thing to do is create a new user with all privileges and a password you can remember to use for all future access to phpMyAdmin which you will access as
http://server_url/phpmyadmin_ibay_name/After spending at least two weeks trying to figure out how to get a PHP 5.5 upgrade to work properly I figured I'd better share the information with others that might be trying to do the same thing. Besides, I expect to reuse this information myself to create a test server with PHP 5.5 at work and I wanted it to be easily accessible.