viewing ext3 journal

Andreas Dilger adilger at clusterfs.com
Wed Jun 21 04:35:10 UTC 2006


On Jun 21, 2006  00:46 +0200, Stefan Drexleri wrote:
> 2006/6/21, Andreas Dilger <adilger at clusterfs.com>:
> >Sorry, you need to add your device name to the end of the above command,
> >like "debugfs -c -R 'dump <8> /tmp/journal' /dev/hda1" or whatever.  It
> >will dump the journal inode (#8) to the file /tmp/journal.  But that is
> >just a raw block dump, you would need to hack debugfs to do something
> >more clever to dump the logical structure of the journal (e.g. which
> >transactions are present, blocks modified in each transaction, etc).
> 
> Oh i see raw data ;)
> What a shame! The Possibility to view last filesystem actions in a
> human readable format would have been nice.

Note that this would never be possible (or at least very easy) with ext3
journaling since ext3 uses "block journaling", where the whole filesystem
block that is modified is written to the journal (e.g. one or two directory
leaf blocks and up to four inode table blocks are written to disk for a
rename).

This is different than e.g. XFS which uses "logical journaling" and writes
the actual operation to the journal (e.g. "rename foo/X to bar/Y").

Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.




More information about the Ext3-users mailing list