Btrfs Fails to Mount Drive - btrfs-transaction blocked for more than 120 seconds.

Bug #1454903 reported by jdfalk
32
This bug affects 7 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Call Trace:
kernel: ffff880408609800 ffff8803e9cba200 ffff8803d06f7398 ffff8803bc89fe00
kernel: 0000000000014200 ffff88040ce9f5c0 ffff880407f9d850 ffff8803bc89fdd8
kernel: ffff8803bc89fdc8 ffff880407f9d850 0000000000014200 ffff8803bc89ffd8
kernel: btrfs-transacti D ffff8803bc89fdc8 0 4187 2 0x00000000
kernel: "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
kernel: Not tainted 3.19.0-16-generic #16-Ubuntu
kernel: INFO: task btrfs-transacti:4187 blocked for more than 120 seconds.
kernel: [<ffffffff817c934d>] system_call_fastpath+0x16/0x1b
kernel: [<ffffffff812175db>] SyS_mount+0x8b/0xd0
kernel: [<ffffffff812169a4>] do_mount+0x204/0xb20
kernel: [<ffffffff81213b4b>] vfs_kern_mount+0x6b/0x120
kernel: [<ffffffff8119b805>] ? __alloc_percpu+0x15/0x20
kernel: [<ffffffff811f7428>] mount_fs+0x38/0x1c0
kernel: [<ffffffffc0333b00>] btrfs_mount+0x850/0x920 [btrfs]
kernel: [<ffffffffc035db23>] open_ctree+0x1813/0x2090 [btrfs]
kernel: [<ffffffffc039f9c0>] ? replay_one_extent+0x6b0/0x6b0 [btrfs]
kernel: [<ffffffffc03a2214>] btrfs_recover_log_trees+0x1d4/0x470 [btrfs]
kernel: [<ffffffffc039abbb>] walk_log_tree+0xbb/0x1a0 [btrfs]
kernel: [<ffffffffc039a679>] walk_down_log_tree+0x1d9/0x420 [btrfs]
kernel: [<ffffffffc0382f34>] ? alloc_extent_buffer+0x34/0x350 [btrfs]
kernel: [<ffffffffc039b04e>] insert_orphan_item+0x5e/0x90 [btrfs]

ProblemType: Bug
DistroRelease: Ubuntu 15.04
Package: linux-image-3.19.0-16-generic 3.19.0-16.16
ProcVersionSignature: Ubuntu 3.19.0-16.16-generic 3.19.3
Uname: Linux 3.19.0-16-generic x86_64
ApportVersion: 2.17.2-0ubuntu1
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: jdfalk 3444 F.... pulseaudio
Date: Wed May 13 19:03:10 2015
HibernationDevice: RESUME=/dev/mapper/sda5_crypt
InstallationDate: Installed on 2015-05-10 (4 days ago)
InstallationMedia: Ubuntu-Server 15.04 "Vivid Vervet" - Release amd64 (20150422)
MachineType: Gigabyte Technology Co., Ltd. To be filled by O.E.M.
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-3.19.0-16-generic.efi.signed root=UUID=51a981ad-aeb0-4bd7-91c6-2d493155c812 ro rootflags=subvol=@ crashkernel=384M-:128M
PulseList: Error: command ['pacmd', 'list'] failed with exit code 1: No PulseAudio daemon running, or not running as session daemon.
RelatedPackageVersions:
 linux-restricted-modules-3.19.0-16-generic N/A
 linux-backports-modules-3.19.0-16-generic N/A
 linux-firmware 1.143
RfKill:

