After seven release candidates and two months of development, Linux creator Linus Torvalds released the Linux 3.5 kernel on Saturday afternoon. The new Linux kernel is noteworthy for a number of incremental improvements it includes, which could serve to make Linux more stable and resilient than ever before.
For many Linux distributions the Ext4 filesystem is the default choice, following the decade-long legacy of Ext2 and Ext3. While Ext4 provides a higher degree of performance and reliability in comparison with its predecessors, it has trailed other fileystems. Both Oracle’s ZFS, used in Solaris, as well as Btrfs, which is part of the Linux kernel, have gone a step further than the Ext filesystem family with integrity checks. In the Linux 3.5 kernel a feature called metadata checksum has been added to help narrow the filesystem integrity gap.
“As much as we wish our storage hardware was 100 percent reliable, it is still quite possible for data to be corrupted on disk, corrupted during transfer over a wire, or written to the wrong places,” the kernel.org wiki on metadata checksums explains. “To protect against this sort of non-hostile corruption, it is desirable to store checksums of metadata objects on the filesystem to prevent broken metadata from shredding the filesystem.”
The wiki noted that Btrfs has stronger guarantees against corruption with uniform checksums on all metadata blocks as well as redundant copies of all metadata. Btrfs is now a supported technology in SUSE Linux Enterprise Server as well as Oracle Linux and is set for full support in Red Hat Enterprise Linux 7 in 2013. The intention with the new Ext4 integrity improvements is to help those users that need to stay with Ext4 and are unable or unwilling to migrate from Ext4.
While Ext4 is getting new integrity features, Btrfs is also pushing forward with improved performance and additional integrity checks.
“The goal is to detect when drives start to get an increased error rate, when drives should be replaced soon,” Linux developer Stefan Behrens wrote in his kernel commit message. “Therefore statistic counters are added that count IO errors (read, write and flush). Additionally, the software detected errors like checksum errors and corrupted blocks are counted.”
The Linux 3.5 kernel also benefits from new capabilities that enable a system to enter a ‘suspend’ state. The use of the low power suspect is particularly important for mobile devices, like those running the Linux-based Android system.
Memory improvements also land in Linux 3.5 by way of the Frontswap feature, contributed by Oracle.
“Frontswap is the alter ego of cleancache, the ‘yang’ to cleancache’s ‘yin’… and more precisely frontswap is the provider of anonymous pages to transcendent memory to nicely complement cleancache’s providing of clean pagecache pages to transcendent memory,” Oracle developer Dan Magenheimer, wrote in his kernel commit message. “For optimal use of transcendent memory, both are necessary… because a kernel under memory pressure first reclaims clean pagecache pages and, when under more memory pressure, starts swapping anonymous pages.”