JAVA和Nginx 教程大全

网站首页 > 精选教程 正文

安装nginx

wys521 2024-09-06 04:28:06 精选教程 25 ℃ 0 评论

在安装nginx前,需要确保系统安装了g++、gcc、openssl-devel、pcre-devel和zlib-devel软件。安装必须软件:

yum install gcc-c++

yum -y install zlib zlib-devel openssl openssl--devel pcre pcre-devel

将安装包文件上传到/usr/local中执行以下操作:

tar -zxv -f nginx-1.2.6.tar.gz

cd /usr/local/nginx-1.2.6

./configure --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_realip_module && make

make install

启动

cd /usr/local/nginx/sbin

./nginx

停止

pkill -9 nginx

平滑重启

./nginx -s reload

Tags:

本文暂时没有评论,来添加一个吧(●'◡'●)

欢迎 发表评论:

最近发表
标签列表