Not able to run any command /lib64/ld-Linux-x86-64.so.2: bad ELF interpreter

Hi,

I accidentally did this:

[

wadhwaso@nxsdgd01 deps]$sudo rpm -e --nodeps glibc-2.5-107.x86_64
error: %postun(glibc-2.5-107.x86_64) scriptlet failed, exit status 255

and since then I am not able to run any command on this server except 'cd'.

I always get the following error:

[wadhwaso@nxsdgd01 ~]$ ls
-bash: /bin/ls: /lib64/ld-linux-x86-64.so.2: bad ELF interpreter: No such file or directory

I am not able to access this server via ssh and I cant even scp a file if I want to. i cant use 'touch', I cant 'vi'. I always get this error

I checked on another server for the file and following is the info.:

[

wadhwaso@nxsdgd05 ~]$ ls /lib64/ld-linux-x86-64.so.2
/lib64/ld-linux-x86-64.so.2
[wadhwaso@nxsdgd05 ~]$ ll /lib64/ld-linux-x86-64.so.2
lrwxrwxrwx 1 root root 9 Apr  7  2012 /lib64/ld-linux-x86-64.so.2 -> ld-2.5.so

Fortunately I also have a winscp session opened for nxsdgd01 but as I am not logged in as root I cannot transfer a file in /lib64. How this could be resolved ?

What OS?

RHEL 5.7 Tikanga

Is this a system that you can boot with an ISO?

This is a virtual machine .. so yep

You should be able to boot up with the RHEL5 boot ISO and go into rescue mode. From there you should be able to reinstall the removed glibc package. Since you'd be running from the ISO, all the commands should be available.

Hey Thank You .. I went to recovery mode and all is good now. :slight_smile: :b: