Updating php72-php-fpm to the latest php 7.4 on centos 7
Try this:
sudo yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
sudo yum -y install https://rpms.remirepo.net/enterprise/remi-release-7.rpm
Enable Remi and EPEL Repository Install both previously downloaded packages and enable Remi PHP 7 repo:
sudo yum -y install yum-utils
sudo yum-config-manager --enable remi-php74
sudo yum update
sudo yum install php php-cli
You can then install additional packages example:
sudo yum install php php-cli php-fpm php-mysqlnd php-zip php-devel php-gd php-mcrypt php-mbstring php-curl php-xml php-pear php-bcmath php-json'
Now check the version php -v
You should be asked whether you would like to keep your php.ini file unchanged or not during the install.
Related videos on Youtube
Chris
Updated on September 18, 2022Comments
-
Chris over 1 year
Im a bit of a newbie at server administration and I was wondering if I could get some tips on updating my PHP version.
When I first setup my server, I followed a tutorial and managed to get php 7.2 up and going, but now I want to update the php 7.4 and im not really sure how.
I'm running a CentOS 7 box, and I setup my original PHP using the following commands;
yum install yum-utils yum install http://rpms.remirepo.net/enterprise/remi-release-7.rpm yum-config-manager --enable remi-php72 yum install php72 php-cli php72-php-fpm php72-php-gd php72-php-json php72-php-mbstring php72-php-mysqlnd php72-php-xml php72-php-xmlrpc php72-php-opcache php72-php-zip php72-php-soap php72-php-bcmath php72-php-imagick systemctl start php72-php-fpm systemctl enable php72-php-fpm
There were some files edited as well, for instance;
/etc/opt/remi/php72/php.ini /etc/opt/remi/php72/php-fpm.d/www.conf
Any help would be really greatly appreciated.
-
Remi Collet over 4 yearsas always.... simply follow the Wizard instructions... rpms.remirepo.net/wizard
-
Luis Alfredo Serrano Díaz almost 4 yearsError: Problem: package remi-release-7.7-2.el7.remi.noarch requires epel-release = 7, but none of the providers can be installed