Page 3 of 4

Re: Upgrading to PHP 5.6.9

Posted: 2015/05/20 02:00:41
by Kunwar
Thanks for helping me out.... I am asking too many questions cuz I am new to Centos....

I have following packages installed:

Code: Select all

[root@parada php.d]# yum list installed | grep "php"
php56u.x86_64                          5.6.8-1.ius.centos7             @/php56u-5.6.8-1.ius.centos7.x86_64
php56u-cli.x86_64                      5.6.8-1.ius.centos7             @ius     
php56u-common.x86_64                   5.6.8-1.ius.centos7             @ius     
php56u-mysqlnd.x86_64                  5.6.8-1.ius.centos7             @/php56u-mysqlnd-5.6.8-1.ius.centos7.x86_64
php56u-pdo.x86_64                      5.6.8-1.ius.centos7             @ius     
php56u-pear.noarch                     1:1.9.5-1.ius.centos7           @ius     
php56u-pecl-jsonc.x86_64               1.3.7-1.ius.centos7             @ius     
php56u-process.x86_64                  5.6.8-1.ius.centos7             @ius     
php56u-xml.x86_64  

[root@parada php.d]# yum list installed | grep "maria"
mariadb.x86_64                         1:5.5.41-2.el7_0                @base    
mariadb-libs.x86_64                    1:5.5.41-2.el7_0                @base    
mariadb-server.x86_64                  1:5.5.41-2.el7_0                @base    

but PHP still didn't get executed... I don't know what to do.

Re: Upgrading to PHP 5.6.9

Posted: 2015/05/20 02:08:12
by gerald_clark
Httpd needs to run php56u instead of php.

Re: Upgrading to PHP 5.6.9

Posted: 2015/05/20 02:50:07
by igro
run "apachectl -M|grep -i php"
this will show loaded php module in apache or not
also see "/var/log/httpd/error.log" there may be some useful information
update: there is two error logs
error_log - log of httpd daemon
error.log - log of virtual host

Re: Upgrading to PHP 5.6.9

Posted: 2015/05/20 10:37:49
by Kunwar
I am not sure what this code does, love get more information on this but the following code worked like a charm.... My issue is resolved.

Code: Select all

yum --enablerepo=centosplus install mod_php

Re: Upgrading to PHP 5.6.9

Posted: 2015/05/23 06:43:03
by igro
it's centos plus repository.
--enablerepo means enable disabled repository and mod_php is that package that need to work apache with php (usually i saw package mod_php in ubuntu. first time see on centos :)
http://wiki.centos.org/AdditionalResour ... CentOSPlus

Re: Upgrading to PHP 5.6.9

Posted: 2015/09/04 04:12:33
by alfianz
hello,

i had problem to upgrade PHP
# rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm
Retrieving https://mirror.webtatic.com/yum/el6/latest.rpm
curl: (6) Couldn't resolve host 'mirror.webtatic.com'
error: skipping https://mirror.webtatic.com/yum/el6/latest.rpm - transfer failed
how to solve it?

Re: Upgrading to PHP 5.6.9

Posted: 2015/09/04 06:28:31
by avij
As TrevorH wrote earlier in this topic, "We do not recommend use of the Webtatic repo under any circumstances."

Perhaps you ran into some previously unknown self-defence mechanism in CentOS... Please read this entire topic for better alternatives to webtatic.

Re: Upgrading to PHP 5.6.9

Posted: 2016/01/26 10:25:09
by sadue
TrevorH wrote:The webtatic repo contains many packages with names that conflict with the names of packages in CentOS base and updates repos. This means that it replaces packages supplied by CentOS without warning. Examine your /var/log/yum.log and see what else got updated at the same time as the php packages were installed (or afterwards). Use rpm -qi $packagename to check to make sure that the buildhost is a CentOS one and that the signing key is the CentOS one for each of those.

The IUS Community repo is a better source of replacement packages since they are all named differently than the ones CentOS supply so you have to take explicit action to install them.
I am a newbie to centos and have no good knowledge of programming. All my installation is through one tutoria or the other.
Am running php 5.4 on my server, due to its incompatibility, I have to upgrade to php 5.6, which I don't know how to upgrade. Many tutorial I found on net makes use of webtatic which is not supported by centos.
I went to IUS site, but to be honest, everything that is been talked there sounds like Greek to me cos am not a programmer.

Please, can you guys help me with a detailed tutorial on how to upgrade my php from 5.4 to 5.6, so that my site can run.

Re: Upgrading to PHP 5.6.9

Posted: 2016/01/26 10:30:37
by remirepo
For obvious reason, I will not give you information about IUS

But, you can try "remi-php56" repository which only provide PHP, and nothing else. And I think is the simpler to use.

Configuration Wizard : http://rpms.remirepo.net/wizard/
Blog post about latest version : http://blog.remirepo.net/post/2016/01/0 ... 7-7.0.2-en

Re: Upgrading to PHP 5.6.9

Posted: 2016/01/26 10:40:08
by stevemowbray
To use the IUS packages in CentOS 7:

1. Install EPEL and IUS repositories:
# yum --enablerepo=extras install epel-release
# yum install https://centos7.iuscommunity.org/ius-release.rpm

2. Install yum-plugin-replace and replace the php packages with php56u packages:
# yum install yum-plugin-replace
# yum replace --replace-with php56u php

3. Restart any services which depend on php, such as httpd.

Note that this will install the current version of 5.6, which at the time of posting is 5.6.16, and that a "yum update" will keep the packages up to date in future.