Question

Error while loading shared libraries: Invalid ELF header

  • Posted March 7, 2014

All of a sudden without change any configuration, my server suddenly restart around 4AM SGT. When I access the droplet console I get this error message.

Begin: Running /scripts/init-bottom … done. /sbin/init: error while loading shared libraries: /lib/i386-linux-gnu/librt.so.1: invalid ELF header [ 2.295850] Kernel panic - not syncing: Attempted to kill init!

Subscribe
Share

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

you have to mount /dev/sda somewhere, like <br> <br>mkdir /mnt <br>mount /dev/sda /mnt <br> <br>but it would be a good idea to fsck it first <br>fsck -yf /dev/sda <br>

Tried mount /dev/vda or /dev/sda for my case, but it has an error of can’t read ‘/etc/fstab’: No such file … /etc only contains the following in the rescue kernel. <br>console-setup <br>ld.so.conf <br>ld.so.conf.d <br>udev <br>default <br>modprobe.d <br>ld.so.cache <br>mtab <br> <br> <br>I also dont have the /lib/i386-linux-gnu/ directory but have this one instead /lib/x86_64-linux-gnu … this directory contains librt.so.1 <br>

boot using the rescue kernel <br>mount /dev/vda <br>and look at /lib/i386-linux-gnu/librt.so.1

Its a 64bit kernel 512MB Ram 20GB SSD Disk San Francisco 1 LAMP on Ubuntu 12.04

a complete stab in the dark, but are you booting a 32 bit kernel on a 64 bit userland? that won’t work.