首页 > 其他 > 详细

2019-09-30安装niginx 启动 关闭 重启

时间:2019-09-30 16:05:35      阅读:72      评论:0      收藏:0      [点我收藏+]

第一步首先下载nginx 安装包解压

checking for C compiler ... not found

上述问题是因为 这几个包的缺失

  1. yum -y install gcc
  2.  yum -y install gcc-c++ 
  3. yum install make

编译安装nginx却requires the PCRE library

编译安装nginx需要pcre包,未安装会有如下提示:

./configure: error: the HTTP rewrite module requires the PCRE library.
You can either disable the module by using --without-http_rewrite_module
option, or install the PCRE library into the system, or build the PCRE library
statically from the source with nginx by using --with-pcre=<path> option.

需要安装pcre的devel包,pcre-devel。使用yum安装即可:(以下命令还带有ssl、zlib等依赖的安装)

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

上述问题是因为 这几个包的缺失

  1. yum -y install gcc
  2.  yum -y install gcc-c++ 
  3. yum install make

编译安装nginx却requires the PCRE library

编译安装nginx需要pcre包,未安装会有如下提示:

./configure: error: the HTTP rewrite module requires the PCRE library.
You can either disable the module by using --without-http_rewrite_module
option, or install the PCRE library into the system, or build the PCRE library
statically from the source with nginx by using --with-pcre=<path> option.

需要安装pcre的devel包,pcre-devel。使用yum安装即可:(以下命令还带有ssl、zlib等依赖的安装)

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

技术分享图片

 关闭nginx 直接杀死进程号

[root@kaiwen ~]# ps -ef | grep nginx

root 28227 1 0 15:12 ? 00:00:00 nginx: master process ./nginx
nobody 28228 28227 0 15:12 ? 00:00:00 nginx: worker process
root 29225 16204 0 15:31 pts/0 00:00:00 grep --color=auto nginx

[root@kaiwen ~]# ps -ef | grep nginx

[root@kaiwen ~]# kill -quit 28227
[root@kaiwen ~]# ps -ef | grep nginx
root 29546 16204 0 15:38 pts/0 00:00:00 grep --color=auto nginx

 

 

 

 





2019-09-30安装niginx 启动 关闭 重启

原文:https://www.cnblogs.com/wbly2019/p/11612934.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!