第一步:首先下载依赖包

下载地址 pcre(www.pcre.org),zlib(www.zlib.org),openssl(www.openssl.org)

第二步:上传那个nginx的安装包

下载nginx安装包,解压

[bdctool@localhost setup]$ tar  -zxvf nginx-1.12.2.tar.gz

[bdctool@localhost setup]$ ./configure  --with-http_stub_status_module --prefix=/opt/aspire/product/bdctool/nginx

报错

./configure: error: the HTTP rewrite module requires the PCRE library.
You can either disable the module by using --without-http_rewrite_module
option, or install the PCRE library into the system, or build the PCRE library
statically from the source with nginx by using --with-pcre=<path> option.

3、还是安装一下pcre吧

[bdctool@localhost setup]$ unzip  pcre-8.10.zip

[bdctool@localhost setup]$ cd  pcre-8.10

[bdctool@localhost pcre-8.10]$ ./configure    --prefix=/opt/aspire/product/bdctool/nginx/zzw_other/pcre-8.10 (自定义目录)

[bdctool@localhost pcre-8.10]$ make

[bdctool@localhost pcre-8.10]$ make install

4、再来安装nginx,首先./configure(这里是个坑,可以不操作,继续往下看--转载注)

[bdctool@localhost nginx-1.12.2]$./configure  --with-http_stub_status_module  --prefix=/opt/aspire/product/bdctool/nginx  --with-pcre=/opt/aspire/product/bdctool/nginx/zzw_other/pcre-8.10

注意:上面命令--prefix=路径为nginx想要安装到的目录, --with-pcre=路径为pcre安装到的目录。

5、修改 --with-pcre=后的路径为pcre的解压后的源路径,重新./configure

[bdctool@localhost nginx-1.12.2]$./configure  --with-http_stub_status_module  --prefix=/opt/aspire/product/bdctool/nginx  --with-pcre=/opt/aspire/product/bdctool/setup/pcre-8.10(注意这个是pcre的源码路径)

原文路径:https://blog.csdn.net/lzs_xiaoze/article/details/85632144

6,执行make 命令

7,执行make install 命令来着

linux 非root用户安装nginx的更多相关文章

  1. linux非root用户安装nginx

    先到官网http://nginx.org/en/download.html下载最新稳定版源码包,目前是1.16.1: 下完后通过rz上传至wlf用户soft目录下,退回上一级目录解压: $ cd so ...

  2. linux非root用户安装jdk1.8

    如题,先到 Oracle 官方网站 下载1.8版本的 JDK 压缩包(jdk-8u221-linux-x64.tar.gz)到本地(如D盘的soft目录),然后开始进入linux的非root用户(如w ...

  3. 【tf.keras】Linux 非 root 用户安装 CUDA 和 cuDNN

    TensorFlow 2.0 for Linux 使用时报错:(cuDNN 版本低了) E tensorflow/stream_executor/cuda/cuda_dnn.cc:319] Loade ...

  4. linux非root用户安装ncurses-devel依赖

    很明显,如果我们通过yum或rpm下载安装,始终无法绕开root用户,除非我们不用yum或rpm.嗯,我们直接用源码安装.下载源码包,到http://ftp.gnu.org/gnu/ncurses/我 ...

  5. linux非root用户安装rabbitmq

    因为rabbitmq是用erlang语言写的,所以装rabbitmq前第一步得先装erlang. 我们到erlang官网https://www.erlang.org/downloads下载安装包,最新 ...

  6. linux非root用户安装4.0.14版本redis

    先到官网https://redis.io/download下安装包,现在最新是5.0.5版本,可惜点击下载后被windows禁了,那就下4版本的,往下看Other versions的Old(4.0), ...

  7. linux非root用户安装5.7.27版本mysql

    先下安装包,到mysql官网https://dev.mysql.com/downloads/mysql/选好安装包版本.操作系统类型(默认是最新版本,点击右边链接Looking for previou ...

  8. Linux非root用户安装jdk和tomcat

    转载自:http://blog.csdn.net/wuyigong111/article/details/17410661,进行部分修改 创建一个用户 sgmm,并在其用户目录里面安装 jdk和tom ...

  9. Linux 以非root用户安装zsh&配置on my zsh

    此文章参考以下三篇文章,如有侵权请联系 Linux非root用户安装zsh, 并用oh-my-zsh进行配置 在没有sudo权限的Linux服务器下安装oh-my-zsh 不使用root权限安装zsh ...

随机推荐

  1. [图片问答]LODOP字体设置方法

    字体设置方法:一.整体设置(针对文本项),打印初始化后.增加打印项之前调用本函数LODOP.SET_PRINT_STYLE("FontSize",11);二.单个打印项(针对文本项 ...

  2. [LeetCode] 774. Minimize Max Distance to Gas Station 最小化加油站间的最大距离

    On a horizontal number line, we have gas stations at positions stations[0], stations[1], ..., statio ...

  3. Component 'TABCTL32.OCX'错误的处理方法

    错误:Component 'TABCTL32.OCX' or one of its dependencies not correctyly registered:a file is missing o ...

  4. 密钥密码体系CA,CSC,CV

    密钥密码体系CA,CD,CSC,CV 片内操作系统 (cos) 密码学(Cryptography) 非接触式智能卡Contactless Smart Card, CSC 密钥名词 名词 英文说明 中文 ...

  5. 学习记录-java基础部分(一)

    学习记录-java基础部分(一) 参考:GitHub上的知名项目:javaGuide : https://github.com/Snailclimb/JavaGuide/blob/master/doc ...

  6. string 与 int double 的转化

    #include <iostream> #include <string> #include <sstream> using namespace std; int ...

  7. Word 自带公式使用方法技巧(11)

    1. 快捷命令 在Word中输入「Alt+=」,可以打开Word中自带公式编辑器.这个编辑器似乎没有什么特别,但其实 Word 2010 以后是支持 LaTeX 语法的.常用规则如下: 分号: a/b ...

  8. yzoj2424 小迟的数字 题解

    题意:如果一个数字用十进制表示,有大于等于1个1,或者大于等于2个2,或者大于等于3个3,或者大于等于4个4,或者大于等于5个5,或者大于等于6个6,或者大于等于7个7,或者大于等于8个8,或者大于等 ...

  9. 可能这些是你想要的H5软键盘兼容方案

    前言 最近一段时间在做 H5 聊天项目,踩过其中一大坑:输入框获取焦点,软键盘弹起,要求输入框吸附(或顶)在输入法框上.需求很明确,看似很简单,其实不然.从实验过一些机型上看,发现主要存在以下问题: ...

  10. 【scratch3.0教程】1.1 走进编程世界

    第一章 认识Scratch 第1课   走进编程世界 大家认识下图中的人物吗? 史蒂夫·乔布斯             比尔·盖茨 ●Elon Musk,特斯拉.Space X火箭公司创始人,9岁学习 ...