Important! important! | EXT4 Disk Corruption

If you use 6.1.64 LTS or 6.1.65 LTS kernel with ext4 file system, then things on your disk get silently corrupted. Apparently, it applies only to newly created data after the installation of the mentioned kernels.

3 Likes

Thanks @Hary for providing the information.

If I may, hereĀ“s a bit more about the topic:

Critical ext4-bend (especially affected: Linux 6.1.64)

Currently, caution should be exercised when updating the Linux kernel. Certain kernel releases have a problem with ext4, which theoretically in the worst case can lead to data compensation.
There is a constellation in which only the first one is included in a release without the second commit and thus the code does not work as desired.
In concrete terms, it is about ext4: properly sync file size update after O_SYNC direct IO Ā· torvalds/linux@9156289 Ā· GitHub and iomap: update ki_pos a little later in iomap_dio_complete Ā· torvalds/linux@936e114 Ā· GitHub .

It is about the fact that the first commit may only be present in the code if the second commit is already included. Actually, this is logical, because it fits with the sequence. Now, however, the backports and distributions are still coming into play.
For the context: since not everyone can always update to the latest Linux version, there is a team, which includes old versions and ā€œbackports small, non-critical fixes on the older versionsā€, i.e. backported.
However, it can now happen that something completely new is being backported without an older requirement being backported.
The errors that then occur are classically called a regression. The individual code changes are not the problem in themselves, but rather the constellation in which they were composed.
Linux 6.1.64 and 6.1.65 are affected, 6.1.66 contains the fix. Debian 12, which relies on the kernels, is particularly at rest, because a problematic kernel version is distributed. For this reason, the release of Debian 12.3 was also delayed.

Further information:

(from: planet.ubuntuusers.de and Kritischer ext4-Bug (besonders betroffen: Linux 6.1.64) - Viktors Blog)

(translation via ā€œTranslateLocally for Firefoxā€ add-on)

Cheers from Rosika :slightly_smiling_face:

4 Likes

Anything that compromises the integrity of a filesystem
is a very serious issue.
Rolling release distros will have gone past kernel 6.1 ā€¦
my Gentoo is 6.6, but many fixed release distros will still
have 6.1 or earlier.
Try not to progress to 6.1. Hold an earlier kernel until you
can jump to 6.2 or later.

2 Likes

None of my stuff (and I have a fair amount) is kernel 6.1 - my two Pop!_OS machines are kernel 6.5.6, my headless Ubuntu on a Pi4 is sill on 5.15, everything else even earlier (Raspbian Stretch on a Pi3 kernel 4 and an OrangePi running Armbian 16 kernel 3.x)ā€¦

Tell a lie - one of my Pi Zero 2W (bullseye) is running 6.1.21 and filesystem is ext4ā€¦ and other 2W (bookworm) on kernel 6.1.41 - also on ext4ā€¦

I guess I should be careful updating themā€¦ Might wait a bitā€¦ I donā€™t update very often - itā€™s not like my systems are on the intertubes and can be molested by nefarious actorsā€¦


My 2 Pi Zero 2W, on bullseye, one bookworm, both seem to not have kernel updates when running ā€œsudo apt list --upgradable |grep -i linuxā€ donā€™t show anything that looks like a kernel update :

Bullseye :

 āœ˜ x@albiorix ī‚° ~ ī‚° sudo apt list --upgradable |grep -i linux

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

binutils-arm-linux-gnueabihf/testing 2.41-6+rpi1 armhf [upgradable from: 2.40-2+rpi2]
console-setup-linux/testing 1.223 all [upgradable from: 1.221]
libselinux1/testing 3.5-1 armhf [upgradable from: 3.4-1+b2]
linux-libc-dev/stable 1:6.1.63-1+rpt1 armhf [upgradable from: 1:1.20230405-1]
python3-selinux/testing 3.5-1 armhf [upgradable from: 3.4-1+b2]
util-linux-extra/testing 2.39.3-2 armhf [upgradable from: 2.38.1-5]
util-linux/testing 2.39.3-2 armhf [upgradable from: 2.38.1-5]

Anyone else here HATE that message ā€œapt does not have a stable CLI interfaceā€? It doesnā€™t exactly inspire one with confidence does it?

EDIT : hmm - ā€œlinux-libc-dev/stable 1:6.1.63-1+rpt1`ā€ looks like it might be ā€œkernel relatedā€ā€¦

Bullseye :

 x@anthe ī‚° ~ ī‚° sudo apt list --upgradable |grep -i linux

WARNING: apt does not have a stable CLI interface. Use with caution in scripts

So nothing with the string ā€œlinuxā€ will get updatedā€¦ Iā€™ll still wait and see if/when thereā€™s a kernel updateā€¦ I guess itā€™s Debian Stable, so probably wonā€™t beā€¦

4 Likes