Koozali.org: home of the SME Server

Reverting PHP version?

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Reverting PHP version?
« on: November 20, 2014, 11:06:50 PM »
I have strayed from the One True Path to SME Server enlightenment, and it bit me.  Before Stephane's work on software collections, I upgraded PHP to 5.5.x from the REMI repositories to support Owncloud.  Now, the newer PHP version is causing incompatibilities with other packages, like John Bennett's Horde 5.2 package and smeserver-phpki.

So, I'm thinking now that I'll revert to the "stock" php versions, and use software collections to enable the newer php only for the apps that require it.  Could this possibly be as simple as mounting the install media and doing "yum downgrade php*"?
......

Offline stephdl

  • *
  • 1,519
  • +0/-0
    • Linux et Geekeries
Re: Reverting PHP version?
« Reply #1 on: November 21, 2014, 12:14:09 AM »
It may need a re-installation, anyway you have to think about backup if you do the mess with the downgrade.
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline janet

  • ****
  • 4,812
  • +0/-0
Re: Reverting PHP version?
« Reply #2 on: November 21, 2014, 02:08:34 AM »
DanB35

A better way that is typically used to remove newer packages & revert to standard packages, is to use
rpm -e --nodeps packagename1 packagename2 packagename3

then do
yum install packagename1 packagename2 packagename3
signal-event post-upgrade
signal-event reboot

so that current standard package versions get installed
« Last Edit: November 22, 2014, 01:44:21 AM by janet »
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Re: Reverting PHP version?
« Reply #3 on: November 21, 2014, 04:24:46 PM »
I bit the bullet, crossed my fingers, and gave it a try, and it seems to be working.  I made a list of all the REMI PHP RPMs I had installed (rpm -qa | grep php | grep remi), removed them all (rpm -e --nodeps php php-common ...), installed the PHP RPMs from the distro ISO to make sure I got them all (yum install php-*), yum update, signal-event post-upgrade, signal-event reboot.

I then installed the software collections php54 and php55 and made the appropriate settings for the owncloud and joomla ibays.  They're working as well.  Thanks for the input!
......

Offline janet

  • ****
  • 4,812
  • +0/-0
Re: Reverting PHP version?
« Reply #4 on: November 21, 2014, 04:37:25 PM »
DanB35

Quote
I then installed the software collections php54 and php55 and made the appropriate settings for the owncloud and joomla ibays.  They're working as well.

Please share with us your exact steps.
The use of Software Collections is new to most users here, so your experience will add greatly to the collective knowledge
ie
Did you follow steps in the Software Collections forum post or wiki article, what did you do to specifically tweak Owncloud & Joomla etc ?

Thanks
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline DanB35

  • ****
  • 764
  • +0/-0
    • http://www.familybrown.org
Re: Reverting PHP version?
« Reply #5 on: November 21, 2014, 05:04:53 PM »
I followed the forum post here: http://forums.contribs.org/index.php/topic,51223.msg260054.html#msg260054

The only setting I changed for owncloud and joomla was to enable php55 for them:

Code: [Select]
# db accounts setprop owncloud php55 enabled
# signal-event ibay-modify owncloud

Owncloud seems to be working without issues.  Joomla is working except for two-factor authentication, which I expect is due to the lack of php-mcrypt in the red hat software collection.  This isn't a critical issue for me, since access to the admin page on Joomla is restricted to my LAN, so I can disable it for the time being.  I haven't extensively tested either application, but both seem to work properly.
......

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: Reverting PHP version?
« Reply #6 on: November 22, 2014, 12:44:46 AM »
A better way that is typically used to remove newer packages & revert to standard packages, is to use
rpm -e packagename

Often it will be necessary to use:

rpm -e --nodeps packagename

and probably:

rpm -e --nodeps packagename1 packagename2 packagename3 ...

Quote
yum install packagename
for each package

I don't think there is a good reason not to do:

yum install packagename1 packagename2 packagename3 ...