[WBEL-users] How to run e2fsck on the root file system
Kirby C. Bohling
kbohling at birddog.com
Wed Mar 30 16:43:30 CST 2005
On Wed, Mar 30, 2005 at 02:34:04PM -0800, Shapiro, Mark wrote:
> It appears that I have one or more bad blocks on my root files system on
> one of my machines running whitebox 3.0.
> When I run e2fsck /dev/hda5, I get a warning that it is very dangerous
> to run e2fsck on a mounted file system.
> However, I don't believe it's possible to unmount /.
> Is there a safe way to bring the system up so that I can run e2fsck on
The generally way this is done is:
Go to single user mode, remount it ro, run fsck:
root# init 1
root# mount -o remount,ro /dev/hda5
root# fsck -C /dev/hda5
You shouldn't ever fsck a read/write filesystem. However, you can
fsck your /, partition if it is read-only. The rc.sysinit scripts
do it when your machine requires an fsck to run.
More information about the Whitebox-users