The ext filesystem – a four-generation retrospective

Aux Base: Library

As I mentioned before, a good basic understanding of ext2 and its successors has been a key element in the popularity of the filesystem. In addition to the usual tools for making and checking ext FS are some good debugging tools, such as debugfs and dumpe2fs, which allow power users to dig really deep into the filesystem to analyze it, fix bugs, or save data.

For these tools to work, they must have appropriate insider knowledge of the relevant member of the ext FS family. If a detail of the filesystem changes, the developers are forced to adapt the associated tools. As the number of helper programs grows, the maintenance effort can become immense. The trick used by ext2 and its successors is to collect filesystem information in the libext2fs library, against which the tools are linked (Listing 2). Ironically, the Btrfs tool, btrfs-convert, also uses this library, allowing you to convert an existing ext FS in situ to the Btrfs competitor [14].

Listing 2

libext2fs

# ldd /usr/sbin/debugfs /usr/sbin/tune2fs > \
  /usr/sbin/mkfs.ext* /usr/sbin/fsck.ext* > \
  /usr/sbin/btrfs-convert | grep ext2fs | > \
  awk '{print $1}' | uniq libext2fs.so.2

Conclusions

With more than 20 years of history, the ext family of filesystems is one of the most sustainable open source projects in the Linux environment. Its success hinges on several factors. To begin, the 1993 design on one hand allowed for future extension, and on the other hand offered strong backward compatibility. Additionally, the makeup of the development team has remained stable. Early adoption into the Linux kernel didn't hurt, either, helping the filesystem family attract a large developer and user community. Early nomination of ext FS as the standard filesystem for Linux is both a cause and consequence of the success of ext2 and its relatives.

However, it still remains to be seen how ext FS will fare in the coming years (see the box "Looking to the Future"). What will happen after the changing of the guard by Btrfs or XFS? Will the Linux Android smartphone continue to fly the banner of the ext family?

Looking to the Future

In 2008, ext4 was released for production use. Whether there will be an ext5 remains questionable. Even Ts'o believes the future belongs to Btrfs [15]. A major advantage of the ext FS family, backward compatibility, ultimately limits its scalability and manageability. SUSE has already gone down this road: After the difficult departure of ReiserFS, the distribution switched to ext3, but the affiliation did not last long; now, Btrfs has taken over. Red Hat will also do away with ext4 as the default filesystem some time soon. XFS is the designated successor.

The (future) development of ext4 hinges on several components. The core team consists of 10 people, including Ts'o. They hold weekly conference calls and meet once a year. The contributions to the source code itself are derived from the work of far more people. A recent rough analysis counted more than 120 different developers. Communication takes place partly on the Linux kernel mailing list, as well as on ext4-specific lists [16]. Good old Internet relay chat (IRC) is also still used [17].

The xfstest and in-house regression test suites are used to verify functionality, robustness, and stability. Bugs and their solutions are documented by Bugzilla tickets [18]. These and many other facts are described on the wiki page [19]. Developers and users alike will find important and useful information there.

The number of ext4 users is virtually impossible to determine. A large question mark hangs over the figures from Google's data centers, where the filesystem is used on their machines. By the way, the conversion from ext2 to ext4 was one of the reasons why the Internet giant took maintainer Ts'o on board. Android Honeycomb and later also rely on the youngest member of the ext FS family. Thanks to Linux smartphones, the number of ext4 instances is growing rapidly.

Infos

  1. Linux Kernel Archives: http://www.kernel.org/
  2. Linux 0.96c: https://www.kernel.org/pub/linux/kernel/Historic/old-versions/linux-0.96c.tar.gz
  3. "Anatomy of ext4" by M. Tim Jones: http://www.ibm.com/developerworks/linux/library/l-anatomy-ext4/
  4. "Design and Implementation of the Second Extended Filesystem" by Rémy Card, Theodore Ts'o, and Stephen Tweedie: http://e2fsprogs.sourceforge.net/ext2intro.html
  5. Tanenbaum, Andrew. Operating Systems: Design and Implementation. Prentice Hall, 1987
  6. Linux 0.96a: https://www.kernel.org/pub/linux/kernel/Historic/old-versions/linux-0.96a.tar.gz
  7. "The Linux ext2/3/4 Filesystem: Past, Present and Future" by Theodore Ts'o: http://www.linuxfoundation.jp/jp_uploads/seminar20060911/Ted_Tso.pdf
  8. Card, Rémy, Theodore Ts'o, and Stephen Tweedie. "Design and implementation of the second extended filesystem" in Proceedings of the First Dutch International Symposium on Linux, 1994
  9. "Journaling the Linux ext2fs Filesystem" by Stephen Tweedie: http://original.jamesthornton.com/hotlist/linux-filesystems/ext3-journal-design.pdf
  10. "fsync on large files" by Alan Curry: http://lkml.org/lkml/1999/2/12/160
  11. "Re: fsync on large files" by Stephen C. Tweedie: http://lkml.org/lkml/1999/2/17/36
  12. Kernel changelog 2.4.15: http://www.kernel.org/pub/linux/kernel/v2.4/ChangeLog-2.4.15
  13. "Proposal and plan for ext2/3 future development work" by Theodore Ts'o: http://lkml.org/lkml/2006/6/28/454
  14. "Conversion from ext3": http://btrfs.wiki.kernel.org/index.php/Conversion_from_Ext3
  15. "Panelists ponder the kernel at Linux Collaboration Summit" by Ryan Paul: http://arstechnica.com/information-technology/2009/04/linux-collaboration-summit-the-kernel-panel/
  16. Ext4 mailing lists: http://ext4.wiki.kernel.org/index.php/Mailinglists
  17. Ext4 IRC: http://ext4.wiki.kernel.org/index.php/IRC
  18. Ext4 bugs: http://bugzilla.kernel.org/buglist.cgi?product=File+System&component=ext4
  19. Ext4 wiki: http://ext4.wiki.kernel.org

The Author

Dr. Udo Seidel is a Math and Physics teacher and a Linux fan since 1996. Since finishing his doctorate, he has worked as a Linux/Unix trainer, system administrator, and senior solution engineer. Today, he is head of a Linux Strategy team at Amadeus Data Processing GmbH in Erding, Germany.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Choose a Filesystem

    Every Linux computer needs a filesystem, and users often choose a filesystem by habit or by default. But, if you're seeking stability, versatility, or a small performance advantage, it pays to take a closer look.

  • File systems

    Many users just opt for the defaults and don’t think about the file system when they install Linux. But if better performance is your goal, it pays to do some shopping.

  • Ext4

    The newest child in the Ext filesystem family provides better performance and supports bigger filesystems. Are you ready for Ext4?

  • Kernel: Ext 4 Filesystem Moves Beyond Developer Status

    Theodore Ts'o has renamed the Ext4 filesystem, for which he has been responsible for source and documentation, from extdev to ext4. Linus Torvalds has also incorporated the change into his personal source tree for the upcoming Kernel 2.6.28.

  • Configuring Filesystems

    Although most Linux distributions today have simple-to-use graphical interfaces for setting up and managing filesystems, knowing how to perform those tasks from the command line is a valuable skill. We’ll show you how to configure and manage filesystems with mkfs, df, du, and fsck.

comments powered by Disqus

Direct Download

Read full article as PDF:

Price $2.95

News