• 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 Unable to get hardware acceleration working on Qnap nas with a Nvidia gpu

    Pages (2): 1 2 Next »

     
    • 0 Vote(s) - 0 Average

    Unable to get hardware acceleration working on Qnap nas with a Nvidia gpu

    Envelope6651
    Offline

    Junior Member

    Posts: 9
    Threads: 1
    Joined: 2025 Jan
    Reputation: 0
    #1
    2025-01-02, 12:58 AM
    Hardware:
    Qnap ts-877xu-rp
    Nvidia RTX 3070 on a gpu riser

    Software:
    My nas is running on firmware QTS 5.2.2.2950
    Nvidia driver version 550.67
    Cuda version 12.4
    Jellyfin version 10.10.3

    Hi, I have been stuck for the last couple of days trying to get hardware acceleration working on my Qnap nas. I am running Jellyfin as a container via Portainer. Here is my compose file:
    Code:
    services:
      jellyfin:
        user: 0:0
        privileged: true
        ports:
          - 8096:8096
        image: jellyfin/jellyfin:latest
        devices:
          - /dev/dri
          - /dev/nvidia0
          - /dev/nvidiactl
          - /dev/nvidia-caps
          - /dev/nvidia-uvm
        volumes:
          - /share/ssd-container/jellyfin/config:/config
          - /share/ssd-container/jellyfin/cache:/cache
          - /opt/NVIDIA_GPU_DRV/usr:/usr/local/nvidia:ro
          - /share/JDrive/Movies:/Movies
          - /share/JDrive/Music:/Music
          - /share/JDrive/TVShows:/TVShows
          - /share/JDrive/Anime:/Anime
        environment:
          - LD_LIBRARY_PATH=/usr/local/nvidia/lib
          - PATH=/lsiopy/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/nvidia/bin
          - NVIDIA_VISIBLE_DEVICES=all
          - NVIDIA_DRIVER_CAPABILITIES=all
        restart: 'unless-stopped'
        deploy:
          resources:
            reservations:
              devices:
                - driver: nvidia
                  count: all
                  capabilities: [gpu]

    I have turned on NVENC hardware accelerations in the settings and have checked: x265, HEVC, HEVC 10bit and VP9 10bit. When I try to watch a hevc file on my browser that doesn't support it it just says "Playback failed due to a fatal player error.". When i look in the ffmpeg logs I see:
    Code:
    ffmpeg version 7.0.2-Jellyfin Copyright (c) 2000-2024 the FFmpeg developers
      built with gcc 12 (Debian 12.2.0-14)
      configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto=auto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-opencl --enable-libdrm --enable-libxml2 --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libharfbuzz --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libsvtav1 --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-vaapi --enable-amf --enable-libvpl --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
      libavutil      59.  8.100 / 59.  8.100
      libavcodec    61.  3.100 / 61.  3.100
      libavformat    61.  1.100 / 61.  1.100
      libavdevice    61.  1.100 / 61.  1.100
      libavfilter    10.  1.100 / 10.  1.100
      libswscale      8.  1.100 /  8.  1.100
      libswresample  5.  1.100 /  5.  1.100
      libpostproc    58.  1.100 / 58.  1.100
    [AVHWDeviceContext @ 0x559a3850dbc0] cu->cuInit(0) failed -> CUDA_ERROR_UNKNOWN: unknown error
    Device creation failed: -542398533.
    Failed to set value 'cuda=cu:0' for option 'init_hw_device': Generic error in an external library
    Error parsing global options: Generic error in an external library

    I am able to run nvidia-smi in the container itself and it looks normal. I also ran /usr/lib/jellyfin-ffmpeg/vainfo idk if this helps but here is the output:
    Code:
    Trying display: drm
    libva info: VA-API version 1.22.0
    libva info: Trying to open /usr/lib/jellyfin-ffmpeg/lib/dri/nvidia_drv_video.so
    libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/nvidia_drv_video.so
    libva info: Trying to open /usr/lib/dri/nvidia_drv_video.so
    libva info: Trying to open /usr/local/lib/dri/nvidia_drv_video.so
    libva info: va_openDriver() returns -1
    vaInitialize failed with error code -1 (unknown libva error),exit

    I am pretty lost and I hoped you guys could help me figure this out. Thanks for your time!
    TheDreadPirate
    Offline

    Community Moderator

    Posts: 15,374
    Threads: 10
    Joined: 2023 Jun
    Reputation: 460
    Country:United States
    #2
    2025-01-02, 01:59 PM
    Did you install the Nvidia encode/decode packages? They are not part of the driver, CUDA, or container toolkit.

    Not sure how that works with Nvidia on QNAP.
    Jellyfin 10.10.7 (Docker)
    Ubuntu 24.04.2 LTS w/HWE
    Intel i3 12100
    Intel Arc A380
    OS drive - SK Hynix P41 1TB
    Storage
        4x WD Red Pro 6TB CMR in RAIDZ1
    [Image: GitHub%20Sponsors-grey?logo=github]
    Envelope6651
    Offline

    Junior Member

    Posts: 9
    Threads: 1
    Joined: 2025 Jan
    Reputation: 0
    #3
    2025-01-02, 02:10 PM
    I missed that part I'll look into it thanks!
    Envelope6651
    Offline

    Junior Member

    Posts: 9
    Threads: 1
    Joined: 2025 Jan
    Reputation: 0
    #4
    2025-01-02, 02:17 PM (This post was last modified: 2025-01-02, 02:19 PM by Envelope6651. Edited 1 time in total.)
    I found libnvidia-encode.so and libnvcuvid in the /usr/local/nvidia/lib directory of my container
    TheDreadPirate
    Offline

    Community Moderator

    Posts: 15,374
    Threads: 10
    Joined: 2023 Jun
    Reputation: 460
    Country:United States
    #5
    2025-01-02, 03:11 PM
    Add this to your compose

    Code:
    runtime: nvidia

    https://jellyfin.org/docs/general/admini...ualization
    Jellyfin 10.10.7 (Docker)
    Ubuntu 24.04.2 LTS w/HWE
    Intel i3 12100
    Intel Arc A380
    OS drive - SK Hynix P41 1TB
    Storage
        4x WD Red Pro 6TB CMR in RAIDZ1
    [Image: GitHub%20Sponsors-grey?logo=github]
    Envelope6651
    Offline

    Junior Member

    Posts: 9
    Threads: 1
    Joined: 2025 Jan
    Reputation: 0
    #6
    2025-01-02, 03:14 PM
    doesnt that require the nvidia toolkit. I don't think its possible to install that on a qnap nas
    TheDreadPirate
    Offline

    Community Moderator

    Posts: 15,374
    Threads: 10
    Joined: 2023 Jun
    Reputation: 460
    Country:United States
    #7
    2025-01-02, 03:19 PM (This post was last modified: 2025-01-02, 03:21 PM by TheDreadPirate. Edited 1 time in total.)
    Using Nvidia GPUs with containers, period, requires the nvidia container toolkit. But it may be different with QNAP.

    Oh. I found this old github issue. Give it a read.

    https://github.com/jellyfin/jellyfin/issues/9806

    Scroll down.
    Jellyfin 10.10.7 (Docker)
    Ubuntu 24.04.2 LTS w/HWE
    Intel i3 12100
    Intel Arc A380
    OS drive - SK Hynix P41 1TB
    Storage
        4x WD Red Pro 6TB CMR in RAIDZ1
    [Image: GitHub%20Sponsors-grey?logo=github]
    Envelope6651
    Offline

    Junior Member

    Posts: 9
    Threads: 1
    Joined: 2025 Jan
    Reputation: 0
    #8
    2025-01-02, 04:00 PM (This post was last modified: 2025-01-02, 04:05 PM by Envelope6651. Edited 1 time in total.)
    My compose file is pretty much the exact same as most of the compose files in the comments. I also have the newest nvidia driver that seemed to work for one of them, but it doesn't seem to work for me. I also check persmissions which are correct for all files which should matter i think because i have privileged mode and use user 0:0. My nvidia-smi also works as expected
    TheDreadPirate
    Offline

    Community Moderator

    Posts: 15,374
    Threads: 10
    Joined: 2023 Jun
    Reputation: 460
    Country:United States
    #9
    2025-01-02, 04:03 PM
    It might be worth going over to the QNAP forum and asking there. I'm not finding any documentation for QNAP, nor user created walk throughs.
    Jellyfin 10.10.7 (Docker)
    Ubuntu 24.04.2 LTS w/HWE
    Intel i3 12100
    Intel Arc A380
    OS drive - SK Hynix P41 1TB
    Storage
        4x WD Red Pro 6TB CMR in RAIDZ1
    [Image: GitHub%20Sponsors-grey?logo=github]
    Envelope6651
    Offline

    Junior Member

    Posts: 9
    Threads: 1
    Joined: 2025 Jan
    Reputation: 0
    #10
    2025-01-02, 04:14 PM (This post was last modified: 2025-01-02, 04:20 PM by Envelope6651. Edited 1 time in total.)
    thanks I'll see if they know something. If I find the solution should I post it here? In the mean time if anyone else has any ideas feel free to respond.
    Pages (2): 1 2 Next »

    « 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