Bug 1373270

Summary: [abrt] WARNING: CPU: 11 PID: 20341 at fs/btrfs/extent-tree.c:4233 btrfs_free_reserved_data_space_noquota+0xed/0x100 [btrfs]
Product: [Fedora] Fedora Reporter: O. ROUSSEL <olivier.roussel>
Component: kernelAssignee: Kernel Maintainer List <kernel-maint>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 23CC: gansalmon, ichavero, itamar, jonathan, kernel-maint, madhu.chinakonda, mchehab, olivier.roussel
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
URL: https://retrace.fedoraproject.org/faf/reports/bthash/2a80840469543d6a392ebe69889456ce2d6c9ba8
Whiteboard: abrt_hash:2047b67224ab60cb36f08cec6b387e235229d463;VARIANT_ID=workstation;
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-10-19 18:22:28 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
File: dmesg none

Description O. ROUSSEL 2016-09-05 16:05:13 UTC
Description of problem:
I've had several kernel oops, all related to BTRFS functions. The previous kernels were tainted so I was not able to report them.

This kind of bug seems to occur when there is a significant amount of I/O operations on the BTRFS filesystem (several GB copied). I am not able to reproduce it in a consistent way.

In two previous cases, the filesystem was reported as full. It was impossible to create new files. df -h still showed several GB available. btrfs check did not report any error. Unmounting and mounting again the filesystem was sufficient to fix the problem temporarily.

The BRTFS filesystem in on a single, LUKS encrypted, partition of a 6TB disk. No I/O error is reported in the system journal.

I am a computer scientist,  and would be able to compile and run a different kernel if it can help.

Additional info:
reporter:       libreport-2.6.4
WARNING: CPU: 11 PID: 20341 at fs/btrfs/extent-tree.c:4233 btrfs_free_reserved_data_space_noquota+0xed/0x100 [btrfs]
Modules linked in: fuse xt_CHECKSUM ipt_MASQUERADE nf_nat_masquerade_ipv4 tun nf_conntrack_netbios_ns nf_conntrack_broadcast ip6t_rpfilter ip6t_REJECT nf_reject_ipv6 xt_conntrack ip_set nfnetlink ebtable_broute bridge stp llc ebtable_nat ip6table_mangle ip6table_nat nf_conntrack_ipv6 nf_defrag_ipv6 nf_nat_ipv6 ip6table_raw ip6table_security iptable_mangle iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack iptable_raw iptable_security ebtable_filter ebtables ip6table_filter ip6_tables btrfs xor raid6_pq dm_crypt snd_hda_codec_hdmi intel_rapl x86_pkg_temp_thermal coretemp kvm_intel kvm snd_hda_codec_realtek irqbypass snd_hda_codec_generic crct10dif_pclmul crc32_pclmul crc32c_intel ghash_clmulni_intel snd_hda_intel snd_hda_codec snd_hda_core snd_hwdep snd_seq snd_seq_device
 snd_pcm mei_wdt iTCO_wdt iTCO_vendor_support dcdbas snd_timer dell_smm_hwmon sb_edac snd mei_me edac_core mei i2c_i801 soundcore lpc_ich shpchp tpm_tis tpm nfsd auth_rpcgss nfs_acl lockd grace sunrpc uas usb_storage nouveau video mxm_wmi i2c_algo_bit drm_kms_helper ttm drm serio_raw e1000e ptp ata_generic pps_core pata_acpi wmi fjes
CPU: 11 PID: 20341 Comm: kworker/u66:3 Not tainted 4.6.7-200.fc23.x86_64 #1
Hardware name: Dell Inc. Precision Tower 7810/0GWHMW, BIOS A07 04/14/2015
Workqueue: writeback wb_workfn (flush-btrfs-1)
 0000000000000286 0000000083fbca35 ffff880dcf0c74f8 ffffffff813d954e
 0000000000000000 0000000000000000 ffff880dcf0c7538 ffffffff810a73db
 0000108900000046 ffff881098d6b800 0000000000002000 ffff881098cce200
Call Trace:
 [<ffffffff813d954e>] dump_stack+0x63/0x85
 [<ffffffff810a73db>] __warn+0xcb/0xf0
 [<ffffffff810a750d>] warn_slowpath_null+0x1d/0x20
 [<ffffffffc071ec5d>] btrfs_free_reserved_data_space_noquota+0xed/0x100 [btrfs]
 [<ffffffffc073b6c0>] btrfs_clear_bit_hook+0x270/0x340 [btrfs]
 [<ffffffffc075898a>] clear_state_bit+0x5a/0x1d0 [btrfs]
 [<ffffffffc0758c57>] __clear_extent_bit+0x157/0x3e0 [btrfs]
 [<ffffffffc0759b59>] extent_clear_unlock_delalloc+0x79/0x330 [btrfs]
 [<ffffffff812218fd>] ? kmem_cache_alloc+0x1cd/0x1e0
 [<ffffffffc0754c33>] ? __btrfs_add_ordered_extent+0x43/0x310 [btrfs]
 [<ffffffffc0754e33>] ? __btrfs_add_ordered_extent+0x243/0x310 [btrfs]
 [<ffffffffc07412c2>] cow_file_range+0x292/0x480 [btrfs]
 [<ffffffffc0742383>] run_delalloc_range+0x393/0x3d0 [btrfs]
 [<ffffffffc075a3f5>] writepage_delalloc.isra.39+0x105/0x170 [btrfs]
 [<ffffffffc075c1e9>] __extent_writepage+0xd9/0x340 [btrfs]
 [<ffffffff811fc600>] ? __page_check_address+0x1f0/0x1f0
 [<ffffffffc075c751>] extent_write_cache_pages.isra.35.constprop.52+0x301/0x3f0 [btrfs]
 [<ffffffffc073b9e3>] ? btrfs_submit_bio_hook+0xa3/0x1b0 [btrfs]
 [<ffffffffc073c4b0>] ? btrfs_fiemap+0x50/0x50 [btrfs]
 [<ffffffffc073baf0>] ? btrfs_submit_bio_hook+0x1b0/0x1b0 [btrfs]
 [<ffffffffc075dabc>] extent_writepages+0x5c/0x90 [btrfs]
 [<ffffffffc073ed00>] ? btrfs_releasepage+0x40/0x40 [btrfs]
 [<ffffffffc073bee8>] btrfs_writepages+0x28/0x30 [btrfs]
 [<ffffffff811c75be>] do_writepages+0x1e/0x30
 [<ffffffff81275a15>] __writeback_single_inode+0x45/0x310
 [<ffffffff812761cf>] writeback_sb_inodes+0x24f/0x5e0
 [<ffffffff812765f2>] __writeback_inodes_wb+0x92/0xc0
 [<ffffffff81276931>] wb_writeback+0x251/0x300
 [<ffffffff812770a2>] wb_workfn+0x222/0x3e0
 [<ffffffff810c0bdc>] process_one_work+0x15c/0x430
 [<ffffffff810c0efe>] worker_thread+0x4e/0x480
 [<ffffffff810c0eb0>] ? process_one_work+0x430/0x430
 [<ffffffff810c6d38>] kthread+0xd8/0xf0
 [<ffffffff817db082>] ret_from_fork+0x22/0x40
 [<ffffffff810c6c60>] ? kthread_worker_fn+0x170/0x170

Comment 1 O. ROUSSEL 2016-09-05 16:05:24 UTC
Created attachment 1197987 [details]
File: dmesg

Comment 2 O. ROUSSEL 2016-09-05 16:19:02 UTC
I forgot to mention that this fs contains a snapshot. The other BTRFS I have on other hosts do not (so far). Don't know if this could be related.

Comment 3 Laura Abbott 2016-09-23 19:50:00 UTC
*********** MASS BUG UPDATE **************
 
We apologize for the inconvenience.  There is a large number of bugs to go through and several of them have gone stale.  Due to this, we are doing a mass bug update across all of the Fedora 23 kernel bugs.
 
Fedora 23 has now been rebased to 4.7.4-100.fc23.  Please test this kernel update (or newer) and let us know if you issue has been resolved or if it is still present with the newer kernel.
 
If you have moved on to Fedora 24 or 25, and are still experiencing this issue, please change the version to Fedora 24 or 25.
 
If you experience different issues, please open a new bug report for those.

Comment 4 O. ROUSSEL 2016-10-19 18:22:28 UTC
As far as I can tell, this problem does not seem to occur any more with kernel 4.7.6-100.fc23.x86_64.