52AV手機A片王|52AV.ONE

標題: [emerg] 5048#0: bind() to x.x.x.x:80 failed (98: Address already in use) [打印本頁]

作者: IT_man    時間: 2016-4-6 12:23
標題: [emerg] 5048#0: bind() to x.x.x.x:80 failed (98: Address already in use)
當啟動nginx時, service nginx start (restart) 出現連續5個相同錯誤:
1 n; C7 S- X1 [. z  Z' A[emerg] 5048#0: bind() to x.x.x.x:80 failed (98: Address already in use), q( C$ e# d$ G( p% G% v2 C
最後再給你出現
2 J) L7 d) H: m- o( v6 r[emerg] 5048#0: still could not bind()* m) D" |1 p+ M  O
重開機也沒用0 |! y! s! ]. F/ ^1 H0 \
這個意謂"nginx或其他程序正在使用 port 80" , 可以指令 netstat -pan | grep ":80" 或
! Y7 A0 o0 d0 W: Sfuser 80/tcp  (fuser 指令可以參考 http://nixgeek.com/finding-out-what-process-is-listening-on-a-port-under-linux.html)( H( D+ q8 \6 V' K0 a! R% d& ^9 j6 T8 O: S
查看是誰占用 port 80,但nginx也沒占用(啟動不了當然不會占用)/ ^% v$ [, r2 Z$ B+ d2 ~  a
7 I  H  G9 Y  J6 w
  ^; @; U& f& s9 S- U" g/ L# W
最後  fuser -k 80/tcp  刪除占用 port 80 的的所有程序(process)8 y) D% |" C* J
然後 service nginx restart  ======> OK/ K# B  w  x! V5 f0 Q

) e9 j' {4 P7 I( A




歡迎光臨 52AV手機A片王|52AV.ONE (https://www.52av.one/) Powered by Discuz! X3.2