nginx安装启动
参考:http://network.51cto.com/art/201005/198198_4.htm
下载nginx tar.gz安装包
下载pcre tar.gz安装包 安装pcre
tar zxvf pcre-7.9.tar.gz
cd pcre-7.9
./configure
make && make install
安装nginx
tar zxvf nginx-0.7.61.tar.gz
cd nginx-0.7.61
./configure --with-http_stub_status_module --prefix=/usr/local/nginx
#--with-http_stub_status_module 是监控模块
#
make && make install ##不加--without-http_rewrite_module这个参数时就是启动URL重写,所以需要pcre
##./configure --with-http_stub_status_module --without-http_rewrite_module --prefix=/usr/local/nginx -----------------------------------------------------------------------
#出现错误(参考地址 http://www.kwx.gd/CentOSApp/nginx-gzip-requires-zlib.html)
./configure: error: the HTTP gzip module requires the zlib library.
You can either disable the module by using –without-http_gzip_module
option, or install the zlib library into the system, or build the zlib
library
statically from the source with nginx by using –with-zlib=<path> option. 则需要安装“zlib-devel”即可。SSH执行以下命令:
yum install -y zlib-devel
------------------------------------------------------------------------
配置文件
目录 /usr/local/nginx/conf/nginx.conf
配置请看 http://www.cnblogs.com/loveismile/p/3875721.html 启动
/usr/local/nginx/sbin/nginx & 重启
/usr/local/nginx/sbin/nginx -s reload 帮助
/usr/local/nginx/sbin/nginx -h 检查nginx.conf配置文件
/usr/local/nginx/sbin/nginx -t
nginx安装启动的更多相关文章
- 聊聊、Nginx 安装启动
首先说下安装 Nginx 的步骤: (1)window 下安装 进入 http://nginx.org/en/download.html 下载版本 Mainline version 或者 Stable ...
- nginX 安装 启动
选择源码安装 下载安装包 nginx-1.8.0.tar.gz 解压 tar -zxvf nginx-1.8.0.tar.gz 进入文件夹 ...
- ubuntu 14.04(desktop amd 64) nginx 安装启动停止
sudo apt-get install nginx 关闭: sudo service nginx stop 启动: sudo nginx
- nginx 安装启动
[root@localhost ~]# wget http://nginx.org/download/nginx-0.7.67.tar.gz --2010-09-24 14:48:12-- http: ...
- centos7 nginx安装/启动/进程状态/杀掉进程
1.安装 下载RPM:wget http://nginx.org/packages/centos/7/x86_64/RPMS/nginx-1.10.0-1.el7.ngx.x86_64.rpm ...
- nginx安装,启动亲测有效
一:安装编译工具及库文件 yum -y install make zlib zlib-devel gcc-c++ libtool openssl openssl-devel 二:安装PCRE,让 N ...
- Linux下Nginx安装/启动/重启/停止
Nginx是高性能的web服务器也是非常好用反向代理服务器,可以实现负载均衡,动静分离等策略,在linux下用的非常多.下面是下载地址 http://nginx.org/en/download.h ...
- Nginx安装启动过程报错libpcre.so.1 cannot open shared object file: No such file or directory
具体报错信息如下: nginx: error while loading shared libraries: libpcre.so.1: cannot open shared object file: ...
- Linux nginx 安装 启动
nginx下载地址:https://nginx.org/download/ ## 解压 tar -zxvf nginx-1.9.9.tar.gz ##进入nginx目录 cd nginx-1.9.9 ...
随机推荐
- entityframework 入门-来自微软
必备条件 要完成本演练,需要安装 Visual Studio 2010 或 Visual Studio 2012. 如果使用的是 Visual Studio 2010,还需要安装 NuGet. 1.创 ...
- java 标识符命名规则
标识符:就是给类,接口,方法,变量等起名字. 组成规则: A:英文字母大小写 B:数字字符 C:$和_ 注意事项: A:不能以数字开头 B:不能是Java中的关键字 C:Java语言严格区分大小写 包 ...
- CGI、FastCGI和PHP-FPM浅析
这段时间对Nginx+PHP-FPM的概念和机制一直不太清晰,趁着同事的分享和看过的几篇博文和资料,重新将思路处理一下. 首先,PHP-FPM(FastCGI Process Manager: Fas ...
- FireDAC 超时
FireDAC 超时 Timeout expired 在Win10 正常. 在Win7 CB的DLL 正常,Delphi的DLL怎么会超时呢??? 果然是连接字符串错了.改为正确的就连接正常了!
- python 格式化 json输出
利用python格式化json 字符串输出. $ echo '{"json":"obj"}' | python -m json.tool 利用python -m ...
- redis集群出现JedisNoReachableClusterNodeException异常(No reachable node in cluster)
上午午好好的,突然抛了如下异常: Exception in thread "main" redis.clients.jedis.exceptions.JedisNoReachabl ...
- windbg学习!vad
在ring0 !address不能提供详细的信息了 可以尝试用下!vad !vad扩展显示一个或多个虚拟地址详细的虚拟地址描述符(virtual address descriptor (VAD)). ...
- Linux C _exit函数与exit函数的联系与区别
一.联系 1.功能上,_exit和exit函数都是让进程正常退出,即关闭进程所打开的文件描述符,释放已占用内存和其他资源. 二.区别 1._exit函数在头文件unistd.h中声明,而exit在头文 ...
- [aspx]控件及代码小例
1. 原生 asp 方式遍历 DataTable 2. aspx 的控件 Repeater 后台绑定 <%-- DataTable dt = OleDbHelper.GetTable(&quo ...
- bootstrap的日期插件datetimepicker有问题
bootstrap的日期插件datetimepicker在chrome中会出现掉下来的现象,而且一直没找到原因,下载最新版的插件直接在各个浏览器中都会掉下来, 问题一直解决不了,转而换其他插件 htt ...