search
HomeBackend DevelopmentPHP7How to install php7 extension in yum

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.

How to install php7 extension in yum

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!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
WWE 2K25: How To Unlock Everything In MyRise
1 months agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

SublimeText3 Linux new version

SublimeText3 Linux new version

SublimeText3 Linux latest version

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools

Atom editor mac version download

Atom editor mac version download

The most popular open source editor