Install php in centos

System centos6+
1、 Since the php version in the centos default yum source is too low, it needs to be replaced
wget -q -O - http://www.atomicorp.com/installers/atomic | sh
If an error is reported, wget cannot be found, install wget:
yum install wget
2、 Install apache, mysql, php
yum install httpd
yum install mysql-server
yum install php
yum install php-gd php-mysql php-pdo php-soap php-mbstring php-xmlrpc php-dom

3、 Increase virtual host
Configuration file /etc/httpd/conf/httpd.conf, virtual host configuration is generally at the bottom
Or create a new virtual host configuration file in /etc/httpd/conf.d/, generally named virtualhosts.conf
The web root directory is generally set in /var/www/, but it can also be modified by yourself
4、 Start apache
/etc/rc.d/init.d/httpd restart
5、 Start mysql
/etc/rc.d/init.d/mysqld restart
6、 Modify the root password of mysql
mysqladmin -u root password “yourpassword”
7、 Deploy code
Put the project code in the set web directory
8 Set time zone tzselect
9 /etc/sysconfig/iptables
This is the firewall configuration file. Check if the apache port (80) in this file is open

Recommended Posts

Install php in centos
CentOS install PHP
How to install PHP7.4 in CentOS
Install MySQL5.7 in centos7
Install redis5.0 in CentOS7
1.5 Install Centos7
How to install php7.3 in centos8 custom directory
CentOS 7 yum install PHP7.3 tutorial
Install PHP in yum under CentOS, configure php-fpm service
Install JDK8 in rpm on CentOS7
Minimal install JDK 1.8 tutorial in CentOS 7
CentOS 7 install Nginx, PHP, MySQL packages
Install MySql with Docker in CentOS7
Install Percona Server database (in CentOS 8)
Install java in yum mode in Centos
How to install HDP2.6 in Centos7.2
Install Centos7 operating system in Docker
Centos install php73 fast cgi + nginx
Install and configure FreeIPA in Centos7
How to install PHP on CentOS 8
Centos6 install Python2.7.13
Centos7.3 install nginx
CentOS7.2 install Mysql5.7.13
CentOS install Redmine
Centos7 install Python 3.6.
CentOS7 install MySQL
Centos7 install protobuf
CentOS 7 install Docker
CentOS 7.4 install Zabbix 3.4
CentOS7 install Docker
Centos6.5 install Tomcat
CentOS install Python 3.6
Vmware install CentOS6
centos7 install docker-ce 18.01.0
CentOS 7.2 install MariaDB
CentOS 7 install Hadoop 3.0.0
Centos7 install Python2.7
Centos 7.6 install seleniu
CentOS 7.3 install Zabbix3
Centos7 install LAMP+PHPmyadmin
CentOS install mysql
CentOS install openjdk 1.8
CENTOS6.5 install CDH5.12.1 (1)
CentOS6 install mist.io
Centos7 install Docker
CentOS7 install mysql
centOs install rabbitMQ
CentOS 7 install MySQL 5.6
Centos7 install Nginx
CentOS6.5 install CDH5.13
Centos7 install docker18
Centos install Python3
centos7 install docker
CentOS install jdk
centos7 install nginx-rtmp
CentOS8 install MySQL8.0
Centos6.3 install KVM
CentOS install PostgreSQL 9.1
CentOS7 install mysql8
CentOS 7 install Java 1.8
CentOS8 install fastdfs6.06