Import Error: libopenblas.so.0: Cannot open shared object file: No such file or directory

Please provide the following info (tick the boxes after creating this topic):
Software Version
DRIVE OS 6.0.6

Target Operating System
Linux

Hardware Platform
DRIVE AGX Orin Developer Kit (not sure its number)

SDK Manager Version
other

Host Machine Version
native Ubuntu Linux 20.04 Host installed with SDK Manager

I have installed torch-2.1.0a0+41361538.nv23.06-cp38-cp38-linux_aarch64.whl. There are no errors during installation. But when I run import torch I am getting “Import Error: libopenblas.so.0: Cannot open shared object file: No such file or directory” this error.

Thanks in Advance.

Dear @m.sachin6,
Could you share more details about reproduce the issue?

@m.sachin6 Did you install openblas on target?

nvidia@tegra-ubuntu:~$ sudo apt-get install libopenblas-dev
[sudo] password for nvidia:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  gcc-10-base libatomic1 libcc1-0 libgcc-s1 libgfortran5 libgomp1 libitm1 liblsan0 libopenblas-pthread-dev
  libopenblas0 libopenblas0-pthread libstdc++6 libtsan0 libubsan1
The following NEW packages will be installed:
  libgfortran5 libopenblas-dev libopenblas-pthread-dev libopenblas0 libopenblas0-pthread
The following packages will be upgraded:
  gcc-10-base libatomic1 libcc1-0 libgcc-s1 libgomp1 libitm1 liblsan0 libstdc++6 libtsan0 libubsan1
