zoukankan      html  css  js  c++  java
  • nginx+phpfpm+mysql 高性能环境搭建

    首先下载nginx,pcre,

    首先安装pcre  

    [xxxxx@xxxxx.com]#tar zxvf pcre-7.2.tar.gz
    [xxxxx@xxxxx.com]#cd pcre-7.2/
    [xxxxx@xxxxx.com]#./configure
    [xxxxx@xxxxx.com]#make && make install
    [xxxxx@xxxxx.com]#cd ../

    libtool: line 990: g++: command not found 

    运行 apt-get install build-essential解决

    编译nginx

    ./configure –user=root –group=root –prefix=/home/admin/nginx –with-openssl=/usr/include/openssl –with-pcre=/usr/local/lib –with-http_stub_status_module

    在这里,需要说明一下,由于Nginx的配置文件中我想用到正则,所以需要 pcre 模块的支持。上面安装步骤里我已经安装了 pcre 及 pcre-devel 的rpm包,但是 Ngxin 并不能正确找到 .h/.so/.a/.la 文件,因此我稍微变通了一下:

    [xxxxx@xxxxx.com]#mkdir /usr/include/pcre/.libs/
    [xxxxx@xxxxx.com]#cp /usr/local/lib/libpcre.a /usr/include/pcre/.libs/libpcre.a
    [xxxxx@xxxxx.com]#cp /usr/local/lib/libpcre.a /usr/include/pcre/.libs/libpcre.la
    [xxxxx@xxxxx.com]#cp /usr/local/lib/libpcre.a /usr/include/pcre/libpcre.a
    [xxxxx@xxxxx.com]#cp /usr/local/lib/libpcre.a /usr/include/pcre/libpcre.la
    然后,修改 objs/Makefile 大概在908行的位置上,注释掉以下内容:

    ./configure –disable-shared

    接下来,就可以正常执行 make 及 make install 了。

  • 相关阅读:
    第04组 Beta冲刺 (2/5)
    第04组 Beta冲刺 (1/6)
    第04组 Alpha冲刺 总结
    二叉树的递归与非递归
    各类典例模板
    选择题合辑2
    运算符重载
    链表题目
    集合的模拟实现(类模板)
    2018Final静态成员(黑名单)
  • 原文地址:https://www.cnblogs.com/mashuaimama/p/2442686.html
Copyright © 2011-2022 走看看