一. 源码包编译安装部署web服务器
1.安装nginx必须的依赖包
[[email protected] ~]# yum -y install gcc openssl-devel pcre-devel zlib-devel
2.安装编译nginx,目前系统测试环境为CentOS6.3 软件版本为nginx-1.2.6
[[email protected] ~]# useradd nginx -s /sbin/nologin
[[email protected] ~]# tar zxvf nginx-1.2.6.tar.gz 
[[email protected] ~]# cd nginx-1.2.6 
[[email protected] nginx-1.2.6]# ./configure --user=nginx --group=nginx --prefix=/usr/local/nginx/ --with-http_stub_status_module --with-http_ssl_module  
// --with-http_stub_status_module 安装允许状态模块
// --with-http_ssl_module 安装ssl模块
[[email protected] ~]# /usr/local/nginx/sbin/nginx -v //查看Nginx的相关环境配置信息是否正确
nginx version: nginx/1.2.6
[[email protected] nginx-1.2.6]# make & make install   //编译安装过程略
 
3.通过nginx自身脚本机器nginx服务器,并通过各种命令查看是否启动成功
[[email protected] ~]# /usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf   // -c指向nginx主配置文件
[[email protected] ~]# lsof -i :80 //查看nginx进程号及运行情况
COMMAND   PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
nginx   21910 root    9u IPv4 262148      0t0 TCP *:http (LISTEN)
nginx   21911 nginx    9u IPv4 262148      0t0 TCP *:http (LISTEN)
[[email protected] ~]# ps -ef | grep nginx //查看nginx进程号及运行情况
root     21910     1 0 10:41 ?        00:00:00 nginx: master process /usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
nginx    21911 21910 0 10:41 ?        00:00:00 nginx: worker process          
root     21957 21755 0 10:42 pts/0    00:00:00 grep nginx
[[email protected] ~]# netstat -nltp | grep 80 //查看nginx进程监听端口
[[email protected] ~]# netstat -an |grep 80
tcp        0      0 0.0.0.0:80                  0.0.0.0:*                   LISTEN
4.通过windows服务器IE浏览器测试

2017最新鑫众游戏大厅源码架设和全套手机版运营级别源码下载

2017最新鑫众游戏大厅源码架设和全套手机版运营级别源码下载:http://aqiulian.com/thread-91-1-1.html

相关文章:

  • 2022-01-15
  • 2022-01-07
  • 2022-02-10
  • 2022-12-23
  • 2021-08-27
  • 2022-12-23
  • 2021-05-12
  • 2021-10-09
猜你喜欢
  • 2021-12-18
  • 2021-08-05
  • 2021-08-18
  • 2021-09-05
  • 2021-12-15
  • 2021-12-18
  • 2021-05-07
相关资源
相似解决方案