Home > Ask the Enterprise Linux Experts > Linux migration and administration Questions & Answers > How does a journaling filesystem work?
Ask The Enterprise Linux Expert: Questions & Answers
EMAIL THIS

How does a journaling filesystem work?

Kenneth Milberg EXPERT RESPONSE FROM: Kenneth Milberg

Pose a Question
Other Enterprise Linux Categories
Meet all Enterprise Linux Experts
Become an Expert for this site


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


>
QUESTION POSED ON: 14 October 2004
How does a journaling filesystem work in the major Linux distros, and what is the difference between Ext2 and Ext3?

>
Ext2 is the standard file system for Linux (I-node based, maintaining metadata, pointing to actual data blocks), while ext3 is a journaled file system. A journaled file system is much easier to recover then a standard one, because you do not need to use fsck anymore for recovery. Data integrity occurs because updates to files are written to logs before the actual data blocks are updated. A thread writes data to the f/s and each transaction is flagged. After a crash, updates are copied back from the journal to the filesystem and any incomplete transactions are gone. In case of a failure, a journaled file system will ensure that all inconsistencies are restored back to its prior state.

Prior to journal filesystems, one would need to run fsck to resolve file and metadata inconsistencies. Sure, fsck works, but it is too darn slow and in today's world with partitions getting larger and larger, it just doesn't scale anymore. Filesystem logging, in many ways, is very similar to database logging. We all know that databases keep logs so that if information has not yet been written to data blocks from cache, there is a way to recover. You can think of journaling file systems as providing the same function, but here at the filesystem level.


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   



RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary



Search and Browse the Expert Answer Center
Search and browse more than 25,000 question and answer pairs from more than 250 TechTarget industry experts.
Browse our Expert Advice



Linux Migration Advice: Unix-to-Linux, Windows-to-Linux
HomeNewsTopicsITKnowledge ExchangeTipsBlogsAsk the ExpertsMultimediaWhite PapersIT Downloads
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 2003 - 2009, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts