Celeb Glow
updates | April 04, 2026

not able to get php7 after add ppa:ondrej/php [closed]

I added the repository by this command:

LC_ALL=en_US.UTF-8 add-apt-repository ppa:ondrej/php

WARNING: add-apt-repository is broken with non-UTF-8 locales, see for workaround:

LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php
More info:
Press [ENTER] to continue or ctrl-c to cancel adding it
gpg: keyring `/tmp/tmph7kev8sf/secring.gpg' created
gpg: keyring `/tmp/tmph7kev8sf/pubring.gpg' created
gpg: requesting key E5267A6C from hkp server keyserver.ubuntu.com
gpg: /tmp/tmph7kev8sf/trustdb.gpg: trustdb created
gpg: key E5267A6C: public key "Launchpad PPA for Ondřej Surý" imported
gpg: Total number processed: 1
gpg: imported: 1 (RSA: 1)
OK

all seems good. then I run apt-cache

apt-cache search php7

which gives nothing.

this is my system information:

~# uname -a
Linux cspweb 3.13.0-123-generic #172-Ubuntu SMP Mon Jun 26 18:04:35 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
locale
LANG=en_US.UTF-8
LANGUAGE=
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

I also try

LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php

the same result. any suggestion and hints is very appreciated.

1

2 Answers

It seems ppa:ondrej/php is not support the Ubuntu 14.04 LTS according to which indicates the standard support is ended April 2019.

After I upgrade my ubuntu to 16.04 LTS, I can install the php 7.3 from the repository.

2

Once you've added a PPA you need to update APT cache before runing apt-cache or apt install.

sudo apt update
2