mohit.saha
02-25-2008, 02:30 AM
If journaling can be used to recover file system after crashes, why does ext3 still ask for file system check during system boot up?:confused:
|
Click to See Complete Forum and Search --> : Ext3 doubts.... mohit.saha 02-25-2008, 02:30 AM If journaling can be used to recover file system after crashes, why does ext3 still ask for file system check during system boot up?:confused: phlipant 02-25-2008, 03:17 AM Every boot? I think you need to use tune2fs mohit.saha 02-25-2008, 04:40 AM no not every boot, but whenever the system is not shutdown cleanly... ext3's main feature is journaling so that it can easily recover itself... but still why it asks for file system check at boot time for unclean shutdown... phlipant 02-25-2008, 11:59 AM no not every boot, but whenever the system is not shutdown cleanly... ext3's main feature is journaling so that it can easily recover itself... but still why it asks for file system check at boot time for unclean shutdown... Journaled file systems are not immune from corruption, merely much more robust. fsck should be run occasionally (although some disagree). Your problem seems to be that, your system frequently goes down too hard, resulting in your disk being marked unclean. I suggest you might add a UPS, or look for a severe hardware or software problem. tune2fs can turn off routine system checks, but if you mount a disk marked unclean, fsck should be run. You need to prevent your disks from being unmounted in an unclean state. Edit: You will find this explanation in the fsck.ext3 man page. e2fsck is used to check a Linux second extended file system (ext2fs). E2fsck also supports ext2 filesystems containing a journal, which are also sometimes known as ext3 filesystems, by first applying the journal to the filesystem before continuing with normal e2fsck processing. After the journal has been applied, a filesystem will normally be marked as clean. Hence, for ext3 filesystems, e2fsck will normally run the journal and exit, unless its superblock indicates that further checking is required. bwkaz 02-25-2008, 07:57 PM but still why it asks for file system check at boot time for unclean shutdown... And when you tell it that it should indeed go ahead and do this check, does the check take 5 seconds, or an hour? If it takes 5 seconds, then it's using the journal. As philipant just posted (the stuff in bold), the fsck that's used for ext3 replays the journal to make the filesystem consistent, then assumes that everything's OK and continues. If it takes an hour, then one of the time-between-fscks or mounts-between-fscks counters has expired, and it's doing a full fsck because a journal does not protect against corrupted data. If the data gets changed between the disk controller and the disk, or while it's on the disk, or while it's in memory, or while it's on the bus on the way to the disk controller, then your filesystem will still be broken, and you won't have any idea -- until you run the full hour-long fsck that fixes the problem. (Well, usually.) (Of course the "hour" time depends on the filesystem size. Larger disks take longer, and smaller disks take less time. But it's way more than five seconds.) mohit.saha 02-26-2008, 12:17 AM Hey thanks a lot to phlipant and bwkaz.... those were very good answer... i do have an ups it was just that a question was there in my mind after reading about ext3 journaling file system. Hope to get some great help from you people and others in near future... If you could please visit another of my thread, the link is given below... http://justlinux.com/forum/showthread.php?p=879004#post879004 PS: i haven't found any comprehensive documentation of e2compr till now. So please if you people could help.:) justlinux.com
Copyright Internet.com Inc. All Rights Reserved. |