Installing and configuring the NGINX+PHP+MYSQL environment on CentOS6.3

Source: Internet
Author: User
Tags install php

1. The current Nginx adoption is the source package installation method (Yum installation failed),: http://nginx.org/en/download.html

My installation package here is: nginx-1.12.0.tar.gz

2. Before installing Nginx, I need to install Pcre, the Pcre source package here is: pcre-8.35.tar.gz

File storage path:/home/nginx/pcre-8.35.tar.gz

Tar zxvf pcre-8.35.tar.gz

CD pcre-8.35

./configure--prefix=/usr/local/pcre

Make

Make install

3. source package installation Nginx; file storage path:/home/nginx/nginx-1.12.0.tar.gz

Tar zxvf nginx-1.12.0.tar.gz

CD nginx-1.12.0

./configure--prefix=/usr/local/nginx--without-http_memcached_module--with-http_stub_status_module -- with-pcre=/home/nginx/pcre-8.35

Note: here must add Pcre source code is located in the path, otherwise error.

Make

Make install

4. Yum install MySQL + PHP, before installing, install yum-downloadonly, download the MySQL and PHP installation package to the local and then install, convenient later set up the device can not be online.

4.1 Installing Yum-downloadonly

Yum install yum-downloadonly or yum install yum-plugin-downloadonly

4.2 Download MySQL

Yum install MySQL mysql-server mysql-devel--downloadonly--downloaddir=/home/phpmysql

4.3 Download php

Yum install php php-fpm php-mysql php-common php-gd php-mbstring php-mcrypt php-devel php-xml--downloadonly--downloaddir =/home/phpmysql/

4.4 Installing MySQL and PHP

cd/home/phpmysql/

RPM-IVH *.rpm--force

Installing and configuring the NGINX+PHP+MYSQL environment on CentOS6.3

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.