linuxserver / docker-calibre

GNU General Public License v3.0
339 stars 62 forks source link

PUID/PGID setting to 1032/100 fails to start #20

Closed rcarmo closed 4 years ago

rcarmo commented 4 years ago

linuxserver.io

If you are new to Docker or this application our issue tracker is ONLY used for reporting bugs or requesting features. Please use our discord server for general support.


Expected Behavior

The container should start regardless of values

Current Behavior

The container enters a crash loop with the following output:

chansrv::main: using log file [/tmp/xrdp-chansrv.1.log]                                            
Could not start log                                                                                
error opening log file [The log is not properly started]. quitting.                                
chansrv::main: using log file [/tmp/xrdp-chansrv.1.log]                                            
Could not start log                                                                                
error opening log file [The log is not properly started]. quitting.                                
chansrv::main: using log file [/tmp/xrdp-chansrv.1.log]                                            
Could not start log                                                                                
error opening log file [The log is not properly started]. quitting.                                

Steps to Reproduce

  1. Install container on Synology NAS
  2. Set environment variables PUID/PGID to 1032/100
  3. Start it

Environment

OS: Synology DSM 6.x CPU architecture: x86_64
How docker service was installed: Built in to DSM

Command used to create docker container (run/create/compose/screenshot)

image

Docker logs

tobbenb commented 4 years ago

The container will not start correctly if the wrong PUID and PGID is used. You have to use the PUID and PGID that have access to the host foldcer of /config.

rcarmo commented 4 years ago

The reason I set the UID/GID was precisely that. I need to use that UID to access both the /config volume and a separate /books volume that is created by that UID.

On 3 Jan 2020, at 23:46, saarg notifications@github.com wrote:

 The container will not start correctly if the wrong PUID and PGID is used. You have to use the PUID and PGID that have access to the host foldcer of /config.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

tobbenb commented 4 years ago

Please supply information about the whole setup of the container, not only the Env variables. Also show the output of ls -al for the host /config folder.

rcarmo commented 4 years ago

Here you go, the remaining settings screens plus a terminal window. The permissions inside /config are correct, as you can see.

Screenshot 2020-01-04 at 11 51 26 Screenshot 2020-01-04 at 11 51 31 Screenshot 2020-01-04 at 11 51 37 Screenshot 2020-01-04 at 11 51 44 Screenshot 2020-01-04 at 11 52 22
rcarmo commented 4 years ago

The Synology log dumps are HTML and finicky to work with, but I'm also attaching a log dump in which you can see the following line:

QStandardPaths: wrong ownership on runtime directory /tmp/runtime-abc, 911 instead of 1032

This leads me to believe that s6-init (or something else) is not changing permissions on /tmp correctly.

Screenshot 2020-01-04 at 12 04 58
tobbenb commented 4 years ago

The permissions should be abc:abc, not abc:users. That might be an issue. As for /tmp, I'm not sure what is going on there. It's for sure wrong permissions.

rcarmo commented 4 years ago

Well, /tmp is inside the container.

tobbenb commented 4 years ago

I just tested it here and it works as it should. Are you sure that the user (UID 1032) have permission to read/write/execute in the host folder of /config? What is the output of ls -al / and ls -al /tmp inside the container? Please also post the output of ls -al in the host folder for /config.

geiger-engineering commented 4 years ago

I've had the exact same problem (using PUID of 1032). I'm not sure why, but deleting all content on the container (right click on container -> action -> delete content [not sure this is the correct name; my Syno is in German]) fixed the problem for me. Maybe it is connected to the Syno logs? I first ran the container with the default user and then modified the environment with the correct PUID/GUID without deleting the container.

tobbenb commented 4 years ago

That makes sense. As the files were created first using one user's UID and then changed. That would make it not accessible

rcarmo commented 4 years ago

I have since updated the container image and the container now starts for me.