The process of constructing nginx under CentOS

Source: Internet
Author: User
Tags install openssl centos nginx load balancing

Today it's just a simple nginx, and it doesn't use the functionality, and it's going to be a document about Nginx load balancing and reverse proxies.

At the same time, if you can see that there are not many places in the document, please ask, thank you first.

First, download

To build a nginx, you need to install a few packages to create an environment.

These packages can be installed directly with Yum, configure the Yum warehouse, and execute the command:

Yum-y Install openssl*

Yum-y Install gcc*

Yum-y Install pcre*

After loading, you can download the Nginx source package to install.

Nginx Download Address: http://nginx.org/en/download.html

I'm under the latest 1.1.16.

Second, the installation

1, TAR-ZXVF nginx-1.1.16.tar.gz will extract the Nginx source code to open

2, CD nginx-1.1.16 into the Nginx ' catalogue

3./configure--prefix=/usr/local/nginx configures Nginx to/usr/local/nginx directory

Of course./configure also has a lot of parameters, specific can be used:./configure--help View.

4, make && make install

The following figure:

Startup method:/usr/local/nginx/sbin/nginx

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.