首页 文章

nginx无法在redhat服务器上启动

提问于
浏览
-3

我试图在rhel 7上安装nginx,它说进程无法启动 . 以下是日志 .

11月13日06:36:42 ip-10-0-0-10.ec2.internal systemd [1]:启动nginx - 高性能网络服务器... ** 11月13日06:36:42 ip-10-0 -0-10.ec2.internal nginx [30974]:nginx:配置文件/etc/nginx/nginx.conf语法正常11月13日06:36:42 ip-10-0-0-10.ec2.internal nginx [30974]:nginx:[emerg] open()“/ mnt / nginx_logs / pubstore / access.log”失败(13:Permission denied)11月13日06:36:42 ip-10-0-0-10.ec2 . 内部nginx [30974]:nginx:配置文件/etc/nginx/nginx.conf测试失败11月13日06:36:42 ip-10-0-0-10.ec2.internal systemd [1]:nginx.service:control进程退出,代码=退出状态= 1月13日06:36:42 ip-10-0-0-10.ec2.internal systemd [1]:无法启动nginx - 高性能Web服务器 . 11月13日06:36:42 ip-10-0-0-10.ec2.internal systemd [1]:单位nginx.service进入失败状态 . **

文件访问日志的权限如下 . 我已经许可,但仍然没有开始 .

-rwxrwxrwx . 1 nginx nginx 0 Nov 13 02:07 access.log

-rwxrwxrwx . 1 nginx nginx 0 Nov 13 02:07 error.log

安装是在amazon ec2实例上的木偶代理上完成的

1 回答

  • 2

    这一行:

    11月13日06:36:42 ip-10-0-0-10.ec2.internal nginx [30974]:nginx:[emerg] open()“/ mnt / nginx_logs / pubstore / access.log”失败(13:没有权限)

    告诉您,您运行nginx的用户,无权写入其配置为写入的日志文件 .

    由于日志存储在非标准位置,因此您可能必须确保要存储的目录登录,可由nginx运行的同一用户写入 .

相关问题