Ubuntu 重启 Nginx 失败,* Restarting nginx nginx ...fail!

原因是你配置 nginx 的配置文件出了错误

查找错误,处理方法

$ sudo nginx -t

nginx: [emerg] "location" directive is not allowed

here in /etc/nginx/nginx.conf:11

nginx: configuration file /etc/nginx/nginx.conf

test failed1

根据错误信息,修改对应生的配置文件即可。

 

转自: http://www.linuxidc.com/Linux/2015-07/119754.htm

posted @ 2015-09-27 11:18  圆旭  阅读(869)  评论(0编辑  收藏  举报