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 ...
随机推荐
- Linux学习笔记——使用指定的用户权限执行程序——sudo
sudo可以用来以其他用户身份执行命令,sudo命令可以针对单个命令授予临时权限.sudo仅在需要时授予用户权限,减少了用户因为错误执行命令损坏系统的可能性. 1:sudo的帮助信息如下: ...
- 执行powershell脚本
打开powershell运行窗口: powershell.exe C:\Users\Administrator\Desktop\a.ps1 -a $a. -a $a : vbs脚本路径(如 C:\h ...
- 纸上谈兵:图(graph)
作者:Vamei 出处:http://www.cnblogs.com/vamei 欢迎转载,也请保留这段声明.谢谢! 图(graph)是一种比较松散的数据结构.它有一些节点(vertice),在某些节 ...
- MongoDB-MMS使用总结
环境:阿里云 系统:ubuntu 12.04 数据库:MongoDB shell version: 2.0.4 登录MMS,注册相应用户 根据文档开始安装:Install the Monitoring ...
- linux shell学习笔记
一 变量 声明变量: my_var='ddd'使用变量: ${my_var}设置为只读变量: readonly my_var删除变量: unset my_var 注意只读变量不能被删除 变量类型:( ...
- TListView Header重绘和高度设置
TListView 的 Header 部分默认 BtnFace 颜色,高度也不能改变.我们可以通过编写一些代码来实现这些功能: 获得TListView 的Header 的句柄: TListView的H ...
- Android DDMS检测内存泄露
Android DDMS检测内存泄露 DDMS是Android开发包中自带工具,可以测试app性能,用于发现内存问题. 1.环境搭建 参考之前发的Android测试环境搭建相关文章,这里不再复述: 2 ...
- Android菜鸟成长记3-activity类
Activity 一.什么是activity Activity 是用户接口程序,原则上它会提供给用户一个交互式的接口功能.它是 android 应用程序的基本功能单元.Activity 本身是没有界面 ...
- Find the equipment indices
Here is a simple program test task, it doesn't have very diffcult logic: A zero-indexed array A cons ...
- Ajax请求SpringMVC
@RequestMapping(value = "/loadMenu", method = RequestMethod.GET) @ResponseBody public Arra ...