Nginx for Windows installation

Source: Internet
Author: User
Tags log log

An. Nginx for Windows installation address:

Http://nginx.org/en/download.html

Two. Nginx Installation Address:

Http://nginx.org/en/docs/windows.html

Three. Start the installation

1. Unzip the downloaded Nginx file

NGINX directory structure: conf: Config file

HTML: The default resource file

LOG: Access log and error log

2. Open the DOS command, locate the Nginx folder and start the Nginx

  

If there is an error, you can check the log log in the Error.log file

3. View Nginx-initiated processes

  

You can see there are two processes, one is the main process, one is the worker process

4. Other Nginx commands

Nginx-s Stop Fast Shutdown process

Nginx-s quit gracefully closes the process. The difference with Nginx-s stop is that when there is a request to be processed in the process, the Execute QUIT command does not immediately abandon the processing of the request, but continues processing the requested request, then closes the process, and no longer accepts the new request. The stop command exits immediately, even if there is a request in the process and is no longer processed.

Nginx-s Reload when the configuration file is modified, executing this command restarts a new worker process and gracefully shuts down the old worker process for the purpose of hot start.

Nginx-s Reopen restart log file

5. The current nginx does not support UDP proxy, a worker thread maximum concurrent connection 1024, a worker process only one thread, this thread is asynchronous non-blocking mode to achieve high concurrency purposes. Typically, a master process is started, and the number of worker processes is equal to the number of cups cores.

Four. Test Nginx

To access http://localhost:8080/index.html, I have modified the port number of the nginx.conf file, and the location of the root directory, access to the URL is: http://localhost:8090/index.html

Configuration of nginx.conf in conf file

Nginx for Windows installation

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.