devall#giga:~$ sudo apt-get install php7.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package php7.1
E: Couldn't find any package by glob 'php7.1'
E: Couldn't find any package by regex 'php7.1'
I am trying to install php 7.1 , tried almost everything...
sudo apt-add-repository ppa:ondrej/php
sudo apt-get update
reinstalled ubuntu twice.. still same error. #help
try with software-properties-common
sudo apt install software-properties-common
sudo add-apt-repository ppa:ondrej/php
sudo apt update
sudo apt search php7
sudo apt install php7.1
php -v
Related
I'm trying to install php8.0-curl on my server.
But it keeps giving me the following error:
$ sudo apt install php8.0-curl
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package php8.0-curl
E: Couldn't find any package by glob 'php8.0-curl'
I followed the following steps, but with no success.
sudo add-apt-repository ppa:ondrej/php
sudo apt update
sudo apt install curl
sudo apt install php8.0-curl
I was using the wrong repositories.
Following this answer solved the issue.
https://serverfault.com/a/1106701
I am trying install libapache2-mod-php7.3 on my ubuntu server 16.04.
I am getting below error
sudo apt install libapache2-mod-php7.3
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package libapache2-mod-php7.3
E: Couldn't find any package by glob 'libapache2-mod-php7.3'
E: Couldn't find any package by regex 'libapache2-mod-php7.3'
Please help me install the libapache2 module on my server.
Thanks
Have you tried this?
sudo add-apt-repository ppa:ondrej/php
sudo apt-get install php7.3 php7.3-cli php7.3-mysql php7.3-gd php7.3-imagick php7.3-recode php7.3-tidy php7.3-xmlrpc php7.3-common php7.3-curl php7.3-mbstring php7.3-xml php7.3-bcmath php7.3-bz2 php7.3-intl php7.3-json php7.3-readline php7.3-zip
sudo apt install libapache2-mod-php7.3
sudo a2enmod php7.3
after successfully installing, execute :
sudo service apache2 restart
FYI, I recommended you use the latest PHP or switch to the LTS version.
You can find out on https://www.php.net/supported-versions.php
After adding the ppa ondrej/php, I try sudo apt-get install php7.4, but the output is
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package php7.4
E: Couldn't find any package by glob 'php7.4'
E: Couldn't find any package by regex 'php7.4'
I have checked and there is a package that should install with that command, but I must be doing something wrong?
have you tried updating your rep?
sudo apt install software-properties-common
sudo add-apt-repository ppa:ondrej/php
sudo apt update
sudo apt install php7.4
php -v
I didn't pay enough attention, this package doesn't exist yet for ubuntu 19.04:
php7.4 7.4.2-6+ubuntu19.10.1+deb.sury.org+1 Ondrej Surý (2020-02-05)
php7.4 7.4.2-6+ubuntu18.04.1+deb.sury.org+1 Ondrej Surý (2020-02-05)
php7.4 7.4.2-6+ubuntu16.04.1+deb.sury.org+1 Ondrej Surý (2020-02-05)
I get the error from my cakephp 2.x project:
The PHP GD extension is required, but is not installed.
I use php7.3 with apache on debian
I search and find
apt-get install php7.3-gd
I tried this but i only get following error:
E: Unable to locate package php7.3-gd
E: Couldn't find any package by glob 'php7.3-gd'
E: Couldn't find any package by regex 'php7.3-gd'
I searched again, but didnt find a soulution for this problem only for ubunto and nothing else worked. I hope someone could help me with this problem.
It looks like you do not have the appropriate repo added. Try :
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install -y php7.3-gd
#Will's answer did not work for me, I then replace the first command from sudo add-apt-repository ppa:ondrej/php to sudo apt-add-repository ppa:ondrej/php and it works for me. So finally I run:
sudo apt-add-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install -y php7.3-gd
Is there a way to find and install the php5-gmp module on Ubuntu 16.04? I looked for this repository but I can't find it here. In fact, when I tried to do:
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install php5-gmp
The results is:
Unable to find php5-gmp package
Try php5.6-gmp:
sudo apt install php5.6-gmp
Obvously this will only install gmp extension for PHP5.6.
If you want it to 7.0, use the right package name:
sudo apt install php7.0-gmp