php - 如何在 Debian 9 机器上为 PHP 7.3 安装 php-fpm?
问题描述
我正在尝试通过 ssh(使用sudo apt-get install -y php-fpm
)在 Debian 9 机器上安装 php-fpm,但出现以下错误
Package php-fpm is a virtual package provided by:
php7.4-fpm 7.4.7-1+0~20200612.18+debian9~1.gbp671911 [Not candidate version]
php7.3-fpm 7.3.19-1+0~20200612.60+debian9~1.gbp6c8fe1 [Not candidate version]
php7.2-fpm 7.2.31-1+0~20200514.41+debian9~1.gbpe2a56b [Not candidate version]
php7.1-fpm 7.1.33-16+0~20200514.38+debian9~1.gbp1e5820 [Not candidate version]
php7.0-fpm 7.0.33-29+0~20200514.36+debian9~1.gbp126f6f [Not candidate version]
php5.6-fpm 5.6.40-29+0~20200514.35+debian9~1.gbpcc49a4 [Not candidate version]
php7.3-fpm 7.3.14-1~deb10u1 [Not candidate version]
php7.3-fpm 7.3.11-1~deb10u1 [Not candidate version]
php7.0-fpm 7.0.33-0+deb9u7 [Not candidate version]
php7.0-fpm 7.0.33-0+deb9u6 [Not candidate version]
E: Package 'php-fpm' has no installation candidate
我试过sudo apt-get install -y php7.3-fpm
了,但我得到了错误:
Package php7.3-fpm is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'php7.3-fpm' has no installation candidate
目前我的 sources.list 是:
# deb http://snapshot.debian.org/archive/debian/20200224T000000Z stretch main
deb http://deb.debian.org/debian stretch main
# deb http://snapshot.debian.org/archive/debian-security/20200224T000000Z stretcc
h/updates main
deb http://security.debian.org/debian-security stretch/updates main
# deb http://snapshot.debian.org/archive/debian/20200224T000000Z stretch-updatess
main
deb http://deb.debian.org/debian stretch-updates main
有任何想法吗?
编辑:
忘了提我正在使用apache。
解决方案
也许这可以帮助
sudo apt update
sudo apt install nginx
sudo apt install ufw
apt install php-fpm
你可以在这里了解更多:https ://itdraft.ru/2019/08/27/ustanovka-nginx-i-php-fpm-na-debian-10/
推荐阅读
- c# - 数据库似乎在执行期间更新,然后更改消失
- c - 使用函数交换两个变量的值时,为什么我应该以地址而不是实际变量名为目标?
- ansible - Ansible-playbook - 如何在字符串中添加大写
- java - Maven项目中的Logback
- discord - 试图制作一个机器人来计算语音频道中的成员
- python-3.x - 比较 2 个相同大小的元组列表:比较和交换
- python - Plotly:如何针对多个其他时间序列显示一个变量的回归线?
- c# - 用于控制范围验证器或文本框最大输入双精度的复选框
- swift - SwiftUI 箭头快捷方式在 iPad 上不起作用
- c++ - 如果用户键入无效值,为什么从 cin 读取的这段代码会无限递归?