Yum method to install php7 extension: 1. Install epel and REMI sources; 2. Check the PHP version that can be installed and use the "yum -y install php" command to install PHP; 3. Use "yum -y install Just run the php-fpm" command to install the PHP extension.

The operating environment of this article: centos7 system, PHP version 7.4, Dell G3 computer.
yum How to install php7 extension?
Centos7 yum installation PHP7 and PHP extension installation:
1. Install epel:
#yum list installed | grep php #查看已安装的PHP,查到后rpm -e 卸载 #yum repolist all | grep php
yum install epel-release -y
2. Install REMI source:
rpm -ivh https://mirrors.tuna.tsinghua.edu.cn/remi/enterprise/remi-release-7.rpm

3. Check the PHP version that can be installed:
yum repolist all | grep php

4. Set the default installed version:
yum

5. Install PHP:
yum -y install php #查看PHP版本 php -v #查看已安装的模块 php -m
6. Check which PHP extensions can be installed:
yum search php74-php

7. Install PHP extension:
示例:安装php74-php-fpm扩展,则执行:(不用加php74-) yum -y install php-fpm

8.php-fpm command:
# 启动 systemctl start php-fpm # 停止 systemctl stop php-fpm #重启 systemctl restart php-fmp # 重载 systemctl reload php-fpm #设置开机启动 systemctl enable php-fpm #禁止开机启动 systemctl disable php-pfm

Recommended learning: "PHP Video Tutorial"
The above is the detailed content of How to install php7 extension in yum. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

SublimeText3 Linux new version
SublimeText3 Linux latest version

SAP NetWeaver Server Adapter for Eclipse
Integrate Eclipse with SAP NetWeaver application server.

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

Dreamweaver Mac version
Visual web development tools

Atom editor mac version download
The most popular open source editor






