Install Nginx on CentOS7 and nginx on centos7
Due to practical needs, I learned a little bit about "nginx" during this period ". We will not discuss nginx any more. http://wiki.nginx.org/mainwill provide a detailed introduction to zookeeper installation.
I am used to downloading the source code from the official website. http://nginx.org/, we can see that nginxis still very popular. Today, it is, and the latest version is already 07-14, mainly including stable and mainline versions.
The stable version I selected for 1.8.0. The software is a little smaller than kb. Download to the host directly on the webpage. You can also download wget at http://nginx.org/download/nginx-1.8.0.tar.gz
tar -xf nginx-1.8.0.tar.gz
Use tar unzip, unzip after, enter the directory can install according to the instructions of the official website (http://wiki.nginx.org/Install)
I also manually paste the text version operation steps. If you are too lazy to do so, press ctrl + C:
./configure
make
sudo make install
Some configuration can be performed for./configure, and I have not studied it in detail. I will add it when I use it later. First fill in a hole here.
Nginx installation is complete. Some minor errors may occur in some earlier versions of linux, but there is nothing to roll back. You may need to install openssl, pure, and CentOS7, the installation is also simple. After the installation is complete, there are four more directories under the directory you specified. We will start nginx in sbin:
The "Permission denied" error occurs, which is obviously a Permission issue. If you are familiar with Linux, you will not be surprised because Linux has strict permissions. In the figure, port 80 is used for bind, linux requires the root permission to use the port lower than 1024. The solution is also very simple. Find the configuration file nginx below. conf: Change the port.
Use nginx-s reload to reload the configuration file. A welcome page is displayed when you access the browser.
The entire process is very simple, enjoy!