成人无码视频,亚洲精品久久久久av无码,午夜精品久久久久久毛片,亚洲 中文字幕 日韩 无码

資訊專欄INFORMATION COLUMN

Nginx的各種報錯總結(jié)

Tecode / 2340人閱讀

摘要:復(fù)制代碼報錯信息如下錯誤錯誤解答執(zhí)行命令安裝依賴包。為了讓讀者理解問題,重現(xiàn)上述錯誤過程,命令如下復(fù)制代碼

1、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= option.

解決方法:yum install pcre pcre-devel -y
錯誤二:軟件依賴包未正確安裝問題---OPENSSL依賴包沒有安裝
./configure: error: SSL modules require the OpenSSL library.
You can either do not enable the modules or install the OpenSSL library
into the system or build the OpenSSL library statically from the source
with nginx by using --with-openssl= option.

解決方法:yum install openssl openssl-devel -y
錯誤三:編譯安裝pcre編譯軟件時,gcc不全導(dǎo)致報錯(使用yum安裝不存在此問題)。
復(fù)制代碼
報錯信息如下:
[root@gjlin2 pcre-8.30]# make && make install
make all-am
make[l]: Entering directory 7h〇me/gjlin/tools/pcre-8.30*
CXX pcrecpp.lo
libtool: compile : unrecognized option -DHAVE_CONFIG_H
libtool:compile : Try libtool --help for more information.
make[l]:*[pcrecpp.lo]錯誤 1
make[l]:Leaving directory /home/gjlin/tools/pcre-8.30
make : * [all]錯誤 2

解答:執(zhí)行"yum -y install gcc-c++"命令安裝gcc-c++依賴包。
復(fù)制代碼
回到頂部
2、Nginx啟動過程中報錯
錯誤一:nginx軟件重復(fù)啟動產(chǎn)生的錯誤信息
復(fù)制代碼
[root@web01 nginx-1.10.2]# /application/nginx/sbin/nginx
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] still could not bind()

解決方法:nginx軟件已經(jīng)啟動無需反復(fù)啟動,如果需要重新啟動需要停止nginx進程或者用reload方式進行重啟

復(fù)制代碼
錯誤二:403報錯
服務(wù)阻止客戶端訪問
服務(wù)端站點目錄中,沒有指定首頁文件信息
錯誤三:啟動 Nginx 時如下報錯"nginx:[emerg]getpwnam(“nginx”)failed"
解答:這是因為沒有對應(yīng)的Nginx服務(wù)用戶,執(zhí)行useradd nginx -s /sbin/nologin -M創(chuàng)建Nginx用戶即可。為了讓讀者理解問題,重現(xiàn)上述錯誤過程,命令如下:

復(fù)制代碼
[root@web tools]# pkill nginx

[root@web tools]# userdel nginx

[root@web tools]# /application/nginx/sbin/nginx

nginx: [emerg] getpwnam(Mnginx") failed

[root@web tools]# useradd nginx -s /sbin/nologin -M

[root@web tools]# /application/nginx/sbin/nginx

文章版權(quán)歸作者所有,未經(jīng)允許請勿轉(zhuǎn)載,若此文章存在違規(guī)行為,您可以聯(lián)系管理員刪除。

轉(zhuǎn)載請注明本文地址:http://m.hztianpu.com/yun/126391.html

相關(guān)文章

  • 跨域問題匯總

    摘要:因為瀏覽器的同源策略,前端開發(fā)會遇到各種跨域問題。前言在總結(jié)各種跨域問題之前,我們先來了解一下瀏覽器的同源策略。所以只能解決一級域名相同二級域名不同的跨域問題。 跨域問題的場景和解決方案多種多樣,只要是做前端開發(fā),總會遇到。而且面試時也是必問的問題。所以自己學(xué)習(xí)總結(jié)記錄一下。 因為瀏覽器的同源策略,前端開發(fā)會遇到各種跨域問題。本篇文章總結(jié)了遇到跨域問題的不同的場景以及對應(yīng)的解決方案。 ...

    MkkHou 評論0 收藏0
  • Wordpress博客遷移至Jekyll過程總結(jié)

    摘要:想來想去還是想試試把我的博客轉(zhuǎn)成一方面為了管理另一方面實在是感覺請求過多速度太慢可改造性太差經(jīng)過遷移后默認(rèn)主題速度杠杠的顯示時間不到哦安裝本文在環(huán)境下操作環(huán)境需要比較懶貌似自帶還是啥時候裝了不會的自己搜一下安裝和目前最新穩(wěn)定版本是自帶源的版 想來想去還是想試試把我的博客轉(zhuǎn)成Jekyll, 一方面為了git管理, 另一方面實在是感覺請求過多速度太慢, 可改造性太差. 經(jīng)過遷移后, 默認(rèn)主...

    高勝山 評論0 收藏0

發(fā)表評論

0條評論

閱讀需要支付1元查看
<