Update php on Oracle Linux Server - php

I have an Oracle Linux Server. I am trying to install PHP. PHP 5.4 installed on OLS. Is there a way to update to php 7.2? When I run yum install php it installs version 5.4.
UPDATE
I reinstall linux to ubuntu. There is no any problem on ubuntu

sudo yum install oracle-php-release-el7
sudo yum install php
See also: https://yum.oracle.com/oracle-linux-php.html

Related

how to upgrade from php 7.0 to php 7.3 on Debian 9.1

I have a Debian 9.1 droplet on DigitalOcean. 1GB Memory, 30GB Disk.
I've previously installed php 7.0 using
apt install php php-fpm
I also ran the following commands to install php modules:
apt-get install php-mysql
apt-get install php-curl
apt-get install php-zip
apt-get install php-apcu
apt-get install php-xml
How do I now upgrade from 7.0 to 7.3?
Just to give you an idea of how you can do it:
Basically, you need to follow two steps:
Install the 7.3 version as you did for 7.0 (you can pass the version number to install the exact version number)
You need to configure your PHP CLI to use the new version 7.3 instead of 7.0.
The above steps can be done for every version.
Here is documentation of how you can do it in case of migration from 7 to 8.
NOTE: The documentation will help you to install a version of PHP and configure CLI so you need to make sure to do the updates as per 7.3.
sudo-apt update
sudo apt-get install php-fpm
This will go try to update it if see you already have php-fpm...
Your repository should be updated to understand there is new version of php that is available for download
you can also remove & purge it and try to download it again...
but also consider some services needs to be updated and set to use last version of php that is currently installed...
Like Nginx ,in that you should update for .conf file to read php 7.3 or any installed versions
you can also check how many versions php do you have by going to directory by this command cd /etc/php and do ls

Can I install php-ldap 5.3.3 when my php version is 5.4.31?

I have php 5.4.31 installed on a Centos 6 machine.
When I use
yum install php-ldap
The information yum provides me after I run the command is in the picture.
So yum asks whether I want to install php-ldap version 5.3.3-49 and php-common version 5.3.3-49. Can I let yum install these suggested packages?
My server has php version 5.4.31 and I want to keep it like that for now.

How to install PHP 5.6+ on Ubuntu 12.04 using tasksel?

I recently downgraded one of my laptop from 14.04 to 12.04. Reason for downgrading operating system is speed only. 12.04 seems 10x time faster then my experience with 14.04 on my low configuration laptop. As usual I install LAMP stack using tasksel command:
$ sudo apt-get install tasksel
$ sudo apt-get update
$ sudo tasksel install lamp-server
However, this installed PHP version 5.3.10. I google to update php version and followed many suggestions including sudo apt-get update, sudo apt-get dist-upgrade and also installing latest PPA as well.
Also fllowed this answer: Php upgrade from 5.3 to php 5.6 on Ubuntu 12.04
Nothing worked so far and I am here for seeking some help.

Install php5-mcrypt on Ubuntu

I want to install the mcrypt on vagrant machine.
The OS is Ubuntu.
Which is the command?
First check php version,
E.g.
php -v
PHP 5.6.38-3+ubuntu18.04.1+deb.sury.org+1 (cli)
Currently php version is 5.6, you will need to install with below command line
sudo apt-get install php5.6-mcrypt
Output

Install PHP 5.6.2 (specific version) and mysql 5.6.17 in Ubuntu OS

Install PHP 5.6.2 (specific version) and mysql 5.6.17 in Ubuntu OS. There are ways to install LAMP, but i am looking for the specific versions. Please guide me..
OS version: Ubuntu 15.04
You can install any version using apt-get in this way:
sudo apt-get install <package-name>=<package-version-number>
You can list the versions by using this command:
apt-cache showpkg <package-name>

Categories