Libnvinfer.so.8: cannot open shared object file: No such file or directory

Please provide complete information as applicable to your setup.

• Hardware Platform (Jetson / GPU)
Xavier NX
• DeepStream Version
6.0
• JetPack Version (valid for Jetson only)
R32 (release), REVISION: 6.1, GCID: 27863751, BOARD: t186ref, EABI: aarch64, DATE: Mon Jul 26 19:36:31 UTC 2021
• TensorRT Version
8.0.1.6-1+cuda10.2
• NVIDIA GPU Driver Version (valid for GPU only)
• Issue Type( questions, new requirements, bugs)
bugs
• How to reproduce the issue ? (This is for bugs. Including which sample app is using, the configuration files content, the command line used and other details for reproducing)

     add "default-runtime" : "nvidia" to /etc/docker/daemon.json root

    {
        "default-runtime" : "nvidia",
        
    sudo apt-get install curl

    distribution=$(. /etc/os-release;echo $ID$VERSION_ID) \
    && curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | sudo gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg \
    && curl -s -L https://nvidia.github.io/libnvidia-container/experimental/$distribution/libnvidia-container.list | \
    sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
    sudo tee /etc/apt/sources.list.d/nvidia-container-toolkit.list
    
    sudo apt-get update
    
    sudo apt-get install -y nvidia-docker2
    
    sudo systemctl restart docker

then

    docker pull nvcr.io/nvidia/deepstream-l4t:6.0-samples
    
    and in the container
 
    deepstream-app
    deepstream-app: error while loading shared libraries: libnvinfer.so.8: cannot open shared object file: No such file or directory

it works well in the host machine

like @zkaiser says here Deepstream-l4t:6.0-samples not finding libnvparsers.so in the container the file /usr/lib/aarch64-linux-gnu/libnvparsers.so.8 is not found, but is present in the host machine

@zkaiser solved by downgrading libnvidia-container0 to 0.10.0+jetpack version

but for me it’s already the last version available

apt-cache policy libnvidia-container0
libnvidia-container0:
  Installed: 0.10.0+jetpack

and i found also a libnvidia-container1 package, dunno which one is currently used

apt-cache policy libnvidia-container1
libnvidia-container1:
  Installed: 1.10.0~rc.3-1
  Candidate: 1.10.0~rc.3-1
  Version table:
 *** 1.10.0~rc.3-1 500
        500 https://nvidia.github.io/libnvidia-container/experimental/ubuntu18.04/arm64  Packages
        100 /var/lib/dpkg/status

tryed with this configuration (stable channel instead of experimental)

cat /etc/apt/sources.list.d/nvidia-container-toolkit.list
deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/$(ARCH) /
# deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://nvidia.github.io/libnvidia-container/experimental/ubuntu18.04/$(ARCH) /

sudo apt-cache policy nvidia-docker2
nvidia-docker2:
  Installed: 2.11.0-1
  Candidate: 2.11.0-1
  Version table:
 *** 2.11.0-1 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages
        100 /var/lib/dpkg/status
     2.10.0-1 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages
     2.9.1-1 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages
     2.9.0-1 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages
     2.8.0-1 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages
     2.7.0-1 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages

apt-cache policy libnvidia-container0
libnvidia-container0:
  Installed: 0.10.0+jetpack
  Candidate: 0.11.0+jetpack
  Version table:
     0.11.0+jetpack 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages
 *** 0.10.0+jetpack 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages
        100 /var/lib/dpkg/status
     0.9.0~beta.1 500
        500 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/arm64  Packages

but the error is the same

thank you, William

It’s softlink, you can create it in container.

ln -s /usr/lib/aarch64-linux-gnu/libnvparsers.so.8.0.1 /usr/lib/aarch64-linux-gnu/libnvparsers.so.8
ln -s /usr/lib/aarch64-linux-gnu/libnvparsers.so.8 /usr/lib/aarch64-linux-gnu/libnvparsers.so

the files are missing in the container as you can see

root@62848c62b394:/app# ls -l /usr/lib/aarch64-linux-gnu/libnv*
-rw-r--r-- 1 root root 425040 Jul 26  2021 /usr/lib/aarch64-linux-gnu/libnvsample_cudaprocess.so

You can mount from host to container.

shouldn’t be done automatically by the nvidia runtime docker environment?

btw i tryed by mounting - /usr/lib/aarch64-linux-gnu:/usr/lib/aarch64-linux-gnu from the host machine

and there are more errors, btw it didn’t happen before it worked well on another edge machine

root@be7856040cb9:~# gst-inspect-1.0 
(Argus) Error FileOperationFailed: Connecting to nvargus-daemon failed: No such file or directory (in src/rpc/socket/client/SocketClientDispatch.cpp, function openSocketConnection(), line 205)
(Argus) Error FileOperationFailed: Cannot create camera provider (in src/rpc/socket/client/SocketClientDispatch.cpp, function createCameraProvider(), line 106)

(gst-plugin-scanner:124): GStreamer-WARNING **: 08:47:29.960: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_infer.so': libcublas.so.10: cannot open shared object file: No such file or directory

(gst-plugin-scanner:124): GStreamer-WARNING **: 08:47:30.050: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_udp.so': librivermax.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:124): GStreamer-WARNING **: 08:47:30.060: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_inferaudio.so': libcufft.so.10: cannot open shared object file: No such file or directory

(gst-plugin-scanner:124): GStreamer-WARNING **: 08:47:30.072: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_deepstream_bins.so': libcublas.so.10: cannot open shared object file: No such file or directory

(gst-plugin-scanner:124): GStreamer-WARNING **: 08:47:30.085: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_inferserver.so': libtritonserver.so: cannot open shared object file: No such file or directory

(gst-plugin-scanner:124): GStreamer-WARNING **: 08:47:30.098: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libcustom2d_preprocess.so': /usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libcustom2d_preprocess.so: undefined symbol: NvBufSurfTransformAsync

(gst-plugin-scanner:124): GStreamer-WARNING **: 08:47:30.100: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_preprocess.so': /usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_preprocess.so: undefined symbol: NvBufSurfTransformAsync

it worked by mounting these folder from the host machine

  - /usr/lib/aarch64-linux-gnu:/usr/lib/aarch64-linux-gnu
  - /usr/local/cuda-10.2/targets/aarch64-linux/lib:/usr/local/cuda-10.2/targets/aarch64-linux/lib

but it seems not a reals solution but a “hacky” one

btw warnings are still present

(Argus) Error FileOperationFailed: Cannot create camera provider (in src/rpc/socket/client/SocketClientDispatch.cpp, function createCameraProvider(), line 106)

gst-plugin-scanner:47): GStreamer-WARNING **: 09:01:48.277: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_udp.so': librivermax.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:47): GStreamer-WARNING **: 09:01:48.380: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_inferserver.so': libtritonserver.so: cannot open shared object file: No such file or directory

(gst-plugin-scanner:47): GStreamer-WARNING **: 09:01:48.390: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libcustom2d_preprocess.so': /usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libcustom2d_preprocess.so: undefined symbol: NvBufSurfTransformAsync

gst-plugin-scanner:47): GStreamer-WARNING **: 09:01:48.392: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_preprocess.so': /usr/lib/aarch64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_preprocess.so: undefined symbol: NvBufSurfTransformAsync

Please follow Quickstart Guide — DeepStream 6.0 Release documentation
Install latest NVIDIA BSP packages