Errors in dmesg after removing a btrfs flash disk

Bug #576057 reported by Radomír Černoch
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu
Invalid
Undecided
Rolf Leggewie

Bug Description

When I remove an USB disk formatted with Btrfs, there is an error in 'dmesg', which mentions a kernel bug.

Description: Ubuntu 10.04 LTS
Release: 10.04

[80337.138374] usb 2-2: USB disconnect, address 2
[80338.337003] __ratelimit: 9 callbacks suppressed
[80338.337009] lost page write due to I/O error on sdc1
[80338.337057] end_request: I/O error, dev sdc, sector 131072
[80338.337062] lost page write due to I/O error on sdc1
[80338.337069] btrfs: 1 errors while writing supers
[80338.337107] ------------[ cut here ]------------
[80338.337111] kernel BUG at /build/buildd/linux-2.6.32/fs/btrfs/disk-io.c:2286!
[80338.337115] invalid opcode: 0000 [#1] SMP
[80338.337119] last sysfs file: /sys/devices/pci0000:00/0000:00:1d.7/class
[80338.337123] CPU 3
[80338.337126] Modules linked in: usb_storage binfmt_misc snd_hda_codec_intelhdmi snd_hda_codec_realtek ppdev fbcon tileblit font bitblit softcursor vga16fb vgastate snd_hda_intel snd_hda_codec snd_hwdep snd_pcm_oss snd_mixer_oss snd_pcm snd_seq_dummy snd_seq_oss arc4 snd_seq_midi snd_rawmidi snd_seq_midi_event snd_seq rt61pci crc_itu_t rt2x00pci rt2x00lib snd_timer led_class snd_seq_device i915 mac80211 drm_kms_helper snd drm i2c_algo_bit video output cfg80211 eeprom_93cx6 serio_raw xhci intel_agp soundcore snd_page_alloc lp parport usbhid hid btrfs zlib_deflate ohci1394 ieee1394 ahci crc32c r8169 mii libcrc32c
[80338.337188] Pid: 2844, comm: umount Not tainted 2.6.32-21-generic #32-Ubuntu H55M-USB3
[80338.337192] RIP: 0010:[<ffffffffa0089e64>] [<ffffffffa0089e64>] write_all_supers+0x274/0x280 [btrfs]
[80338.337215] RSP: 0018:ffff88020495dd78 EFLAGS: 00010292
[80338.337219] RAX: 000000000000003a RBX: ffff8801f012b068 RCX: 000000000000001e
[80338.337223] RDX: 0000000000000000 RSI: 0000000000000082 RDI: 0000000000000246
[80338.337226] RBP: ffff88020495ddd8 R08: 00000000ffffffff R09: 0000000000000000
[80338.337230] R10: 0000000000000005 R11: 0000000000000000 R12: 0000000000000001
[80338.337233] R13: ffff8801f012b068 R14: 0000000000000000 R15: ffff880209517800
[80338.337238] FS: 00007f3d85c50740(0000) GS:ffff8800282c0000(0000) knlGS:0000000000000000
[80338.337242] CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b
[80338.337245] CR2: 00007f42584f06a8 CR3: 00000001dad9f000 CR4: 00000000000006e0
[80338.337249] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[80338.337253] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
[80338.337257] Process umount (pid: 2844, threadinfo ffff88020495c000, task ffff8801924e44d0)
[80338.337260] Stack:
[80338.337262] ffff8801f01c0dce ffff8801f012b000 ffff880209517800 0000000000000000
[80338.337268] <0> ffff8801f01c0cb3 0000000100000001 ffff88020495ddd8 ffff880209517800
[80338.337274] <0> ffff880212fbf3f0 ffff88020495de28 ffff880212fbf460 0000000000000001
[80338.337280] Call Trace:
[80338.337299] [<ffffffffa0089e83>] write_ctree_super+0x13/0x20 [btrfs]
[80338.337318] [<ffffffffa008f259>] btrfs_commit_transaction+0x4c9/0x6f0 [btrfs]
[80338.337328] [<ffffffff81085320>] ? autoremove_wake_function+0x0/0x40
[80338.337346] [<ffffffffa008e699>] ? start_transaction+0x129/0x180 [btrfs]
[80338.337359] [<ffffffffa006eb23>] btrfs_sync_fs+0x43/0x80 [btrfs]
[80338.337366] [<ffffffff81197d9e>] sync_quota_sb+0x5e/0x130
[80338.337373] [<ffffffff81169f0a>] __sync_filesystem+0x7a/0x90
[80338.337378] [<ffffffff81169ff9>] sync_filesystems+0xd9/0x130
[80338.337384] [<ffffffff8115ece1>] sys_umount+0xb1/0xd0
[80338.337392] [<ffffffff810131b2>] system_call_fastpath+0x16/0x1b
[80338.337395] Code: 5e 41 5f c9 c3 44 89 f6 48 c7 c7 50 f1 0c a0 31 c0 e8 50 42 4b e1 0f 0b eb fe 44 89 e6 48 c7 c7 50 f1 0c a0 31 c0 e8 3b 42 4b e1 <0f> 0b eb fe 0f 1f 84 00 00 00 00 00 55 48 89 e5 0f 1f 44 00 00
[80338.337441] RIP [<ffffffffa0089e64>] write_all_supers+0x274/0x280 [btrfs]
[80338.337458] RSP <ffff88020495dd78>
[80338.337463] ---[ end trace 5dad66d8edaeb8a5 ]---

Tags: btrfs kernel
Revision history for this message
Rocko (rockorequin) wrote :

Does it lock the PC up? It tends to lock mine if I remove the drive before unmounting it. 2.6.34 performs a bit better, but removing the drive still makes the kernel hang eventually, requiring a reboot. It might also be related to https://bugs.launchpad.net/bugs/518638 - if you remount the btrfs drive on a different device (eg /dev/sdc), the kernel can't see it because it thinks it's still mounted on the old device (eg /dev/sdb).

I reported this kernel bug at https://bugzilla.kernel.org/show_bug.cgi?id=15325 a few months ago, but there's been no response so far.

Revision history for this message
Radomír Černoch (radomir-cernoch) wrote :

No, it does not. I was able to continue working flawlessly. Apart from the flash drive, I am using Btrfs on the root fs and no error has occured. Therefore I assume that the kernel was able to recover fully from this error.

Revision history for this message
Rolf Leggewie (r0lf) wrote :

Ubuntu has not shipped a btrfs package for a long time, moving to generic Ubuntu for triage.

This bug is pretty old. Did anyone affected by this experience it with trusty or later?

affects: btrfs (Ubuntu) → ubuntu
Changed in ubuntu:
assignee: nobody → Rolf Leggewie (r0lf)
Revision history for this message
Rolf Leggewie (r0lf) wrote :

We'd like to figure out what's causing this bug for you, but we haven't heard back from you in a while. Could you please provide the requested information? Thanks!

Revision history for this message
Rolf Leggewie (r0lf) wrote :

closing as obsolete

Changed in ubuntu:
status: New → Invalid
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.