編譯安裝nginx過程中出現的錯誤


執行 make 報錯

make: *** No rule to make target build, needed by default. Stop.

解決方式:

更新yum

yum update

更新完成后,先刪除之前准備make的nginx包,然后重新解壓一個。

安裝前置庫:

[root@cqakserver local]# yum install -y gcc pcre pcre-devel openssl openssl-devel gd gd-devel

刪除原來解壓縮目錄,重新編譯安裝

./configure: error: the HTTP gzip module requires the zlib library.

則需要安裝“zlib-devel”即可。SSH執行以下命令:

yum install -y zlib-devel

./configure: error: the HTTP rewrite module requires the PCRE library.

yum -y install pcre-devel

./configure: error: the HTTP cache module requires md5 functions

from OpenSSL library.

yum -y install openssl openssl-devel

判斷Nginx配置是否正確

nginx -t -c /usr/nginx/conf/nginx.conf
或者
/usr/nginx/sbin/nginx -t


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM