Linux – error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory

linuxUbuntu

I accidently renamed /lib/x86_64-linux-gnu/libc.so.6 to /lib/x86_64-linux-gnu/libc.so.6-bak

Now I can not perform some commands such as

ls
ll
vim
wget.
.
.
.
.
it is showing the following error whenever I try to execute any command

error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory

I can not rename it back

Best Answer

I suppose you'd have to find a statically linked program (like busybox if you have busybox-static installed or something) with which you could move it back, or else boot from a rescue disk, like an ubuntu live CD or someting, and do it from there.

Related Topic