Reference resources :
install :
apt-get install python-software-properties
add-apt-repository ppa:nginx/stable
apt-get update
apt-get install nginx
To configure :
vi /etc/nginx/nginx.conf
Important lines :
#include /etc/nginx/sites-enabled/*; 
#error_log /var/log/nginx/error.log;
vi /etc/nginx/sites-available/default
Important lines :
root /var/www/html;
index  index.php index.html index.htm index.nginx-debian.html;
location ~ \.php$ {
                try_files $uri =404;
                fastcgi_pass unix: /var/run/php5-fpm.sock;
                fastcgi_index index.php;
                fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
                include fastcgi_params;

1. Nginx More articles about

  1. accept_mutex Relationship with performance (nginx)

    notes : Running environment CentOS 6+   background       On the right to start 20 individual worker Of nginx It was found during the stress test that : If the configuration file event In the configuration block accept_mutex Switch on (1.11.3 edition ...

  2. nginx Configure the reverse proxy or jump to appear 400 Problem handling records

    After lunch break and work , Colleagues said that the test site access interface appeared 400 Bad Request  Request Header Or Cookie Too Large Tips , Fortunately, there was a problem with the test server , The impact is not big , But hurry up ...

  3. 【 Large scale website technology practice 】 Elementary chapter : With the help of Nginx Build a reverse proxy server

    One . Reverse proxy :Web Server's “ agent ” 1.1 Initial impression of reverse agent Reverse proxy (Reverse Proxy) Method is to accept as a proxy server internet Connection request on , Then forward the request to the server on the internal network , And will be taken from ...

  4. Docker Note 1 : be based on Docker The container builds and runs nginx + php + mysql ( mariadb ) Service environment

    First of all, why write your own Dockerfile To build  nginx.php.mariadb These three mirrors ? First, we hope to have a deeper understanding of Dockerfile Use , So we can have a preliminary understanding of docker How the image is constructed : Second, hope for the future ...

  5. nginx+php Use

    From the original :windows The configuration nginx+php Environmental Science Follow his steps , Close test available ! But some people may be confused about the root directory he said later . In fact, it was set when it was set : The root of the website is www This directory , If you don't create it, please do it yourself ...

  6. nginx Use

    1.nginx The download Unzip the file directory : 2.nginx Common commands nginx -s stop closed  nginx -s quit Safe shutdown  nginx -s reload When changing the configuration file , heavy ...

  7. nginx+iis+redis+Task.MainForm Build a distributed architecture And (redis Storing distributed shared session And share session Operation process )

    This time share is to use windows+nginx+iis+redis+Task.MainForm Build a distributed architecture , The last sharing article was made in windows The use of nginx, It's usually officially released in linux Matching ...

  8. windows+nginx+iis+redis+Task.MainForm Build a distributed architecture And (nginx+iis Build service cluster )

    This time share is to use windows+nginx+iis+redis+Task.MainForm Build a distributed architecture , It can be seen from the title that this content can not be finished by a sharing article , So I'm going to share a few articles to explain , Step by step to achieve sub ...

  9. nginx Source code analysis module initialization

    stay nginx During startup , Module initialization is an important part of the whole startup process , And understand the process of module initialization, corresponding to the specific analysis of each module will have a multiplier effect . in my opinion , Analysis of the source code to understand the initialization of the module is the most direct , So the main thing is ...

  10. Nginx How to handle a request

    Looked at the nginx Official documents of , among nginx How to deal with a request is very good , Now post it to share .Nginx First select which virtual host will handle the request . Let's start with a simple configuration ( All of them 3 All the virtual hosts are on the port *:80 On the monitor ...

Random recommendation

  1. html,if Label use

    $vo.auth_id eq $vo2.auth_pid Error reporting cannot be used condition Access variables inside , It can't be in the form of dots , Should use the [''] Form access

  2. Delphi FindowWindow,FindowWindowEx

    unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms ...

  3. Reprint —— There are three 50 The state of life of an American programmer is related to IT Career Fantasy

    Tomorrow is national day , I don't want to work too hard today ! Write an essay about a business trip to the United States , Compared to the United States 50 Multi year old programmers and most 50 Many years old, domestic parents' living condition has the feeling . A few years ago, I had a chance to go on a business trip to the United States , The location is in the United States ...

  4. Part 6 AngularJS ng repeat directive

    ng-repeat is similar to foreach loop in C#. Let us understand this with an example. Here is what we ...

  5. Expand Fitnesse Of ScriptTable: Support if-then

    Fitnesse Of ScriptTable Only all lines can be executed in sequence , This blog introduces how to make ScriptTable Support if-then, To conditionally execute a line . First, popularize the concept , What is? Fitnesse, Listen to .NET edition Cuc ...

  6. Learn safety from scratch ( 15、 ... and )●DHCP service

    DHCP, Full name :Dynamic Host Configuration Protocol, Dynamic Host Configuration Protocol , It is based on UDP LAN protocol for , Its main functions are : Automatically assign IP Address , The administrator manages the internal ...

  7. 【BZOJ1095】【ZJOI2007】 hide-and-seek [ Dynamic point differentiation ]

    Answer key : It seems to be relatively simple For each barycenter, the next barycenter is connected to the edge What is the height of the tree log Of We maintain two pieces of information for each layer 1. The distance from all nodes to the center of gravity of the upper layer 2. All the sons of 1 The top of the pile In addition, open a general stack Maintain each layer the longest + Second in command Changes are ...

  8. C++ The construction execution order of multiple inheritance

    One class , It might have a base class , There may also be multiple base classes , These classes may also be virtual base classes , And there may be object members in the class itself . So in what order do the class or object members involved call their respective constructors ? Today, let's take an example to analyze . ...

  9. 【webstorm】 Registration code Update notes

    20190225 1. modify hosts file ,windows Of hosts The file path is   C:\ Windows \ System32 \ drivers \ etc \ hosts acco ...

  10. vue:vue-resource

    vue-resource Is a very light weight for handling HTTP Plug in requested , It provides two ways to deal with HTTP request : Use Vue.http or this.$http: Use Vue.resource or this.$res ...