SourcePackage: linux
UdevLog: Error: [Errno 2] No such file or directory: '/var/log/udev'
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 01/06/2014
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: F18i
dmi.board.asset.tag: To be filled by O.E.M.
dmi.board.name: Z77X-D3H
dmi.board.vendor: Gigabyte Technology Co., Ltd.
dmi.board.version: x.x
dmi.chassis.asset.tag: To Be Filled By O.E.M.
dmi.chassis.type: 3
dmi.chassis.vendor: Gigabyte Technology Co., Ltd.
dmi.chassis.version: To Be Filled By O.E.M.
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvrF18i:bd01/06/2014:svnGigabyteTechnologyCo.,Ltd.:pnTobefilledbyO.E.M.:pvrTobefilledbyO.E.M.:rvnGigabyteTechnologyCo.,Ltd.:rnZ77X-D3H:rvrx.x:cvnGigabyteTechnologyCo.,Ltd.:ct3:cvrToBeFilledByO.E.M.:
dmi.product.name: To be filled by O.E.M.
dmi.product.version: To be filled by O.E.M.
dmi.sys.vendor: Gigabyte Technology Co., Ltd.
---
ApportVersion: 2.17.2-0ubuntu1
Architecture: amd64
DistroRelease: Ubuntu 15.04
InstallationDate: Installed on 2015-05-10 (5 days ago)
InstallationMedia: Ubuntu-Server 15.04 "Vivid Vervet" - Release amd64 (20150422)
Package: linux (not installed)
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
Tags: vivid
Uname: Linux 4.1.0-040100rc3-generic x86_64
UnreportableReason: The running kernel is not an Ubuntu kernel
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups:

_MarkForUpload: True

Revision history for this message
jdfalk (johnathan-falk) wrote :
Revision history for this message
Brad Figg (brad-figg) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Would it be possible for you to test the latest upstream kernel? Refer to https://wiki.ubuntu.com/KernelMainlineBuilds . Please test the latest v4.1 kernel[0].

If this bug is fixed in the mainline kernel, please add the following tag 'kernel-fixed-upstream'.

If the mainline kernel does not fix this bug, please add the tag: 'kernel-bug-exists-upstream'.

If you are unable to test the mainline kernel, for example it will not boot, please add the tag: 'kernel-unable-to-test-upstream'.
Once testing of the upstream kernel is complete, please mark this bug as "Confirmed".

Thanks in advance.

[0] http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.1-rc3-vivid/

Changed in linux (Ubuntu):
importance: Undecided → Medium
status: Confirmed → Incomplete
Changed in linux (Ubuntu):
importance: Medium → High
Revision history for this message
jdfalk (johnathan-falk) wrote : Re: [Bug 1454903] Re: Btrfs Fails to Mount Drive - btrfs-transaction blocked for more than 120 seconds.
Download full text (4.7 KiB)

It slowly got worse until my whole system wouldn't start. Finally I ran
btrfs check --repair /dev/sdx1 from a usb boot drive and it said: "cache
and super generation don't match, space cache will be invalidated"

After that it mounted right away. However I will proceed with the newer
kernel as we don't know what caused the corruption in the first place and
why it didn't resolve this automagically.
On Thu, May 14, 2015 at 11:01 AM Alberto Salvia Novella <
<email address hidden>> wrote:

> ** Changed in: linux (Ubuntu)
> Importance: Medium => High
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1454903
>
> Title:
> Btrfs Fails to Mount Drive - btrfs-transaction blocked for more than
> 120 seconds.
>
> Status in linux package in Ubuntu:
> Incomplete
>
> Bug description:
> Call Trace:
> kernel: ffff880408609800 ffff8803e9cba200 ffff8803d06f7398
> ffff8803bc89fe00
> kernel: 0000000000014200 ffff88040ce9f5c0 ffff880407f9d850
> ffff8803bc89fdd8
> kernel: ffff8803bc89fdc8 ffff880407f9d850 0000000000014200
> ffff8803bc89ffd8
> kernel: btrfs-transacti D ffff8803bc89fdc8 0 4187 2 0x00000000
> kernel: "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this
> message.
> kernel: Not tainted 3.19.0-16-generic #16-Ubuntu
> kernel: INFO: task btrfs-transacti:4187 blocked for more than 120
> seconds.
> kernel: [<ffffffff817c934d>] system_call_fastpath+0x16/0x1b
> kernel: [<ffffffff812175db>] SyS_mount+0x8b/0xd0
> kernel: [<ffffffff812169a4>] do_mount+0x204/0xb20
> kernel: [<ffffffff81213b4b>] vfs_kern_mount+0x6b/0x120
> kernel: [<ffffffff8119b805>] ? __alloc_percpu+0x15/0x20
> kernel: [<ffffffff811f7428>] mount_fs+0x38/0x1c0
> kernel: [<ffffffffc0333b00>] btrfs_mount+0x850/0x920 [btrfs]
> kernel: [<ffffffffc035db23>] open_ctree+0x1813/0x2090 [btrfs]
> kernel: [<ffffffffc039f9c0>] ? replay_one_extent+0x6b0/0x6b0 [btrfs]
> kernel: [<ffffffffc03a2214>] btrfs_recover_log_trees+0x1d4/0x470 [btrfs]
> kernel: [<ffffffffc039abbb>] walk_log_tree+0xbb/0x1a0 [btrfs]
> kernel: [<ffffffffc039a679>] walk_down_log_tree+0x1d9/0x420 [btrfs]
> kernel: [<ffffffffc0382f34>] ? alloc_extent_buffer+0x34/0x350 [btrfs]
> kernel: [<ffffffffc039b04e>] insert_orphan_item+0x5e/0x90 [btrfs]
>
> ProblemType: Bug
> DistroRelease: Ubuntu 15.04
> Package: linux-image-3.19.0-16-generic 3.19.0-16.16
> ProcVersionSignature: Ubuntu 3.19.0-16.16-generic 3.19.3
> Uname: Linux 3.19.0-16-generic x86_64
> ApportVersion: 2.17.2-0ubuntu1
> Architecture: amd64
> AudioDevicesInUse:
> USER PID ACCESS COMMAND
> /dev/snd/controlC0: jdfalk 3444 F.... pulseaudio
> Date: Wed May 13 19:03:10 2015
> HibernationDevice: RESUME=/dev/mapper/sda5_crypt
> InstallationDate: Installed on 2015-05-10 (4 days ago)
> InstallationMedia: Ubuntu-Server 15.04 "Vivid Vervet" - Release amd64
> (20150422)
> MachineType: Gigabyte Technology Co., Ltd. To be filled by O.E.M.
> ProcEnviron:
> TERM=xterm-256color
> PATH=(custom, no user)
> LANG=en_US.UTF-8
> SHELL=/bin/bash
> ProcFB: 0 inteldrmfb
> ProcKerne...

Read more...

Revision history for this message
jdfalk (johnathan-falk) wrote : JournalErrors.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
jdfalk (johnathan-falk) wrote :

Updated to the requested mainline kernel.
uname --all
Linux 4.1.0-040100rc3-generic #201505102036 SMP Mon May 11 00:37:27 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

I don't want to tag this as fixed by the upstream kernel because we don't know what actually caused the issue in the first place.

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
jdfalk (johnathan-falk)
tags: added: kernel-fixed-upstream
Revision history for this message
Thomas Mayer (thomas303) wrote :

I've just seen this with 16.04, together with latest HES 4.8 kernel:

uname -a
Linux server 4.8.0-51-generic #54~16.04.1-Ubuntu SMP Wed Apr 26 16:00:28 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

That happened during a btrfs-scrub:

May 7 02:11:52 server kernel: [17884.471597] [<ffffffffc04cbc73>] wait_current_trans.isra.21+0xd3/0x120 [btrfs]
May 7 02:11:52 server kernel: [17884.471617] [<ffffffffc04ce43f>] start_transaction+0x27f/0x4c0 [btrfs]
May 7 02:11:52 server kernel: [17884.471635] [<ffffffffc04ce6d7>] btrfs_join_transaction+0x17/0x20 [btrfs]
May 7 02:11:52 server kernel: [17884.471654] [<ffffffffc04d4b45>] btrfs_dirty_inode+0x35/0xd0 [btrfs]
May 7 02:11:52 server kernel: [17884.471672] [<ffffffffc04da57d>] btrfs_setattr+0x9d/0x330 [btrfs]
May 7 02:11:52 server kernel: [17884.471697] INFO: task btrfs:3559 blocked for more than 120 seconds.
May 7 02:11:52 server kernel: [17884.471851] btrfs D ffff937fa2257b68 0 3559 3518 0x00000000
May 7 02:11:52 server kernel: [17884.471887] [<ffffffffc04cb862>] wait_for_commit.isra.16+0x52/0xa0 [btrfs]
May 7 02:11:52 server kernel: [17884.471909] [<ffffffffc04cc205>] btrfs_wait_for_commit+0x145/0x170 [btrfs]
May 7 02:11:52 server kernel: [17884.471935] [<ffffffffc04bb227>] btrfs_inc_block_group_ro+0x67/0x1b0 [btrfs]
May 7 02:11:52 server kernel: [17884.471961] [<ffffffffc0532d77>] scrub_enumerate_chunks+0x217/0x670 [btrfs]
May 7 02:11:52 server kernel: [17884.471994] [<ffffffffc05344ea>] btrfs_scrub_dev+0x1fa/0x540 [btrfs]
May 7 02:11:52 server kernel: [17884.472019] [<ffffffffc050c25c>] btrfs_ioctl+0x1a7c/0x2010 [btrfs]

