ubunutu 12.04LTS 安装 nginx
来源:互联网 发布:测试网络丢包软件 编辑:程序博客网 时间:2024/05/16 05:56
1、下载
到http://nginx.org/download/选择需要的版本,复制其连接地址。然后输入指令
marco@marco:~/download$ wget http://nginx.org/download/nginx-1.7.1.tar.gz--2014-06-15 09:23:58-- http://nginx.org/download/nginx-1.7.1.tar.gzResolving nginx.org (nginx.org)... 206.251.255.63Connecting to nginx.org (nginx.org)|206.251.255.63|:80... connected.HTTP request sent, awaiting response... 200 OKLength: 811015 (792K) [application/octet-stream]Saving to: `nginx-1.7.1.tar.gz'100%[======================================>] 811,015 233K/s in 3.4s 2014-06-15 09:24:11 (233 KB/s) - `nginx-1.7.1.tar.gz' saved [811015/811015]
随后解压
marco@marco:~/download$ tar -xvzf nginx-1.7.1.tar.gz
之后在当前目录下就会出现 nginx-1.7.1的目录。
2、检查
marco@marco:~/download/nginx-1.7.1$ ./configure
随后出现错误提示
checking for PCRE library ... not foundchecking for PCRE library in /usr/local/ ... not foundchecking for PCRE library in /usr/include/pcre/ ... not foundchecking for PCRE library in /usr/pkg/ ... not foundchecking for PCRE library in /opt/local/ ... not found./configure: error: the HTTP rewrite module requires the PCRE library.You can either disable the module by using --without-http_rewrite_moduleoption, or install the PCRE library into the system, or build the PCRE librarystatically from the source with nginx by using --with-pcre=<path> option.
上网查得 PCRE的全名是Perl Compatible Regular Expressions,是perl库,只要是让perl语言兼容正则表达式。
从错误提示看一看出来,如果没有这个库的话nginx 就无法支持HTTP的URL重写功能。不需要这个功能就可以在执行编译脚本的时候加上“--without-http_rewrite_module”参数就可以了。但是我还想要解决这个问题。
用http访问http://sourceforge.net/projects/pcre/files/pcre/,选择想要的PCRE版本下载。然后上传到服务器上。
加压、编译和安装PCRE
marco@marco:~/download$ tar -xvzf _pcre-8.35.tar.gzmarco@marco:~/download$ cd pcre-8.35/marco@marco:~/download/pcre-8.35$ ./configure marco@marco:~/download/pcre-8.35$ sudo make install
0 0
- ubunutu 12.04LTS 安装 nginx
- ubunutu 12.04 下安装rvm
- ubunutu 12.04下安装rails
- Ubuntu 12.04 LTS 安装 Nginx 1.6.0
- ubunutu 12.04 下使用passenger+nginx 部署 rails应用
- ubunutu 安装鼠标手势
- 如何在Ubuntu 12.04 LTS上安装nginx?
- ubunutu
- 17. ubuntu 16.04 LTS 安装 nginx
- ubunutu安装python的graph-tool库
- Ubuntu 12.04 LTS 的安装
- Ubuntu 12.04 LTS 安装JDK
- Ubuntu 12.04 LTS 安装 MATLAB2012a
- 移动硬盘安装Ubuntu 12.04 LTS
- Ubuntu 12.04 LTS安装总结
- ubuntu 12.04 LTS 安装codeweavers
- Ubuntu 12.04 LTS -- NFS安装
- Ubuntu 12.04LTS安装PPTP
- 优化exp/imp导入导出速度大全
- postgres 之 initdb 源码分析 三
- linux下安装zeromq及其测试
- 反人类的 贝塞尔曲线
- PAT Advanced Level 1034
- ubunutu 12.04LTS 安装 nginx
- 个撒的个撒的个撒的个撒的噶是的噶是的个后撒的个哈撒个撒的
- spring 项目中集成 Protocol Buffers 示例
- java二维码生成与解析代码实现
- 理想与现实
- 压缩与备份
- jquery同时验证邮箱和手机号吗
- Linux创建普通文件 vim
- PAT Advanced Level 1038