The ext3 filesystem isn't just designed to be backwards compatible with the ext2 filesystem. It is just the ext2 filesystem with journal files added.

All those attributes are all exactly there in EXT3, because the EXT3 source code started off by me taking a copy of the entire EXT2 directory and copying it into the directory called ext3 and then doing a global search-and-replace for all occurrences of ext2 and replacing that string with ext3.

--Dr. Stephen Tweedie

So an ext3 partition, if unmounted cleanly, can be remounted as ext2 since just like ext2, it sets a "Unmounted Cleanly" bit while unmounting the filesystem.

In the event an ext3 filesystem is not unmounted cleanly (eg, your kid likes to press buttons while you aren't paying attention), an attempt to mount it as ext2 will fail; on mounting a volume as ext3, a bit is set which essentially says, "Do not mount this as ext2." Ext2 understands this (rather, it finds a bit it doesn't understand, so it won't mount the filesystem) and won't mount a volume with that set. On a clean unmount, this bit is set back to "okay for ext2," along with the "cleanly unmounted" bit that ext2 expects.

The journaling portion of ext3 is completely separate from the almost-ext2 portion. The almost-ext2 portion of the code (aka "the ext3 layer") is simply ext2 modified to deal with transactions instead of direct writing to disk; the journaling portion of the code ("the jfs layer") stores those transactions and makes sure they are either completely done or not. This exposes the glaring problem with ext2. Since writing data involves writing to the ext3 layer, which then writes the same data again to the jfs layer, maximum write throughput is decreased by half in sustained write operations. This is a bad thing. As of this date, a version which allows only journaling metadata instead of journaling all writes is planned.

Log in or register to write something here or to contact authors.