10 upgraded, 5 newly installed, 0 to remove and 168 not upgraded.
Need to get 12.5 MB of archives.
After this operation, 68.4 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libatomic1 arm64 10.5.0-1ubuntu1~20.04 [9808 B]
Get:2 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libubsan1 arm64 10.5.0-1ubuntu1~20.04 [765 kB]
Get:3 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libtsan0 arm64 10.5.0-1ubuntu1~20.04 [1972 kB]
Get:4 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 gcc-10-base arm64 10.5.0-1ubuntu1~20.04 [20.8 kB]
Get:5 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libstdc++6 arm64 10.5.0-1ubuntu1~20.04 [461 kB]
Get:6 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 liblsan0 arm64 10.5.0-1ubuntu1~20.04 [800 kB]
Get:7 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libitm1 arm64 10.5.0-1ubuntu1~20.04 [24.1 kB]
Get:8 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libgomp1 arm64 10.5.0-1ubuntu1~20.04 [93.5 kB]
Get:9 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libcc1-0 arm64 10.5.0-1ubuntu1~20.04 [46.2 kB]
Get:10 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libgcc-s1 arm64 10.5.0-1ubuntu1~20.04 [34.6 kB]
Get:11 http://ports.ubuntu.com/ubuntu-ports focal-updates/main arm64 libgfortran5 arm64 10.5.0-1ubuntu1~20.04 [346 kB]
Get:12 http://ports.ubuntu.com/ubuntu-ports focal-updates/universe arm64 libopenblas0-pthread arm64 0.3.8+ds-1ubuntu0.20.04.1 [5153 kB]
Get:13 http://ports.ubuntu.com/ubuntu-ports focal-updates/universe arm64 libopenblas0 arm64 0.3.8+ds-1ubuntu0.20.04.1 [5892 B]
Get:14 http://ports.ubuntu.com/ubuntu-ports focal-updates/universe arm64 libopenblas-pthread-dev arm64 0.3.8+ds-1ubuntu0.20.04.1 [2787 kB]
Get:15 http://ports.ubuntu.com/ubuntu-ports focal-updates/universe arm64 libopenblas-dev arm64 0.3.8+ds-1ubuntu0.20.04.1 [16.4 kB]
Fetched 12.5 MB in 10s (1304 kB/s)
debconf: delaying package configuration, since apt-utils is not installed
(Reading database ... 59494 files and directories currently installed.)
Preparing to unpack .../libatomic1_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libatomic1:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Preparing to unpack .../libubsan1_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libubsan1:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Preparing to unpack .../libtsan0_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libtsan0:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Preparing to unpack .../gcc-10-base_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking gcc-10-base:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Setting up gcc-10-base:arm64 (10.5.0-1ubuntu1~20.04) ...
(Reading database ... 59493 files and directories currently installed.)
Preparing to unpack .../libstdc++6_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libstdc++6:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Setting up libstdc++6:arm64 (10.5.0-1ubuntu1~20.04) ...
(Reading database ... 59493 files and directories currently installed.)
Preparing to unpack .../liblsan0_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking liblsan0:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Preparing to unpack .../libitm1_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libitm1:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Preparing to unpack .../libgomp1_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libgomp1:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Preparing to unpack .../libcc1-0_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libcc1-0:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Preparing to unpack .../libgcc-s1_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libgcc-s1:arm64 (10.5.0-1ubuntu1~20.04) over (10.3.0-1ubuntu1~20.04) ...
Setting up libgcc-s1:arm64 (10.5.0-1ubuntu1~20.04) ...
Selecting previously unselected package libgfortran5:arm64.
(Reading database ... 59493 files and directories currently installed.)
Preparing to unpack .../libgfortran5_10.5.0-1ubuntu1~20.04_arm64.deb ...
Unpacking libgfortran5:arm64 (10.5.0-1ubuntu1~20.04) ...
Selecting previously unselected package libopenblas0-pthread:arm64.
Preparing to unpack .../libopenblas0-pthread_0.3.8+ds-1ubuntu0.20.04.1_arm64.deb ...
Unpacking libopenblas0-pthread:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
Selecting previously unselected package libopenblas0:arm64.
Preparing to unpack .../libopenblas0_0.3.8+ds-1ubuntu0.20.04.1_arm64.deb ...
Unpacking libopenblas0:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
Selecting previously unselected package libopenblas-pthread-dev:arm64.
Preparing to unpack .../libopenblas-pthread-dev_0.3.8+ds-1ubuntu0.20.04.1_arm64.deb ...
Unpacking libopenblas-pthread-dev:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
Selecting previously unselected package libopenblas-dev:arm64.
Preparing to unpack .../libopenblas-dev_0.3.8+ds-1ubuntu0.20.04.1_arm64.deb ...
Unpacking libopenblas-dev:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
Setting up libgomp1:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up libatomic1:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up libgfortran5:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up libubsan1:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up libcc1-0:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up liblsan0:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up libitm1:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up libtsan0:arm64 (10.5.0-1ubuntu1~20.04) ...
Setting up libopenblas0-pthread:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
update-alternatives: using /usr/lib/aarch64-linux-gnu/openblas-pthread/libblas.so.3 to provide /usr/lib/aarch64-linux-gnu/libblas.so.3 (libblas.so.3-aarch64-linux-gnu) in auto mode
update-alternatives: using /usr/lib/aarch64-linux-gnu/openblas-pthread/liblapack.so.3 to provide /usr/lib/aarch64-linux-gnu/liblapack.so.3 (liblapack.so.3-aarch64-linux-gnu) in auto mode
update-alternatives: using /usr/lib/aarch64-linux-gnu/openblas-pthread/libopenblas.so.0 to provide /usr/lib/aarch64-linux-gnu/libopenblas.so.0 (libopenblas.so.0-aarch64-linux-gnu) in auto mode
Setting up libopenblas0:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
Setting up libopenblas-pthread-dev:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
update-alternatives: using /usr/lib/aarch64-linux-gnu/openblas-pthread/libblas.so to provide /usr/lib/aarch64-linux-gnu/libblas.so (libblas.so-aarch64-linux-gnu) in auto mode
update-alternatives: using /usr/lib/aarch64-linux-gnu/openblas-pthread/liblapack.so to provide /usr/lib/aarch64-linux-gnu/liblapack.so (liblapack.so-aarch64-linux-gnu) in auto mode
update-alternatives: using /usr/lib/aarch64-linux-gnu/openblas-pthread/libopenblas.so to provide /usr/lib/aarch64-linux-gnu/libopenblas.so (libopenblas.so-aarch64-linux-gnu) in auto mode
Setting up libopenblas-dev:arm64 (0.3.8+ds-1ubuntu0.20.04.1) ...
Processing triggers for libc-bin (2.31-0ubuntu9.9) ...
/sbin/ldconfig.real: /lib/aarch64-linux-gnu/libnl-genl-3.so.200 is not a symbolic link

nvidia@tegra-ubuntu:~$ sudo updatedb
sudo: updatedb: command not found
nvidia@tegra-ubuntu:~$ sudo apt-get install locate
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
  locate
0 upgraded, 1 newly installed, 0 to remove and 168 not upgraded.
Need to get 82.9 kB of archives.
After this operation, 245 kB of additional disk space will be used.
Get:1 http://ports.ubuntu.com/ubuntu-ports focal/universe arm64 locate arm64 4.7.0-1ubuntu1 [82.9 kB]
Fetched 82.9 kB in 1s (60.5 kB/s)
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package locate.
(Reading database ... 59540 files and directories currently installed.)
Preparing to unpack .../locate_4.7.0-1ubuntu1_arm64.deb ...
Unpacking locate (4.7.0-1ubuntu1) ...
Setting up locate (4.7.0-1ubuntu1) ...
nvidia@tegra-ubuntu:~$ ls /usr/lib/aarch64-linux-gnu/libopenblas.so.0
/usr/lib/aarch64-linux-gnu/libopenblas.so.0

Thanks a lot @SivaRamaKrishnaNV. The solution you provided has worked.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.