Skip to content
This repository has been archived by the owner on Feb 4, 2021. It is now read-only.

Nginx error: could not open error log file: open() "/var/lib/nginx/logs/error.log" #37

Closed
kuba-orlik opened this issue Sep 17, 2016 · 12 comments

Comments

@kuba-orlik
Copy link

I've set up the app from the 10.0 tag and the app doesn't start... The logs keep showing:

nextcloud_1     | nginx: [alert] could not open error log file: open() "/var/lib/nginx/logs/error.log" failed (13: Permission denied)
nextcloud_1     | 2016/09/17 18:44:45 [emerg] 13#0: open() "/var/lib/nginx/logs/error.log" failed (13: Permission denied)
nextcloud_1     | nginx: [alert] could not open error log file: open() "/var/lib/nginx/logs/error.log" failed (13: Permission denied)
nextcloud_1     | 2016/09/17 18:44:46 [emerg] 17#0: open() "/var/lib/nginx/logs/error.log" failed (13: Permission denied)
nextcloud_1     | nginx: [alert] could not open error log file: open() "/var/lib/nginx/logs/error.log" failed (13: Permission denied)
nextcloud_1     | 2016/09/17 18:44:47 [emerg] 19#0: open() "/var/lib/nginx/logs/error.log" failed (13: Permission denied)

I didn't mess with any nginx settings. Should I?

@Wonderfall
Copy link
Owner

Similar to #34, though I couldn't reproduce your problem.
Let me know if the latest fix works?

@gcollura
Copy link

I have the same problem, but this happens only on my vps (ubuntu server 14.04), not on my pc (ubuntu 16.04).

Server:

$ docker version
Client:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   23cf638
 Built:        Thu Aug 18 05:22:43 2016
 OS/Arch:      linux/amd64

Server:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   23cf638
 Built:        Thu Aug 18 05:22:43 2016
 OS/Arch:      linux/amd64

My PC:

docker version
Client:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   23cf638
 Built:        Thu Aug 18 05:33:38 2016
 OS/Arch:      linux/amd64

Server:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   23cf638
 Built:        Thu Aug 18 05:33:38 2016
 OS/Arch:      linux/amd64

If you need any additional information, I'm willing to help you.

@Wonderfall
Copy link
Owner

f5dac5c didn't work? Make sure you pulled the latest image.

@Wonderfall Wonderfall reopened this Sep 18, 2016
@gcollura
Copy link

Yes, I pulled the last one:

$ docker pull wonderfall/nextcloud
Using default tag: latest
latest: Pulling from wonderfall/nextcloud
Digest: sha256:724628042dc11df2fa47138e9430fe0a755fc9088a3baf92315625c458bd23c7
Status: Image is up to date for wonderfall/nextcloud:latest

Thank you.

@edouardkleinhans
Copy link

same issue on my server (ubuntu 14.04)

@Wonderfall
Copy link
Owner

Wonderfall commented Sep 19, 2016

Honestly I don't know what's wrong, it was supposed to work. Somehow it's related to the OS (Ubuntu 14.04 has this problem), perhaps there's something with the fs driver used by Docker (aufs, overlay...).

What do you guys think? Should I revert back to some root processes? I don't have much time actually so if you could do some research I'd be grateful for that. Maybe someone on Ubuntu 14.04 can try to update aufs?

@verbunk
Copy link

verbunk commented Sep 22, 2016

FWIW: For all these files I put them in a Dockerfile defined volume and then mount it at runtime via
--tmpfs /path/to/cache(s) No issues after that.

It also makes supervisor sockets happy if you store them in a tmpfs. YMMV

@dh1tw
Copy link

dh1tw commented Sep 24, 2016

I confirm - I get the same error message on my Rootserver (Ubuntu 14.04). Using any tag (daily, latest, 10.0).

Client:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   23cf638
 Built:        Thu Aug 18 05:22:43 2016
 OS/Arch:      linux/amd64

Server:
 Version:      1.12.1
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   23cf638
 Built:        Thu Aug 18 05:22:43 2016
 OS/Arch:      linux/amd64

@Wonderfall
Copy link
Owner

Can someone try to update aufs or to use another fs on Ubuntu 14.04? I'm now pretty sure there's something wrong with older versions of aufs.

@Vingtoft
Copy link

Did anyone find a solution to this problem?

@Wonderfall
Copy link
Owner

Wonderfall commented Sep 26, 2016

What aufs version are you using? I see many issues with aufs about this.
Like moby/moby#20240.

I'm not really sure but in order to fix this problem you should likely upgrade aufs, or consider using another fs supported by Docker such as overlay (the one I'm using) or btrfs. I'm deeply sorry guys but I'm not willing to downgrade and add root processes, that would be a security regression. :(

@dh1tw
Copy link

dh1tw commented Sep 26, 2016

I can confirm that updating to Ubuntu 16.04, which comes with aufs 4.x solved the problem.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants