我的ubuntu版本:
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 21.10
Release: 21.10
Codename: impish
ppa:ondrej/php
现在,我正在尝试使用以下命令添加存储库:
$ sudo apt install software-properties-common
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
software-properties-common is already the newest version (0.99.13).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
sudo add-apt-repository ppa:ondrej/php
PPA publishes dbgsym, you may need to include 'main/debug' component
Repository: 'deb http://ppa.launchpad.net/ondrej/php/ubuntu/ impish main'
Description:
Co-installable PHP versions: PHP 5.6, PHP 7.x and most requested extensions are included. Only Supported Versions of PHP (http://php.net/supported-versions.php) for Supported Ubuntu Releases (https://wiki.ubuntu.com/Releases) are provided. Don't ask for end-of-life PHP versions or Ubuntu release, they won't be provided.
Debian oldstable and stable packages are provided as well: https://deb.sury.org/#debian-dpa
You can get more information about the packages at https://deb.sury.org
IMPORTANT: The <foo>-backports is now required on older Ubuntu releases.
BUGS&FEATURES: This PPA now has a issue tracker:
https://deb.sury.org/#bug-reporting
CAVEATS:
1. If you are using php-gearman, you need to add ppa:ondrej/pkg-gearman
2. If you are using apache2, you are advised to add ppa:ondrej/apache2
3. If you are using nginx, you are advised to add ppa:ondrej/nginx-mainline
or ppa:ondrej/nginx
PLEASE READ: If you like my work and want to give me a little motivation, please consider donating regularly: https://donate.sury.org/
WARNING: add-apt-repository is broken with non-UTF-8 locales, see
https://github.com/oerdnj/deb.sury.org/issues/56 for workaround:
# LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php
More info: https://launchpad.net/~ondrej/+archive/ubuntu/php
Adding repository.
Press [ENTER] to continue or Ctrl-c to cancel.
Adding deb entry to /etc/apt/sources.list.d/ondrej-ubuntu-php-impish.list
Adding disabled deb-src entry to /etc/apt/sources.list.d/ondrej-ubuntu-php-impish.list
Adding key to /etc/apt/trusted.gpg.d/ondrej-ubuntu-php.gpg with fingerprint 14AA40EC0831756756D7F66C4F4EA0AAE5267A6C
Hit:1 https://dl.google.com/linux/chrome/deb stable InRelease
Get:2 http://security.ubuntu.com/ubuntu impish-security InRelease [90.7 kB]
Hit:3 http://ae.archive.ubuntu.com/ubuntu impish InRelease
Hit:4 http://ae.archive.ubuntu.com/ubuntu hirsute InRelease
Get:5 http://ae.archive.ubuntu.com/ubuntu impish-updates InRelease [90.7 kB]
Hit:6 http://ae.archive.ubuntu.com/ubuntu impish-backports InRelease
Ign:7 http://ppa.launchpad.net/ondrej/php/ubuntu impish InRelease
Err:8 http://ppa.launchpad.net/ondrej/php/ubuntu impish Release
404 Not Found [IP: 91.189.95.85 80]
Reading package lists... Done
E: The repository 'http://ppa.launchpad.net/ondrej/php/ubuntu impish Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
如您所见,它给出了错误消息 E:存储库“http://ppa.launchpad.net/ondrej/php/ubuntu impish Release”没有 Release 文件。
我无法使用以下命令安装 php 7.4sudo apt-get install php7.4
我的问题是如何在这个版本的 Ubuntu 上安装 php 7.4?
答案1
您必须等到这个新 Ubuntu 版本的软件包在 OndrejSury 存储库中发布。
https://launchpad.net/~ondrej/+archive/ubuntu/php?field.series_filter=
如果你现在看,他目前支持版本 18.04(bionic)、20.04(focal)和 21.04(hirsute)。
当他添加 21.10(impish)的软件包时,您将能够添加这个存储库。