Home
Help
Search
Login
Register
OPNsense Forum
»
Archive
»
22.1 Legacy Series
»
nginx permission denied /var/log/nginx/
« previous
next »
Print
Pages: [
1
]
Author
Topic: nginx permission denied /var/log/nginx/ (Read 9130 times)
itngo
Full Member
Posts: 123
Karma: 4
nginx permission denied /var/log/nginx/
«
on:
August 04, 2022, 08:38:56 am »
Yesterday we changed log rotation and cleared logs in opnsense.
Since nginx LOG/GlobalError is flooding with open() "/var/log/nginx/FILE_NAME_REPLACED.access.log" failed (13: Permission denied)
What can we do?
Logged
itngo
Full Member
Posts: 123
Karma: 4
Re: nginx permission denied /var/log/nginx/
«
Reply #1 on:
August 04, 2022, 08:50:44 am »
Look like when you clear logs, permission get wrong.
New log files where with owner "www", after deleting files and apply nginx config files get created with owner "root" and logging is working again.... BUG?
Logged
itngo
Full Member
Posts: 123
Karma: 4
Re: nginx permission denied /var/log/nginx/
«
Reply #2 on:
August 04, 2022, 08:59:53 am »
It look like permissions get reset to www after a few minutes. Some sort of background job?
Global Error log gets flooded again.
Logged
Grossartig
Jr. Member
Posts: 76
Karma: 4
Re: nginx permission denied /var/log/nginx/
«
Reply #3 on:
July 04, 2023, 12:30:37 am »
Late response, but since you didn't get a response, and since I just had the same issue, I hope the following helps. The ownership of /var/log/nginx was root, but I had to change the ownership of that particular folder to www. This still allowed all log files to be written, but for the web UI to access them as well.
Unclear how it got messed up in the first place. I am currently on 23.1.11 but had the issue at least since 23.1.9, if not much earlier and never noticed until now.
Logged
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
Archive
»
22.1 Legacy Series
»
nginx permission denied /var/log/nginx/