Search This Blog

2013-11-26

Linux Filesystem Recovery

Dropped down to initramfs prompt usually means that you have been unable to mount the root filesystem.

This will normally require a fsck, but sometimes even the fsck will not run due to bad superblocks.

Find alternative superblocks:
dumpe2fs /dev/xxx | grep -i superblock
OR (if you do not have dumpe2fs)
mke2fs -n /dev/xxx

Run filesystem check with alternative superblock
e2fsck -f -b $alternativeSuperblock /dev/sda3

More Linux Filesystem Recovery Resources:
http://www.cyberciti.biz/tips/understanding-unixlinux-filesystem-superblock.html
http://www.cyberciti.biz/tips/surviving-a-linux-filesystem-failures.html
http://bernaerts.dyndns.org/linux/74-ubuntu/232-ubuntu-boot-failure-initramfs
http://askubuntu.com/questions/137655/boot-up-fails-drops-to-initramfs-prompt-12-04
http://linuxexpresso.wordpress.com/2010/03/31/repair-a-broken-ext4-superblock-in-ubuntu/
http://www.cyberciti.biz/tips/mounting-with-an-alternative-superblock.html

Note: With BSD platforms I have found that it will usually just dump you into single user mode in which case you can just run an fsck -y /dev/xxx and you will not need a live/rescue CD

1 comment:

  1. This comment has been removed by a blog administrator.

    ReplyDelete