Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Explain in detail the two ways to install PHP in YUM under Centos

2025-04-05 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

When installing PHP under Centos, it has been implemented in two ways, and now it is sorted out for recording.

Abstract

Generally, we use source code installation or RPM package installation to install software under Centos, and sometimes it is easier to use YUM source.

There is a special place to install PHP, which has two YUM sources to choose from

Install and upgrade PHP in Webtatic mode

Install the webtatic source

[root@i-bskmtj6q ~] # rpm-Uvh https://mirror.webtatic.com/yum/el6/latest.rpmRetrieving https://mirror.webtatic.com/yum/el6/latest.rpmPreparing... # 1:webtatic-release # [root@i-bskmtj6q] # ls-l / etc/yum .repos.d / webtatic*-rw-r--r-- 1 root root 963 Nov 13 2016 / etc/yum.repos.d/webtatic-archive.repo-rw-r--r-- 1 root root 865 Nov 13 2016 / etc/yum.repos.d/webtatic.repo-rw-r--r-- 1 root root 963 Nov 13 2016 / etc/yum.repos.d/webtatic-testing.repo

Install or upgrade PHP

# # install yum-enablerepo=remi install php php-* # # updateyum-enablerepo=remi update php php-*

Install and upgrade PHP in REMI mode

There is a special place in the REMI source that must be installed before installing it.

[root@i-bskmtj6q ~] # rpm-Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpmRetrieving http://rpms.famillecollet.com/enterprise/remi-release-6.rpmerror: Failed dependencies: epel-release = 6 is needed by remi-release-6.9-1.el6.remi.noarch

Install the REMI source

[root@i-bskmtj6q ~] # rpm-ivh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpmRetrieving https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpmPreparing... # [100%] 1:epel-release # [100%] [root@i-bskmtj6q] # rpm-Uvh http:/ / rpms.famillecollet.com/enterprise/remi-release-6.rpmRetrieving http://rpms.famillecollet.com/enterprise/remi-release-6.rpmPreparing... # 1:remi-release # [root@i-bskmtj6q] # ls-l / etc/ Yum.repos.d/remi*-rw-r--r-- 1 root root 457 Jun 30 20:13 / etc/yum.repos.d/remi-php54.repo-rw-r--r-- 1 root root 1316 Jun 30 20:13 / etc/yum.repos.d/remi-php70.repo-rw-r--r-- 1 root root 1316 Jun 30 20:13 / etc/yum.repos.d/remi-php71.repo-rw-r--r-- 1 root root 1316 Jun 30 20 : 13 / etc/yum.repos.d/remi-php72.repo-rw-r--r-- 1 root root 2609 Jun 30 20:13 / etc/yum.repos.d/remi.repo-rw-r--r-- 1 root root 751 Jun 30 20:13 / etc/yum.repos.d/remi-safe.repo

Install or upgrade PHP

# # install yum-enablerepo=webtatic install php php-* # # updateyum-enablerepo=webtatic update php php-*

Description

1 、 EPEL

Extra Packages for Enterprise Linux, that is, the extended software source for enterprise Linux, is suitable for RHEL,CentOS,Scientific Linux systems.

2 、 remi

Software sources provide up-to-date software support for old fedora versions, as well as up-to-date software for Centos and RHEL

The icon on the official website may be mainly related to the installation and upgrade of PHP (personal guess)

3 、 Webtatic

The Webtatic Yum repository is a CentOS/RHEL repository containing updated web-related packages. Mainly supply the latest LAMP and other software sources

Refer to the official website to introduce https://webtatic.com/projects/yum-repository/

The above is the whole content of this article, I hope it will be helpful to your study, and I also hope that you will support it.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report