Linux – Ubuntu Server – Power failure leads to boot failure

busyboxfscklinuxUbuntuubuntu-10.04

I have installed Ubuntu Server 10.04.1 LTS on an ext4 partition. Whenever my system looses power suddenly, It doesn't boot into the normal procedure to fix the problems automatically, but switches to the busy box shell (where it says Kernel Panic : No init found)

So I guess kernel is refusing to mount the filesystem when it is not clean, since when I boot up using a Live CD and fsck it, it boots up correctly.

How can I force kernel to mount the filesystem, even if it is not clean ?, so that automated fsck on system startup fixes the problems… (or it's a grub problem ?)

K-V : 2.6.32-26-generic-pae #48-Ubuntu SMP

Best Answer

Ali, you didn't mention what your journaling is set to. The default mount mode of ext3 and ext4 is 'data=ordered'. This means that while metadata operations may be safe, data may be lost on power failure.

If you're expecting to lose power regularly, I'd suggest adding 'data=journal' to the modes in /etc/fstab. This will slow down your write speed quite a bit, but it should ensure that every disk operation is complete on your hard drive so you don't lose data.

You will also want to regularly forcibly fsck your filesystems so there aren't surprises on the next power failure.