Opened 8 years ago
Closed 7 years ago
#1289 closed defect (fixed)
Nginx 1.12.0 unable to start after initial installation on RHEL 7 if access_log is uncommented
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | minor | Milestone: | |
Component: | nginx-package | Version: | 1.9.x |
Keywords: | Cc: | ||
uname -a: | Linux 3.10.0-514.el7.x86_64 #1 SMP Wed Oct 19 11:24:13 EDT 2016 x86_64 x86_64 x86_64 GNU/Linux | ||
nginx -V: | nginx version: nginx/1.12.0 |
Description
On RHEL 7 I installed Nginx by adding a yum repo
[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/rhel/7/$basearch/
gpgcheck=0
enablied=1
After installation I updated /etc/nginx/conf.d/default.conf and uncommented the line
access_log /var/log/nginx/log/host.access.log main;
Then I tried to start the nginx.service systemd unit
-- Unit nginx.service has begun starting up.
Jun 05 16:43:23 nginx[2960]: nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
Jun 05 16:43:23 nginx[2960]: nginx: [emerg] open() "/var/log/nginx/log/host.access.log" failed (2: No such file or directory)
Jun 05 16:43:23 nginx[2960]: nginx: configuration file /etc/nginx/nginx.conf test failed
Jun 05 16:43:23 systemd[1]: nginx.service: control process exited, code=exited status=1
Jun 05 16:43:23 systemd[1]: Failed to start nginx - high performance web server.
When I change the access_log in default.conf to /var/log/nginx/access.log then I was able to successfully start the service.
Perhaps making that access_log value change in default.conf will fix this issue.
Change History (3)
comment:1 by , 8 years ago
Component: | other → nginx-package |
---|
comment:2 by , 8 years ago
comment:3 by , 7 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Thanks! I've commited the changes to the packaging sources - the package for the next 1.12 stable release will have the fix.