Site icon DebugPoint NEWS

OpenZFS 2.2.1 Released to Fix a File Corruption Bug. Update Now.

OpenZFS, the significant project working on implementing the ZFS file system for both Linux and FreeBSD, brings a critical update related to a file corruption bug with OpenZFS 2.2.1 release this week. This release also brings compatibility with the latest mainline Linux Kernel 6.6 and other changes as well.

The said bug, initially pointed to a glitch confined to the 2.2.x branch, attributed to a hiccup in the block cloning mechanism introduced in OpenZFS 2.2.0. This mechanism facilitates creating file copies without duplicating data, referencing existing data blocks of the source file. OpenZFS 2.2.1 took a proactive stance by disabling the block cloning mechanism by default and adding the zfs_bclone_enabled setting to reinstate support for this mode.

The developers were puzzled to find out that the bug was affecting the configurations of the 2.1.x branch. Their assumption that the issue occurs only on systems with older releases of the coreutils package could not be confirmed either. To their surprise, the error was replicated in FreeBSD and in Linux distributions with the latest release of coreutils 9.4.

File corruption under this bug is not an everyday occurrence. Instances include the obscure scenario of running “emerge -1 dev-lang/go” in Gentoo, resulting in corrupted files during the installation of the Go toolkit. Specifically, files in the /usr/lib/go/pkg/tool/linux_amd64/ directory faced the brunt of this issue. The bug seems to have manifested post the default parameter tweak, “zfs_dmu_offset_next_sync=1” in openzfs version 2.1.4. The root cause of this error remains elusive.

If you want a workaround, consider setting the parameter "/sys/module/zfs/parameters/zfs_dmu_offset_next_sync" to 0. This workaround aims to block the error and ensure that your files remain unscathed.

As of publishing this, zfs 2.2.1 has already landed in Ubuntu 23.10 and upcoming version repositories, including Fedora and Arch Linux.

Via OpenZFS release notes

Recent articles from

Exit mobile version