Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

bash: No such file or directory (for 32-bit binary on Ubuntu 20.04)

I am trying to run an older, 32-bit binary on Ubuntu 20.04 on an x86_64 machine. Here is the profile of the binary from file:

$ file /usr/local/diamond/3.13/modeltech/linuxloem/vsim
/usr/local/diamond/3.13/modeltech/linuxloem/vsim: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=b8557f9eb74b21146d0eba49769f30f475422d26, stripped

When I execute the binary, I get this error:

$ /usr/local/diamond/3.13/modeltech/linuxloem/vsim
bash: /usr/local/diamond/3.13/modeltech/linuxloem/vsim: No such file or directory

I cannot figure out what the problem is. Permissions on the binary are fine (mwg is my user and group):

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

$ ls -la /usr/local/diamond/3.13/modeltech/linuxloem/vsim
-rwxr-xr-x 1 mwg mwg 7772676 Jul 18  2023 /usr/local/diamond/3.13/modeltech/linuxloem/vsim

The same problem occurs when trying to run the binary as root (i.e., prefixing the command with sudo).

The only thing I can think of is that this binary is expecting an interpreter at /lib/ld-linux.so.2 (from the file output above), and this path does not exist on my system. This answer gave me the idea that I may need to apt install binutils, but I tried that, and it did not fix the problem.

Does anyone have a suggestion for how I can run this binary? Or how to further diagnose the problem?

>Solution :

On my Ubuntu 22.04.4 system, /lib/ld-linux.so.2 is a symlink to /lib/i386-linux-gnu/ld-linux.so.2. That file is provided by the libc6:i386 package.

Installing libc6:i386 will likely correct the problem.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading