"btrfs subvolume list" sporadically segfaults with linux-image-5.4.0-52-generic

Bug #1901755 reported by Martin Carpella
36
This bug affects 11 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

On a BTRFS volume with a lot of subvolumes, I get sporadic segfaults on "btrfs subvolume list", about 1/3 of the time. This is on Ubuntu 20.04.

linux-image-5.4.0-48-generic does not experience those segfaults.

On #btrfs on freenode, it was pointed out that 5.4.0-52.57 seems to have a regression but not the fix for it committed. To quote from the IRC message:

> 5.4.0-52.57 has a regression (a48b73eca4ce btrfs: fix potential deadlock in the search ioctl) and not the fix (1c78544eaa46 btrfs: fix wrong address when faulting in pages in the search ioctl)

Tags: focal
Paul White (paulw2u)
affects: ubuntu → linux (Ubuntu)
tags: added: focal
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1901755

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Revision history for this message
Martin Carpella (martinc) wrote :

I'm currently not running the affected kernel version, since the system is being used as a backup-target (hence the high subvolume count), therefore I cannot provide the requested log.

My initial bug report contains the information that should help determining which commit is missing from the kernel.

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Hello Martin,

thanks for your bug report, the fix mentioned in the quote (1c78544eaa46 btrfs: fix wrong address when faulting in pages in the search ioctl) has already been applied to the Focal master-next branch via stable update process in bug 1896824.

It's expected to have this fix available in -updates after the upcoming SRU cycle.

I will keep this report open to make it easier for others to find it.

Changed in linux (Ubuntu):
status: Confirmed → Fix Committed
Revision history for this message
David A. Sjøen (dabide) wrote :

Hello Po-Hsu Lin,

Will this also be fixed in the current 18.04 kernel, or has it already been? We have the same issue there.

David

Revision history for this message
Bastian Baum (protree) wrote :

I'm still getting this error on Ubuntu 18.04 with kernel 5.4.0-54.60. Installed Mainline Kernel 5.9.10 as a workaround...

Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Hi all,
with commit 1c78544eaa46 in Focal[1] tree released, this fix should be available since Ubuntu-5.4.0-55.61

~/ubuntu-focal [master-next]$ git tag --contains 0d3fe387a7a4da52e94d960eb0987b991b29dbdf
Ubuntu-5.4.0-55.61
Ubuntu-5.4.0-56.62
Ubuntu-5.4.0-57.63
Ubuntu-5.4.0-58.64
Ubuntu-5.4.0-59.65
Ubuntu-5.4.0-60.67
Ubuntu-5.4.0-61.69
Ubuntu-5.4.0-62.70
Ubuntu-5.4.0-64.72
Ubuntu-5.4.0-65.73
Ubuntu-5.4.0-66.74
Ubuntu-5.4.0-67.75
Ubuntu-5.4.0-68.76

For Bionic, you can get this fix with the 5.4 HWE kernel on bionic.

Therefore I am closing this bug here, please feel free to open a new issue with command "ubuntu-bug linux".
Thanks

[1] https://kernel.ubuntu.com/git/ubuntu/ubuntu-focal.git/commit/?id=0d3fe387a7a4da52e94d960eb0987b991b29dbdf

Changed in linux (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.