//yum损坏
    1、yum install gcc-c++ 报错 ———————————》 https://www.cnblogs.com/itxdm/p/5876597.html
    //安装成功 但是启动失败 ———————————-》https://www.cnblogs.com/yufeng218/p/8215421.html
    2、nginx启动报错:nginx: [error] open() “/var/run/nginx/nginx.pid” failed (2: No such file or directory) 的解决办法

    sudo /usr/sbin/nginx -c /etc/nginx/nginx.conf
    ./nginx -c /usr/local/nginx/conf/nginx.conf ——-生成pid
    3、启动成功,
    开启防火墙 ——》 关闭防火墙

    页面打不开 ——》
    nginx 403 forbidden
    404报错

    开启logger日志 ,看日志
    error_log logs/error.log;
    error_log logs/error.log notice;
    error_log logs/error.log info;
    —————————— 备份 cp nginx.conf nginxbak.conf
    5、目录介绍
    ——

    6、 一个端口,多项目部署
    https://zhuanlan.zhihu.com/p/131009164
    server {
    listen 80;
    server_name localhost;
    location / {
    root html;
    index index.html index.htm;
    }

    location /web {
    alias /home/application/web;
    index index.html index.htm;
    }

    error_page 500 502 503 504 /50x.html;
    location = /50x.html {
    root html;
    }
    }
    6、多端口演示

    server {
    listen 80;
    server_name localhost;
    location / {
    root html;
    index index.html index.htm;
    }

    location /web {
    alias /home/application/web;
    index index.html index.htm;
    }

    error_page 500 502 503 504 /50x.html;
    location = /50x.html {
    root html;
    }
    }
    server {
    listen 81;
    server_name localhost;
    location / {
    root /home/application/css04;
    index index.html index.htm;
    }

    error_page 500 502 503 504 /50x.html;
    location = /50x.html {
    root html;
    }
    }
    7、本地dns域名解析修改
    192.168.23.129 www.baimaone.com www.baimatwo.com www.ccd.com
    server {
    listen 80;
    server_name www.baimaone.com;
    location / {
    root html;
    index index.html index.htm;
    }

    location /web {
    alias /home/application/web;
    index index.html index.htm;
    }

    error_page 500 502 503 504 /50x.html;
    location = /50x.html {
    root html;
    }
    }

    8、同端口,不同域名演示
    server {
    listen 80;
    server_name www.baimaone.com;
    location / {
    root html;
    index index.html index.htm;
    }

    location /web {
    alias /home/application/web;
    index index.html index.htm;
    }

    error_page 500 502 503 504 /50x.html;
    location = /50x.html {
    root html;
    }
    }
    server {
    listen 80;
    server_name www.baimatwo.com;
    location / {
    root /home/application/css04;
    index index.html index.htm;
    }

    error_page 500 502 503 504 /50x.html;
    location = /50x.html {
    root html;
    }
    }