Good morning,
I am facing a very annoying issue with Nginx access and error logs.
For a reason I cannot mention, I absolutely need to write my nginx logs on a NFS partition mounted on the server.
For this, I mentionned the path to the error and access logs files (each one on a different nfs partition).
The file is properly created bu the Nginx master but only a few logs are written (most of them are lost).
To understand the problem, I separated temporarily the error log and I observed "permission denied" alerts:
2016/03/09 10:13:03 [alert] 1698#0: *13 write() to "<PATH to NFS LOG>/access.log" failed (13: Permission denied) while logging request, client: <server IP>, server: <server IP>, request: "GET /home HTTP/1.1", upstream: "http://<server IP>:<server Port>/home", host: "<server IP>:<server Port>"
A tcpdump gives me NFS3ERR_ACCES error packet at the same time.
You'll tell me it is user permission error to access the NFS mount, but logs are sometimes written and I only have this issue with Nginx (other tools works fine with it).
If you are aware of this, what should I do (in nfs server/client conf or patch for nginx) to fix this issue.
Thank you for your concern,
MPtiBot
I am facing a very annoying issue with Nginx access and error logs.
For a reason I cannot mention, I absolutely need to write my nginx logs on a NFS partition mounted on the server.
For this, I mentionned the path to the error and access logs files (each one on a different nfs partition).
The file is properly created bu the Nginx master but only a few logs are written (most of them are lost).
To understand the problem, I separated temporarily the error log and I observed "permission denied" alerts:
2016/03/09 10:13:03 [alert] 1698#0: *13 write() to "<PATH to NFS LOG>/access.log" failed (13: Permission denied) while logging request, client: <server IP>, server: <server IP>, request: "GET /home HTTP/1.1", upstream: "http://<server IP>:<server Port>/home", host: "<server IP>:<server Port>"
A tcpdump gives me NFS3ERR_ACCES error packet at the same time.
You'll tell me it is user permission error to access the NFS mount, but logs are sometimes written and I only have this issue with Nginx (other tools works fine with it).
If you are aware of this, what should I do (in nfs server/client conf or patch for nginx) to fix this issue.
Thank you for your concern,
MPtiBot