Revision history for this message
AlexanderYT (arcam) wrote :
Download full text (20.9 KiB)

I can confirm

# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.2 LTS
Release: 16.04
Codename: xenial

# uptime g6-1
 02:13:43 up 17 days, 6:40, 1 user, load average: 404.83, 402.10, 397.12

[Thu Jun 15 19:30:38 2017] device eth1 left promiscuous mode
[Thu Jun 15 19:31:12 2017] device eth1 entered promiscuous mode
[Thu Jun 15 19:34:04 2017] device eth1 left promiscuous mode
[Thu Jun 15 19:35:59 2017] device eth1 entered promiscuous mode
[Thu Jun 15 19:38:44 2017] device eth1 left promiscuous mode
[Thu Jun 15 21:32:25 2017] device eth2 entered promiscuous mode
[Thu Jun 15 22:04:15 2017] device eth2 left promiscuous mode
[Thu Jun 15 22:04:46 2017] device eth2 entered promiscuous mode
[Thu Jun 15 22:04:52 2017] device eth2 left promiscuous mode
[Fri Jun 16 16:23:36 2017] device eth1 entered promiscuous mode
[Fri Jun 16 20:02:57 2017] device eth1 left promiscuous mode
[Fri Jun 16 22:39:54 2017] INFO: task btrfs-transacti:1604 blocked for more than 120 seconds.
[Fri Jun 16 22:39:54 2017] Tainted: G I 4.4.0-67-generic #88-Ubuntu
[Fri Jun 16 22:39:54 2017] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
[Fri Jun 16 22:39:54 2017] btrfs-transacti D ffff8817e65e7b38 0 1604 2 0x00000000
[Fri Jun 16 22:39:54 2017] ffff8817e65e7b38 ffffffffc03dbf65 ffff880be8c3f2c0 ffff8817e51472c0
[Fri Jun 16 22:39:54 2017] ffff8817e65e8000 00000000ffffff00 ffff8817e51472c0 ffff8817e51472c0
[Fri Jun 16 22:39:54 2017] ffff88137fc714c8 ffff8817e65e7b50 ffffffff81838545 ffff88137fc71530
[Fri Jun 16 22:39:54 2017] Call Trace:
[Fri Jun 16 22:39:54 2017] [<ffffffffc03dbf65>] ? btrfs_submit_bio_hook+0xe5/0x1b0 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffff81838545>] schedule+0x35/0x80
[Fri Jun 16 22:39:54 2017] [<ffffffffc04158e6>] btrfs_tree_read_lock+0xe6/0x140 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffff810c4210>] ? wake_atomic_t_function+0x60/0x60
[Fri Jun 16 22:39:54 2017] [<ffffffffc03aeba4>] btrfs_read_lock_root_node+0x34/0x50 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc03b3cab>] btrfs_search_slot+0x74b/0xa00 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffff810f611c>] ? ktime_get+0x3c/0xb0
[Fri Jun 16 22:39:54 2017] [<ffffffffc03cf27e>] btrfs_lookup_inode+0x3e/0xc0 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc042fe99>] __btrfs_update_delayed_inode+0x69/0x210 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc03ae90a>] ? btrfs_alloc_path+0x1a/0x20 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc04305b1>] __btrfs_run_delayed_items+0x571/0x620 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc03aeb06>] ? btrfs_free_path+0x26/0x30 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc0430cf3>] btrfs_run_delayed_items+0x13/0x20 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc03d9ecb>] btrfs_commit_transaction+0x28b/0xa90 [btrfs]
[Fri Jun 16 22:39:54 2017] [<ffffffffc03d52e9>] transaction...

