`
can_do
  • 浏览: 249771 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

Linux下Nginx安装

阅读更多
(1)、Linux下Nginx的安装:

chmod +x ./nginx-1.0.5.tar.gz

gunzip ./nginx-1.0.5.tar.gz

tar -xvf ./nginx-1.0.5.tar

./configure --prefix=/opt/nginx_installed --with-http_stub_status_module --with-openssl=/opt/nginx-1.0.5/auto/lib/openssl

注意:此配置只引用了http_stub_status_module和openssl,其他module需要引用的话,再加进来。

make

make install

[root@apusicB1 sbin]# ./nginx -t

nginx: the configuration file /opt/nginx_installed/conf/nginx.conf syntax is ok

nginx: configuration file /opt/nginx_installed/conf/nginx.conf test is successful

(2)、Nginx启动、停止、重启

# ./nginx  =>启动

#./nginx -s stop  =>停止

# ./nginx -s reload  =>重启

# kill -QUIT <Main_Pid>  =>cat <nginx_home>/logs/nginx.pid  =>杀掉所有nginx进程

# killall nginx  =>杀掉所有nginx进程

参见:http://nginx.org/en/ 和http://wiki.nginx.org/NginxHttpUpstreamModule
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics