zoukankan      html  css  js  c++  java
  • zabbix学习-安装nginx

    zabbix服务端采用LNMP或者LAMP,我这里安装nginx,版本是nginx-1.12.1

    需要提前安装的包,opssl,openssl-devel,pcre,pcre-devel,gcc*.

    现将压缩包上传到linux服务器上,安装命令

    ./configure --prefix=/usr/local/nginx-1.12.1 --with-http_ssl_module --with-http_v2_module --with-http_stub_status_module --with-pcre

    其中/usr/local/nginx-1.12.1 是指nginx的安装路径

    上述命令执行完毕后,如果没有报错,接着执行make   make install

    安装完成后,执行命令curl -s http://localhost,如下:

    [root@zabbixserver nginx-1.12.1]# curl -s http://localhost
    <!DOCTYPE html>
    <html>
    <head>
    <title>Welcome to nginx!</title>
    <style>
        body {
             35em;
            margin: 0 auto;
            font-family: Tahoma, Verdana, Arial, sans-serif;
        }
    </style>
    </head>
    <body>
    <h1>Welcome to nginx!</h1>
    <p>If you see this page, the nginx web server is successfully installed and
    working. Further configuration is required.</p>
    
    <p>For online documentation and support please refer to
    <a href="http://nginx.org/">nginx.org</a>.<br/>
    Commercial support is available at
    <a href="http://nginx.com/">nginx.com</a>.</p>
    
    <p><em>Thank you for using nginx.</em></p>
    </body>
    </html> 

    或者在浏览器里访问:主机IP

    启动:

    /usr/local/nginx-1.12.1/sbin/nginx

    关闭:

    /usr/local/nginx-1.12.1/sbin/nginx -s stop

    重置:(当配置文件更改时,可以不用重启来让新的配置生效)

    /usr/local/nginx-1.12.1/sbin/nginx -s reload

    ------------先简单安装,后面再研究----------

  • 相关阅读:
    OpenJudge 2738 浮点数加法
    OpenJudge 2809 计算2的N次方
    OpenJudge / Poj 1003 Hangover
    OpenJudge 2706 麦森数
    模板:大整数除法
    OpenJudge 2737 大整数除法
    模板:大整数减法
    ES Field Collapsing 字段折叠使用详解
    ES aggregation详解
    一个一站式流式处理云平台解决方案
  • 原文地址:https://www.cnblogs.com/cq90/p/7221568.html
Copyright © 2011-2022 走看看