Running The Native ZFS Linux Kernel Module, Plus Benchmarks
In August we delivered the news that Linux was soon to receive a native ZFS Linux kernel module. The Sun (now Oracle) ZFS file-system has long been sought after for Linux, though less now since Btrfs has emerged, but incompatibilities between the CDDL and GPL licenses have barred such support from entering the mainline Linux kernel. There has been ZFS-FUSE to run the ZFS file-system in user-space, but it comes with slow performance. There has also been work by the Lawrence Livermore National Laboratories in porting ZFS to Linux as a native Linux kernel module. This LLNL ZFS work though is incomplete but still progressing due to a US Department of Energy contract. It is though via this work that developers in India at KQ Infotech have made working a Linux kernel module for ZFS. In this article are some new details on KQ Infotech's ZFS kernel module and our results from testing out the ZFS file-system on Linux.
In the August article covering KQ Infotech's ZFS implementation, it was shared that the kernel module would be released in the next month. The module was released in September, but it was only available to a limited number of closed beta testers with a general availability release at a later date. Fortunately, we have had access to this ZFS module for testing and we have been informed by KQ Infotech that the GA release of their ZFS implementation is expected to come the first week of January. KQ Infotech works around the CDDL-GPL licensing issues with ZFS by distributing the kernel module separately with no plans for pushing it into the mainline Linux kernel.
The ZFS kernel module is currently distributed by KQ Infotech for Fedora 12 running the Linux 2.6.31/2.6.32 kernels, Ubuntu 10.04 with the Linux 2.6.32 kernel, and Red Hat Enterprise Linux 6 with the Linux 2.6.32 kernel. We are told that Ubuntu 10.10 will be supported before the GA milestone is met. The ZFS support is not distributed as a simple Debian or RPM package, but rather a set of packages are to be installed. There is a LZFS package that is the POSIX porting layer to the ZFS file-system, three packages for SPL (the utilities, the kernel modules, and the module development headers), and then a set of packages for ZFS itself with the ZFS library and utilities along with the actual kernel module. While in beta, these packages at least for Ubuntu seem to be hastily created (i.e. the dependencies are not setup) and were just converted from RPMs using Alien.
The SPL packages provide the Solaris Porting Layer modules for emulating some Solaris primitives in the Linux kernel, as such, this ZFS implementation is not ported to purely take advantage of the Linux kernel design. The Solaris Porting Layer is also developed by the Lawrence Livermore National Laboratories for their port. When loading the ZFS and SPL kernel modules, also loaded are the following modules: lzfs, zcommon, znvpair, zavl, zlib_deflate, and zunicode.
We have seen the source code to the KQ Infotech work and as of right now it appears to have been branched from the Lawrence Livermore National Laboratories ZFS work at 2009-11-24. This is from the SPL/ZFS 0.4.9 release that was based upon OpenSolaris Nevada Build (ONNV) 121 with Zpool version 18 and file-system version 4. The upstream LLNL work is up to version 0.5.2 with ONNV Build 147, Zpool 28, and ZFS file-system version five. KQ Infotech has pulled in support right now for ZFS Zpool version 26, but before the January release they plan to rebase against Zpool 28.
Using the ZFS/Zpool utilities on Linux is done in the same manner as on Solaris/OpenSolaris and the BSD platforms. For those not up to speed on the ZFS file-system, some of its features include support for storage pools, cloning, snapshots, cache management, block de-duplication, dynamic stripping, copy-on-write transactions, online repair support, and adaptive endianness, among other capabilities.
The native ZFS Linux kernel module performance was compared to the EXT4, Btrfs, and XFS file-systems. We also benchmarked the ZFS-FUSE module on Linux for this comparison. Ubuntu 10.04.1 LTS was used for compatibility with KQ Infotech's current package offerings. As Ubuntu 10.04 had to be used with the Linux 2.6.32 kernel, with the EXT4, Btrfs, ZFS, and ZFS-FUSE testing we benchmarked them under the same Linux 2.6.32 kernel and additionally did so under the latest Linux 2.6.37 kernel code as of 18 November. This was done as the Linux file-system performance has changed and continues to change as the file-system modules mature and other I/O-related work takes place. We also benchmarked OpenIndiana b147 for comparison too in order to get a look at the native ZFS performance under Solaris. OpenIndiana was used since it's based upon the more recent build 147 compared to the last OpenSolaris b134 preview release and Nexenta, among others, also using older versions of the OpenSolaris code-base. All file-systems were tested with their default mount options.
A 60GB OCZ Vertex 2 SSD was used for benchmarking these different file-systems. We had also ran a similar subset of these tests on a standard 7200RPM Serial ATA 2.0 hard drive and proportionally these results didn't end up being different on an HDD over an SSD. The other hardware components in this test system included an Intel Core i5 750 quad-core CPU, an ECS P55H-A motherboard, 4GB of DDR3 system memory, and an ATI Radeon HD 5770 graphics card. The OS hard drive was a Western Digital 500GB Serial ATA 2.0 disk drive while all benchmarks were done with the OCZ SATA 2.0 SSD.
Benchmarking was done with a Phoronix Test Suite 3.0 "Iveland" development snapshot. Test profiles included Apache, SQLite, Compile Bench, IOzone, Dbench, FS-Mark, Threaded I/O Tester, Postmark, and Unpack-Linux.
Latest Articles & Reviews
Latest Linux News
Most Viewed News This Week