Lamp-centos 7 platform three-host FastCGI Model

Source: Internet
Author: User

Requirements:

Centos 7 lamp (PHP-FPM)

(1) The three are separated from the three hosts.

(2) one virtual host is used to provide phpMyAdmin; the other virtual host is used to provide WordPress;

(3) xcache


Lab preparation:

# Setenforce 0 # systemctl stop iptables # systemctl stop firwalld Modify file: Linux:/etc/hosts windows: \ windows \ system32 \ drivers \ etc \ hosts add content: 10.0.0.0.61 10.0.0.61


Lab Environment

The three are separated from three hosts.

host1: 10.0.0.61 httpdhost2: 10.0.0.62 php-fpmhost3: 10.0.0.63 mariadb


Host1

# yum install httpd -y


Host2

# yum install php-fpm php-mysql php-mbstring -y

Edit the configuration file:

# Vim/etc/php-fpm.d/www. conf Listen = 127.0.0.1: 9000 listen. allowed_clients = 127.0.0.1 changed to listen = 10.0.0.62: 9000 // local IP address, which port is listening to listen. allowed_clients = 10.0.0.61 // address to which access is allowed
systemctl start php-fpm


Host3

# yum install mariadb-server -y# systemctl start mariadbmysql> create user [email protected]‘10.0.0.%‘;mysql> grant all on *.* to [email protected]‘10.0.0.%‘ identified by ‘123456‘mysql> create user ‘wordpress‘@‘10.0.0.62‘;mysql> create database wordpress;mysql> grant all on wordpress.* to ‘wordpress‘@‘10.0.0.62‘ identified by ‘wordpress‘


Create a VM











Lamp-centos 7 platform three-host FastCGI Model

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.