• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Support Troubleshooting SOLVED: unable to find user in passwd file (docker compose)

     
    • 0 Vote(s) - 0 Average

    SOLVED: unable to find user in passwd file (docker compose)

    Pollo
    Offline

    Junior Member

    Posts: 14
    Threads: 3
    Joined: 2024 Oct
    Reputation: 0
    Country:United States
    #1
    2024-12-18, 02:49 AM (This post was last modified: 2024-12-18, 04:49 AM by Pollo. Edited 2 times in total.)
    Hello! I am trying to set up docker and after using the documentation for docker compose setup, I'm getting this error when I try to start the container with docker compose up:

    "Error response from daemon: unable to find user pete: no matching entries in passwd file"

    I don't understand why i'm getting this error because my user is in the passwd file already. I am running the latest stable build of the Ubuntu docker container runtime (27.2.0). Here is my docker-compose.yml file:
    Code:
    services:
      jellyfin:
        image: 'jellyfin/jellyfin:latest'
        container_name: jellyfin
        user: pete:pete
        network_mode: 'host'
        ports:
        - 8096:8096
        volumes:
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-config:/config
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-cache:/cache
          - type: bind
            source: /media/pete/{media dir}
            target: /media
          #- type: bind
            #source: /path/to/media2
            #target: /media2
            #read_only: true
          # Optional - extra fonts to be used during transcoding with subtitle burn-in
          - type: bind
            source: /home/pete/snap/docker/jellyfin/fonts
            target: /usr/local/share/fonts/custom
            read_only: true
        restart: 'unless-stopped'
        # Optional - alternative address used for autodiscovery
        #environment:
          #- JELLYFIN_PublishedServerUrl=http://example.com
        # Optional - may be necessary for docker healthcheck to pass if running in host network mode
        extra_hosts:
          - 'host.docker.internal:host-gateway'

    Any help will be appriciated!
    Go to solution
    theguymadmax
    Offline

    Community Moderator

    Posts: 1,108
    Threads: 0
    Joined: 2024 Jun
    Reputation: 59
    #2
    2024-12-18, 03:10 AM
    In the terminal, type: id
    This will display your UID and GID, which you can then enter for the user. See the example below:


    Code:
    services:
      jellyfin:
        image: jellyfin/jellyfin:latest
        container_name: jellyfin
        user: 1000:1000
        group_add:
          - "992" #render
        network_mode: 'host'
        volumes:
          - /home/max/docker/Jellyfin/Config:/config
          - /home/max/docker/Jellyfin/Cache:/cache
          - /media/Media:/Media
        restart: 'unless-stopped'
        devices:
          - /dev/dri/renderD128:/dev/dri/renderD128
    Pollo
    Offline

    Junior Member

    Posts: 14
    Threads: 3
    Joined: 2024 Oct
    Reputation: 0
    Country:United States
    #3
    2024-12-18, 05:17 AM (This post was last modified: 2024-12-18, 05:21 AM by Pollo. Edited 1 time in total.)
    (2024-12-18, 03:10 AM)theguymadmax Wrote: In the terminal, type: id
    This will display your UID and GID, which you can then enter for the user. See the example below:


    Code:
    services:
      jellyfin:
        image: jellyfin/jellyfin:latest
        container_name: jellyfin
        user: 1000:1000
        group_add:
          - "992" #render
        network_mode: 'host'
        volumes:
          - /home/max/docker/Jellyfin/Config:/config
          - /home/max/docker/Jellyfin/Cache:/cache
          - /media/Media:/Media
        restart: 'unless-stopped'
        devices:
          - /dev/dri/renderD128:/dev/dri/renderD128

    Thank you, that seemed to work! However I'm getting a new error now

    Code:
    jellyfin  | Unhandled exception.
    jellyfin  | System.UnauthorizedAccessException: Access to the path '/config/log' is denied.
    jellyfin  |  ---> System.IO.IOException: Permission denied
    jellyfin  |    --- End of inner exception stack trace ---
    jellyfin  |    at System.IO.FileSystem.CreateDirectory(String fullPath, UnixFileMode unixCreateMode)
    jellyfin  |    at System.IO.Directory.CreateDirectory(String path)
    jellyfin  |    at Jellyfin.Server.Helpers.StartupHelpers.CreateApplicationPaths(StartupOptions options)
    jellyfin  |    at Jellyfin.Server.Program.StartApp(StartupOptions options)
    jellyfin  |    at Jellyfin.Server.Program.<Main>(String[] args)
    jellyfin exited with code 139

    I tried changing the directories, creating them, and disable + re-enabling docker through snap, but I still get the same error. I'm not sure if this change is correct or if I need to make the /config/log directory.
    Code:
    volumes:
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-config:/var/log/docker/jellyfin/config
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-cache:/var/log/docker/jellyfin/cache
    theguymadmax
    Offline

    Community Moderator

    Posts: 1,108
    Threads: 0
    Joined: 2024 Jun
    Reputation: 59
    #4
    2024-12-18, 05:02 PM (This post was last modified: 2024-12-18, 05:08 PM by theguymadmax. Edited 1 time in total.)
    You don't have permission to access the specified locations. To resolve this, I recommend the following steps:

    1. Create a Docker Folder in Your Home Directory:

    Set up a dedicated directory for your Docker containers and their associated data inside your home directory. This way, you will have full control over the directories and avoid permission issues. Make sure folder are created prior to running docker compose up -d.

    Directory Structure:
    • /home/pete/Docker/
    • /home/pete/Docker/Jellyfin/
    • /home/pete/Docker/Jellyfin/config/
    • /home/pete/Docker/Jellyfin/cache/
    • /home/pete/Docker/Jellyfin/docker-compose.yml

    2. Update Your docker-compose.yml File:

    Modify the volumes section in your docker-compose.yml to point to the new directories you created in your home directory.

    Original:
    Code:
    volumes:
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-config:/var/log/docker/jellyfin/config
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-cache:/var/log/docker/jellyfin/cache

     
    Updated:
    Code:
    volumes:
          - /home/pete/Docker/Jellyfin/config:/config
          - /home/pete/Docker/Jellyfin/cache:/cache
    Pollo
    Offline

    Junior Member

    Posts: 14
    Threads: 3
    Joined: 2024 Oct
    Reputation: 0
    Country:United States
    #5
    2024-12-19, 01:02 AM
    (2024-12-18, 05:02 PM)theguymadmax Wrote: You don't have permission to access the specified locations. To resolve this, I recommend the following steps:

    1. Create a Docker Folder in Your Home Directory:

    Set up a dedicated directory for your Docker containers and their associated data inside your home directory. This way, you will have full control over the directories and avoid permission issues. Make sure folder are created prior to running docker compose up -d.

    Directory Structure:
    • /home/pete/Docker/
    • /home/pete/Docker/Jellyfin/
    • /home/pete/Docker/Jellyfin/config/
    • /home/pete/Docker/Jellyfin/cache/
    • /home/pete/Docker/Jellyfin/docker-compose.yml

    2. Update Your docker-compose.yml File:

    Modify the volumes section in your docker-compose.yml to point to the new directories you created in your home directory.

    Original:
    Code:
    volumes:
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-config:/var/log/docker/jellyfin/config
          - /var/snap/docker/common/var-lib-docker/volumes/jellyfin-cache:/var/log/docker/jellyfin/cache

     
    Updated:
    Code:
    volumes:
          - /home/pete/Docker/Jellyfin/config:/config
          - /home/pete/Docker/Jellyfin/cache:/cache

    Oh ok, thank you for the explanation! I'll most likely stick to this method, but would it be better in the long term for me to use volumes instead of bind mounts?
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode