L
L
lapka-admin2018-04-18 20:16:15
PHP
lapka-admin, 2018-04-18 20:16:15

How to install PHP 7.2 on Ubuntu?

The system was just installed by Ubuntu 16.04 php -v command not found means everything is ok.
Further, for example:

sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install php7.2-cli

Mistake:
Reading package lists... Done
Building dependency tree... Done
E: Unable to locate package php7.2-cli
E: Couldn't find any package by glob 'php7.2-cli'
E: Couldn't find any package by regex 'php7.2-cli'

Ok, php 7 seems to be in the official turnips, I do: sudo apt show php
Errors:
N: Unable to locate package php
N: Unable to locate package php
E: No packages found

The same result when apt install php
I somehow use the package manager incorrectly or what should I do first? Turnips update?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
M
Maxim Timofeev, 2018-04-18
@webinar

https://askubuntu.com/questions/705880/how-to-inst...

P
Pavel, 2018-04-18
@PavelMonro

Well basically:
This will install:
libapache2-mod-php7.2
libargon2-0
libsodium23
libssl1.1
php7.2-cli
php7.2-common
php7.2-json
php7.2-opcache
php7.2-readline

P
Pantene742, 2018-04-18
@Pantene742

A very good article on Digital Oceans fits Ubuntu exactly. I put the first time in my life on a remote server without a graph. shells. There's an article on how to install a LAMP stack + Wordpress / Also PHP and PHP modules my Admin
Googled ...... Do it very slowly and carefully. better do it in 4 hours but the first time.
https://www.digitalocean.com/community/tutorials/h...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question