Automatic recovery of ext4 filesystem

Last days I was facing problems with power outages/glitches that caused some failures on ext4 filesystem, the fs was then remounted as read-only. Unfortunately, this caused crash of few important services (bamboo agents) that need to write to that filesystem.

To fix this, I need to manually reboot the machine (and sometimes also run fsck from the initrd and go through all the errors).

I was wondering if there is any better (automatic) solution. Would adding errors=panic mount option to the fstab cause the system to reboot? The filesystem would then be fsck'ed automatically.

The machine is running Xubuntu 16.04 LTS.

Thank you in advance!

1 Answer

Ive seen this may times; especially on vmware.

As far as I know, errors=panic dos not acually work ( but try for yourself; it may be implmented now.. ) Panic also dont help you much, as system would still be down/dead...

If you change filesystem type to xfs: Xfs is a bit different in handling write-errors - at least it dos not go readonly. There are still errors and I believe your application can get write errors on some files, until you reboot/unmount and run xfs_repair. - this can give a corrupted database...

The real solution is to have stable hardware (stable SAN/VMware... )..

1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like