1. 程式人生 > >nginx: [alert] kill(12268, 1) failed (3: No such process)

nginx: [alert] kill(12268, 1) failed (3: No such process)

執行nginx伺服器時,終端下輸入命令ps aux|grep nginx,正確應顯示如下圖:

   但是卻沒有顯示中間nobody     3162  0.0  0.1  37228  3548 ?        S    22:58   0:00 nginx: worker process這一行,只有其它兩行的狀況。這樣就會造成通過django管理員進入後臺傳到fastdfs中的圖片無法通過靜態網頁或者img標籤訪問。最開始打算 解除安裝重新安裝。(編譯安裝的nginx)。重灌後啟動nginx報如下錯誤:

           nginx: [alert] kill(12268, 1) failed (3: No such process)

然後經過 [[email protected] ~]# ll /usr/local/nginx/sbin/nginx -rwxr-xr-x. 1 root root 9120664 May 9 11:30 /usr/local/nginx/sbin/nginx

[[email protected] ~]# whereis nginx nginx: /usr/bin/nginx /usr/local/nginx

[[email protected] ~]# find / -name nginx find: ‘/run/user/1000/gvfs’: Permission denied /etc/rc.d/init.d/nginx /usr/bin/nginx /usr/local/nginx /usr/local/nginx/sbin/nginx

[[email protected] ~]# find / -name nginx.conf find: ‘/run/user/1000/gvfs’: Permission denied /usr/local/nginx/conf/nginx.conf

[[email protected] ~]# /usr/sbin/nginx -c /usr/local/nginx/conf/nginx.conf -bash: /usr/sbin/nginx: No such file or directory

[[email protected] ~]# /usr/bin/nginx -c /usr/local/nginx/conf/nginx.conf [
[email protected]
~]# vi /usr/local/nginx/conf/nginx.conf [[email protected] ~]# nginx -s reload 一通瞎操作(並不知道這樣做的原因),解決問題。