Posts by tama777

    Tama. Thanks so much. Great guide. Needed to change kernel to 58 and had to use a different driver for my card (450.80.02) for a Geoforce 1050 ti. You don't say anything about backport/header installation. Did you do this before this driver install or does this do it automatically?


    Thanks. ML

    Hi ML!

    I mentioned in my first comment:

    Quote

    My Openmediavault System is OMV5.3.9-1 with Linux 5.4.0-0.bpo.-amd64 kernel and NVIDIA GeForce GTX1660. Plex hardware transcoding works for me based on the following (If Plex doesn't hardware transcode, check this video) :

    Step 1: Install the NVIDIA driver based on the second option (How to install NVIDIA driver by using the official nvidia.com package step by step instructions).

    (If you are installing another bpo kernel, you will need to reinstall the Nvidia driver compilation prerequisite: apt -y install linux-headers-$(uname -r) )

    in this comment shows the "omv.jpg" & "linux-headers.jpg".


    Currently, My Openmediavault System is OMV5.5.20-1 with Linux 5.9.0-0.bpo.2-amd64 kernel, NVIDIA Linux Graphics Driver 455.45.01 (Linux Short Lived (Kernel 5.9 support)) and NVIDIA GeForce GTX1660. Works well


    Fixed: NVIDIA-Linux-x86_64-460.27.04



    I don't know what the problem might be for you, I was able to install the nvml_fix and the nvidia-patch without error.

    Install nvml_fix (NVIDIA Linux Graphics Driver 440.64) :


    apt install -y git


    git clone https://github.com/CFSworks/nvml_fix.git

    cd nvml_fix

    make TARGET_VER=440.64

    sudo dpkg-divert --add --local --divert /usr/lib/x86_64-linux-gnu/libnvidia-ml.so.1.orig --rename /usr/lib/x86_64-linux-gnu/libnvidia-ml.so.1

    sudo make install TARGET_VER=440.64 libdir=/usr/lib/x86_64-linux-gnu

    before_nvml_fix_440.64.txt  after_nvml_fix_440.64.txt


    then I installed the latest nvidia driver (NVIDIA Linux Graphics Driver 440.82) (if you are using a container in the Docker (e.g. Plex) that uses the nvidia card, stop the Docker before installing newest nvidia driver) and I reinstalled the nvml_fix:


    cd nvml_fix

    make TARGET_VER=440.82

    sudo dpkg-divert --add --local --divert /usr/lib/x86_64-linux-gnu/libnvidia-ml.so.1.orig --rename /usr/lib/x86_64-linux-gnu/libnvidia-ml.so.1

    sudo make install TARGET_VER=440.82 libdir=/usr/lib/x86_64-linux-gnu

    before_nvml_fix_440.82.txt  after_nvml_fix_440.82.txt


    Install nvidia-patch:


    git clone https://github.com/keylase/nvidia-patch.git

    cd nvidia-patch

    bash ./patch.sh

    Quote

    Im just curious why does the NVIDIA docker keeps replicating I have 2 unusable docker images of it in my docker.

    When you run the docker run --gpus all nvidia/cuda:10.0-base nvidia-smi command, it downloads the "nvidia/cuda:10.0-base" image, which it uses to test the nvidia-container-toolkit and nvidia-container-runtime, so you can safely delete the containers



    and then the "nvidia/cuda:10.0-base" image.


    Quote

    It still does not show HW transcoding so I don't know why?

    In nvidia-smi: I found this and this (with the solution? (I can't try it because nvidia-smi works well for me)).

    In Plex: If I start the hardware transcoding in Plex I have the hw indication after about 7 seconds.


    Quote

    Just noticed whenever Jellyfin is running Plex will hw decode stuff as the CPU stays under 20% activity. Now when Jellyfin is closed it hit's the CPU hard.

    Now I watched it with Plex + Handbrake duo, but CPU usage didn't jump when I stop Handbrake (although the Handbrake only encodes using the nvidia card). (For me, at the moment Jellyfin does not want to use the nvidia card for hardware transcoding.)

    Please see if the hardware transcoding works with Jellyfin.


    Example:


    I think, your OMV + Docker + NVIDIA video card system is ready to hardware transcoding, but ....


    Quote

    Not sure why it's saying not supported?

    what video or movie do you want to transcode, H.264 or HEVC or...... because your video card (GTX 760) only supports transcoding up to H264.


    Read these articles:

    Using Hardware-Accelerated Streaming

    NVIDIA Hardware Transcoding Calculator for Plex

    root@openmediavault:~# nvidia-smi

    -bash: nvidia-smi: command not found

    The NVIDIA driver is not properly installed, please reinstall it!

    (If you install it properly, we will continue troubleshooting if any!)


    An example (OMV 5 + OMV-Extras + Docker 5:19.03.8~3-0~debian-buster + NVIDIA Linux Graphics Driver v440.64):



    omv.jpg


    Code
    apt -y install nvidia-detect

    nvidia-detect.jpg


    Code
    nvidia-detect

    nvidia-detect2.jpg


    Code
    wget http://us.download.nvidia.com/XFree86/Linux-x86_64/440.64/NVIDIA-Linux-x86_64-440.64.run

    wget.jpg


    Code
    apt -y install linux-headers-$(uname -r) build-essential

    linux-headers.jpg


    Code
    echo blacklist nouveau > /etc/modprobe.d/blacklist-nvidia-nouveau.conf
    Code
    systemctl set-default multi-user.target

    nouveau.jpg


    Code
    systemctl reboot
    Code
    bash NVIDIA-Linux-x86_64-440.64.run

    nvidia_driver.jpg


    Code
    systemctl set-default graphical.target

    graphical.target.jpg


    Code
    systemctl reboot
    Code
    nvidia-smi

    nvidia-smi.jpg

    So this is what I am getting, what do I do next?


    docker: Error response from daemon: OCI runtime create failed: container_linux.g o:349: starting container process caused "process_linux.go:449: container init c aused \"process_linux.go:432: running prestart hook 0 caused \\\"error running h ook: exit status 1, stdout: , stderr: nvidia-container-cli: initialization error : driver error: failed to process request\\\\n\\\"\"": unknown.

    ERRO[0026] error waiting for container: context canceled


    Login to your system via ssh as root, please run the following command lines separately and paste the results here:

    Code
    nvidia-smi 
    Code
    docker run --gpus all nvidia/cuda:10.0-base nvidia-smi

    After following all these steps I get the following error after running the test command for the Nvidia cuda container:

    Code
    NVIDIA-SMI couldn't find libnvidia-ml.so library in your system. Please make sure that the NVIDIA Display Driver is properly installed and present in your system.
    Please also try adding directory that contains libnvidia-ml.so to your system PATH.

    Unfortunately this is the same error I got when I first started out trying to get this stuff to work.

    FWIW, here is my nvidia-smi output. I have the same driver version as you, which is the latest. Previously I tried a 390 legacy driver but it complained that it was out of date when I ran the cuda container command.

    What is the contents of /etc/nvidia-container-runtime/config.toml, please copy and paste here.

    My Openmediavault System is OMV5.3.9-1 with Linux 5.4.0-0.bpo.-amd64 kernel and NVIDIA GeForce GTX1660. Plex hardware transcoding works for me based on the following (If Plex doesn't hardware transcode, check this video) :



    Step 1: Install the NVIDIA driver based on the second option (How to install NVIDIA driver by using the official nvidia.com package step by step instructions).

    (If you are installing another bpo kernel, you will need to reinstall the Nvidia driver compilation prerequisite: apt -y install linux-headers-$(uname -r) )


    Step 2: Install the Curl command-line utility:


    Code
    sudo apt install curl


    Step 3: Installing the NVIDIA Container Toolkit:


    # Add the package repositories

    Code
    distribution=$(. /etc/os-release;echo $ID$VERSION_ID)
    curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | sudo apt-key add -
    curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | sudo tee /etc/apt/sources.list.d/nvidia-docker.list

    then

    Code
    sudo apt-get update && sudo apt-get install -y nvidia-container-toolkit
    sudo systemctl restart docker



    Step 4: Installing nvidia-container-runtime:


    Code
    sudo apt-get install nvidia-container-runtime


    Step 5: Edit /etc/nvidia-container-runtime/config.toml eg. nano and replace "@/sbin/ldconfig" with "/sbin/ldconfig", then save the file. (Thanks to lyon667!)


    Step 6: If you want NVIDIA to be the default Docker runtime, modify the contents of /etc/docker/daemon.json to:


    Code
    {
    "runtimes": {
    "nvidia": {
    "path": "/usr/bin/nvidia-container-runtime",
    "runtimeArgs": []
    }
    },
    "default-runtime": "nvidia"
    }

    Step 7:

    Code
    sudo systemctl restart docker

    Step 8: Install linuxserver/plex


    For example, it looks like this to me:




    Maybe it helps.


    cuda.jpgPlex.jpg