Revision history for this message
AlexanderYT (arcam) wrote :

Linux g6-1 4.4.0-67-generic #88-Ubuntu SMP Wed Mar 8 16:34:45 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

Revision history for this message
Konrad Wojas (kwojas) wrote :

I upgraded from kernel 4.4 to 4.8 on 16.04 LTS in the hope the issue would go away. My hang is in btrfs-cleaner, not sure if this is the same bug or not.

This related thread is interesting but does not seem to resolve it: https://patchwork.kernel.org/patch/8284721/

Linux nuc 4.8.0-54-generic #57~16.04.1-Ubuntu SMP Wed May 24 16:22:28 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

Jun 19 01:51:14 nuc kernel: INFO: task btrfs-cleaner:408 blocked for more than 120 seconds.
Jun 19 01:51:14 nuc kernel: Not tainted 4.8.0-54-generic #57~16.04.1-Ubuntu
Jun 19 01:51:14 nuc kernel: "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
Jun 19 01:51:14 nuc kernel: btrfs-cleaner D ffff9478128d3d00 0 408 2 0x00000000
Jun 19 01:51:14 nuc kernel: ffff9478128d3d00 ffff9478128d3cc8 ffff94781c2a6ac0 ffff9478137a0000
Jun 19 01:51:14 nuc kernel: ffffffffa4cc7492 ffff9478128d4000 ffff947813e841f0 ffff947813e84000
Jun 19 01:51:14 nuc kernel: ffff947813e841f0 0000000000000001 ffff9478128d3d18 ffffffffa5496045
Jun 19 01:51:14 nuc kernel: Call Trace:
Jun 19 01:51:14 nuc kernel: [<ffffffffa4cc7492>] ? autoremove_wake_function+0x12/0x40
Jun 19 01:51:14 nuc kernel: [<ffffffffa5496045>] schedule+0x35/0x80
Jun 19 01:51:14 nuc kernel: [<ffffffffc079fc73>] wait_current_trans.isra.21+0xd3/0x120 [btrfs]
Jun 19 01:51:14 nuc kernel: [<ffffffffa4cc7480>] ? wake_atomic_t_function+0x60/0x60
Jun 19 01:51:14 nuc kernel: [<ffffffffc07a248f>] start_transaction+0x2cf/0x4c0 [btrfs]
Jun 19 01:51:14 nuc kernel: [<ffffffffc07a2698>] btrfs_start_transaction+0x18/0x20 [btrfs]
Jun 19 01:51:14 nuc kernel: [<ffffffffc0788f72>] btrfs_drop_snapshot+0x4b2/0x800 [btrfs]
Jun 19 01:51:14 nuc kernel: [<ffffffffa5495b87>] ? __schedule+0x307/0x790
Jun 19 01:51:14 nuc kernel: [<ffffffffc07a1624>] btrfs_clean_one_deleted_snapshot+0xb4/0x100 [btrfs]
Jun 19 01:51:14 nuc kernel: [<ffffffffc0797dbd>] cleaner_kthread+0x15d/0x1d0 [btrfs]
Jun 19 01:51:14 nuc kernel: [<ffffffffc0797c60>] ? btrfs_destroy_pinned_extent+0xf0/0xf0 [btrfs]
Jun 19 01:51:14 nuc kernel: [<ffffffffa4ca3fb8>] kthread+0xd8/0xf0
Jun 19 01:51:14 nuc kernel: [<ffffffffa549aa9f>] ret_from_fork+0x1f/0x40
Jun 19 01:51:14 nuc kernel: [<ffffffffa4ca3ee0>] ? kthread_create_on_node+0x1e0/0x1e0

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

The best way is to ask maintainer on linux-btrfs.

Alexej (nebu0email.tg)
Changed in linux (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Daniel (hackie) wrote :

@Alexej Do you have more information about the fix? Which version? Upstream?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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