首页 > 技术文章 > Linux make nginx 的时候报错

laowenBlog 2017-08-29 08:58 原文

报错如下:
`conf/koi-win' and `/usr/local/nginx/conf/koi-win' are the same file
 
原因:
可能在编译 nginx 的时候步骤不对、
或者 编译 nginx 的目录和下载的源码的目录在同一个目录下、
 
解决:
重新编译 nginx
步骤如下:
1:wget http://nginx.org/download/nginx-1.10.3.tar.gz
2:tar -zxvf nginx-1.10.3.tar.gz
3:cd nginx-1.10.3
4:./configure --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_gzip_static_module --with-http_ssl_module
5:make && make install
6:cd /usr/local/nginx
7:vim /conf/nginx.conf // 编辑配置文件
 
注意:还有可能缺少 openssl、pecl、最好自己都默认安装下

推荐阅读