# lib/ld-linux.so.2: bad ELF interpreter: No such file or directory



## Boylett

I get this error: "lib/ld-linux.so.2: bad ELF interpreter: No such file or directory" when I try to run a 32 bit binary on a 32 bit system. Nothing in google helps (most of them are trying to run 32 bit on 64 bit or vice versa).

I have installed all glibc packages.

How can it be fixed?

Thanks.


----------



## lotuseclat79

Hi Boylett,

We need a bit more context for your problem. What software (i.e. the 32-bit binary) were you trying to run on which Linux distribution?

What is the result of the following command on your linux:
$ ls -lt /lib/linux*

On my linux (Ubuntu 9.10) aka Karmic Koala, the resuilt is the following:
[email protected]:~/Desktop$ ls -lt /lib/ld-linux*
lrwxrwxrwx 1 root root 12 2009-10-28 16:55 /lib/ld-linux.so.2 -> ld-2.10.1.so

If you have the file, ld-2.10.1.so in /lib, and there is no file /lib/ld-linux.so.2, then you can create a symbolic link to the existing file that might help correct the problem as follows:
[email protected]:~$ sudo -i
# cd /lib
# ln -s ld-2.10.1.so ld-linux.so.2
# exit

-- Tom


----------



## Boylett

I'm running CentOS 5, and I'm trying to run an SA-MP server (x86).

ls -lt /lib/linux*
ls: /lib/linux*: No such file or directory

ls -lt /lib/ | grep linux
lrwxrwxrwx 1 root root 9 Dec 10 17:31 ld-linux.so.2 -> ld-2.5.so

ls -al /lib | grep ld-2.5.so
-rwxr-xr-x 1 root root 124432 Sep 3 02:56 ld-2.5.so
lrwxrwxrwx 1 root root 9 Dec 10 17:31 ld-linux.so.2 -> ld-2.5.so


----------



## lotuseclat79

What version of CentOS do you have, i.e. run the following command:
$ cat /etc/lsb-release

Since your post indicates that you have ld-2.5.so, you may need to upgrade the package libc6 or libc6-i686 or libc6-dev which should get you a more recent version of the ld-2.xx.so module.

Either that or upgrade your release of CentOS to the latest stable release which is 5.4.

-- Tom


----------

