How to install php 7.x on CentOS 7
Step 1: Setup the Webtatic YUM repo
Precompiled PHP 7.x binaries are available for CentOS 7 from the Webtatic, IUS, or Remi’s RPM repositories.
Below are instructions on installing PHP 7.x using the Webtatic YUM repo.
Setup the Webtatic YUM repo:
sudo rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
sudo rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
Step 2: Install PHP 7.1 and necessary extensions
Install PHP 7.1 and some of the most commonly used extensions:
sudo yum install -y mod_php71w php71w-cli php71w-common php71w-gd php71w-mbstring php71w-mcrypt php71w-mysqlnd php71w-xml
Note: The above packages are for general purpose use and may not suit your specific requirements. You should confirm the packages to be installed referring to the Webtatic PHP 7.1 introduction page.
Alternatively, if you want to install PHP 7.0, you should refer to Webtatic PHP 7.0 introduction page.
Step 3: configure PHP 7.x
After the installation, the PHP 7.x configuration file will be saved as /etc/php.ini. If necessary, you can use the vi text editor to modify it:
sudo cp /etc/php.ini /etc/php.ini.bak
sudo vi /etc/php.ini
Remember to restart your web server after modifying the /etc/php.ini file.
For Apache:
sudo systemctl restart httpd.service
For Nginx:
sudo systemctl restart nginx.service php-fpm.service
That’s it. Thanks for reading.
How to install php 7.x on CentOS 7的更多相关文章
- Install FFMPEG and FFMPEG-PHP in CentOS 6 with Virtualmin
Install FFMPEG and FFMPEG-PHP in CentOS 6 with Virtualmin 1 year ago - by Daniel - howto centos v ...
- Install Erlang and Elixir in CentOS 7
In this tutorial, we will be discussing about how to install Erlang and Elixir in CentOS 7 minimal s ...
- Install Maya 2015 x64 in CentOS 7
Thanks for Must(QQ ID)'s big help for installing Maya in CentOS7. This is my steps for installing ma ...
- How to install Wordpress 4.0 on CentOS 7.0
This document describes how to install and configure Wordpress 4.0 on CentOS 7.0. WordPress started ...
- How to install GSL on linux(ubuntu,centos,redhat)
Test: ftp://ftp.gnu.org/gnu/gsl/gsl-1.15.tar.gz success. ftp://ftp.gnu.org/gnu/gsl/gsl-1.13.0.tar.g ...
- How To install FFMPEG, FLVTOOL2, MP4Box on CentOS server 2015 easy method
for i386:wget http://pkgs.repoforge.org/rpmforge-release/rpmforge-release-0.5.3-1.el6.rf.i686.rpmrpm ...
- Install TightVNC Server in RHEL/CentOS and Fedora to Access Remote Desktops
Virtual Networking Computing (VNC) is a Kind of remote sharing system that makes it possible to take ...
- How to install Redis 3.2 on CentOS 6 and 7
What is Redis? Redis is a flexible open-source, key value data store, used as a database, cache and ...
- [转载]How To Install Nginx And PHP-FPM On CentOS 6 Via Yum
http://www.lifelinux.com/how-to-install-nginx-and-php-fpm-on-centos-6-via-yum/ http://blog.csdn.net/ ...
- Install Haskell on Ubuntu and CentOS
For Ubuntu: Step one: Install GHC If you don't want to install curl you can skip step 1 and just dir ...
随机推荐
- 曾经跳过的坑------JS中对象与结构体的声明和调用
直接上代码 正确的写法 //同一个ready方法中var viewModel = { // self.projectCode = PROJECT_CODE; BOOKEDCOUNT : 5, TOTA ...
- Android:日常学习笔记(8)———探究UI开发(2)
Android:日常学习笔记(8)———探究UI开发(2) 对话框 说明: 对话框是提示用户作出决定或输入额外信息的小窗口. 对话框不会填充屏幕,通常用于需要用户采取行动才能继续执行的模式事件. 提示 ...
- 17南宁区域赛 J - Rearrangement 【规律】
题目链接 https://nanti.jisuanke.com/t/19976 题意 给出 一个n 然后 给出 2*n 个数 可以重新排列成两行 然后 相邻的两个数 加起来 不能被三整除 可以上下相邻 ...
- PAT 天梯赛 L1-038. 新世界 【水】
题目链接 https://www.patest.cn/contests/gplt/L1-038 AC代码 #include <iostream> #include <cstdio&g ...
- Kafka Confluent
今天我们要讲的大数据公司叫作Confluent,这个公司是前LinkedIn员工出来后联合创办的,而创业的基础是一款叫作Apache Kafka的开源软件. Confluen联合创始人Jun Rao即 ...
- 每天一个Linux命令(48)ping命令
ping命令用来测试主机之间网络的连通性. (1)用法: 用法: ping [参数] [主机名或IP地址] (2)功能: 功能: 确定网络和各外部主机的状态 ...
- JAVA中的Token 基于Token的身份验证
最近在做项目开始,涉及到服务器与安卓之间的接口开发,在此开发过程中发现了安卓与一般浏览器不同,安卓在每次发送请求的时候并不会带上上一次请求的SessionId,导致服务器每次接收安卓发送的请求访问时都 ...
- Qt移植对USB鼠标键盘、触摸屏的支持
.USB键盘 经过一番搜索,发现对Qt键盘的支持主要关系到两个方面: 1. 键盘类型确定: 4.7以前的Qt版本,如果是PS2圆孔键盘,Qt编译时需加上选项:-qt-kbd-vr41xx(未测试):如 ...
- wifidog源码分析 - wifidog原理 tiger
转:http://www.cnblogs.com/tolimit/p/4223644.html wifidog源码分析 - wifidog原理 wifidog是一个用于配合认证服务器实现无线网页认证功 ...
- html5-entities.js消失问题
今天用nuxt做项目时,启动npm run dev,项目正常启动, 可过一会儿再试图启动时却报错: * ./libhtml5-entities.js in ./~/html-entities/inde ...