Bug 1314911

Summary: XFS Corruption
Product: [Fedora] Fedora Reporter: Christopher Bachner <b.christopher.92>
Component: kernelAssignee: Eric Sandeen <esandeen>
Status: CLOSED INSUFFICIENT_DATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 23CC: b.christopher.92, esandeen, gansalmon, itamar, jonathan, kernel-maint, madhu.chinakonda, mchehab
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-03-07 20:10:25 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Christopher Bachner 2016-03-04 20:34:03 UTC
Description of problem: This week I got random XFS corruptions on two different partitions. 


Version-Release number of selected component (if applicable): Fedora 23,xfsprogs-3.2.4-1.fc23.x86_64, Kernel 4.4.3-300.fc23.x86_64


How reproducible:
Not sure

Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:
Mar 04 09:12:49 fedora23 kernel: XFS (sda5): Internal error XFS_WANT_CORRUPTED_GOTO at line 3156 of file fs/xfs/libxfs/xfs_btree.c.  Caller xfs_free_ag_extent+0x46c/0x770 [xfs]
Mar 04 09:12:49 fedora23 kernel: CPU: 2 PID: 3415 Comm: Chrome_CacheThr Tainted: P           OE   4.4.3-300.fc23.x86_64 #1
Mar 04 09:12:49 fedora23 kernel: Hardware name: ASUS All Series/Z87-K, BIOS 1402 11/05/2014
Mar 04 09:12:49 fedora23 kernel:  0000000000000286 000000009acf04a2 ffff88039012fae8 ffffffff813b4b6e
Mar 04 09:12:49 fedora23 kernel:  ffff88003fb2f110 ffff88003fb2f110 ffff88039012fb00 ffffffffa0123bbc
Mar 04 09:12:49 fedora23 kernel:  ffffffffa00e183c ffff88039012fb80 ffffffffa00fdaad ffff88039012fbec
Mar 04 09:12:49 fedora23 kernel: Call Trace:
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff813b4b6e>] dump_stack+0x63/0x85
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa0123bbc>] xfs_error_report+0x3c/0x40 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa00e183c>] ? xfs_free_ag_extent+0x46c/0x770 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa00fdaad>] xfs_btree_insert+0x14d/0x1b0 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa00e183c>] xfs_free_ag_extent+0x46c/0x770 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa00e2c25>] xfs_free_extent+0xf5/0x120 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa014f896>] xfs_trans_free_extent+0x26/0x60 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa011ce49>] xfs_bmap_finish+0xf9/0x120 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa0134112>] xfs_itruncate_extents+0x122/0x260 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa01342e9>] xfs_inactive_truncate+0x99/0x110 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa0135062>] xfs_inactive+0x102/0x120 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa013a315>] xfs_fs_evict_inode+0xa5/0x100 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8124866a>] evict+0xaa/0x170
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8124893e>] iput+0x1be/0x240
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8123daec>] do_unlinkat+0x1cc/0x290
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8123e5c6>] SyS_unlink+0x16/0x20
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8179f16e>] entry_SYSCALL_64_fastpath+0x12/0x71
Mar 04 09:12:49 fedora23 kernel: XFS (sda5): Internal error xfs_trans_cancel at line 990 of file fs/xfs/xfs_trans.c.  Caller xfs_inactive_truncate+0xda/0x110 [xfs]
Mar 04 09:12:49 fedora23 kernel: CPU: 2 PID: 3415 Comm: Chrome_CacheThr Tainted: P           OE   4.4.3-300.fc23.x86_64 #1
Mar 04 09:12:49 fedora23 kernel: Hardware name: ASUS All Series/Z87-K, BIOS 1402 11/05/2014
Mar 04 09:12:49 fedora23 kernel:  0000000000000286 000000009acf04a2 ffff88039012fd98 ffffffff813b4b6e
Mar 04 09:12:49 fedora23 kernel:  ffff8800c9e24cb0 0000000000000001 ffff88039012fdb0 ffffffffa0123bbc
Mar 04 09:12:49 fedora23 kernel:  ffffffffa013432a ffff88039012fdd8 ffffffffa013eee6 00000000ffffff8b
Mar 04 09:12:49 fedora23 kernel: Call Trace:
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff813b4b6e>] dump_stack+0x63/0x85
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa0123bbc>] xfs_error_report+0x3c/0x40 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa013432a>] ? xfs_inactive_truncate+0xda/0x110 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa013eee6>] xfs_trans_cancel+0xb6/0xe0 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa013432a>] xfs_inactive_truncate+0xda/0x110 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa0135062>] xfs_inactive+0x102/0x120 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffffa013a315>] xfs_fs_evict_inode+0xa5/0x100 [xfs]
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8124866a>] evict+0xaa/0x170
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8124893e>] iput+0x1be/0x240
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8123daec>] do_unlinkat+0x1cc/0x290
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8123e5c6>] SyS_unlink+0x16/0x20
Mar 04 09:12:49 fedora23 kernel:  [<ffffffff8179f16e>] entry_SYSCALL_64_fastpath+0x12/0x71
Mar 04 09:12:49 fedora23 kernel: XFS (sda5): xfs_do_force_shutdown(0x8) called from line 991 of file fs/xfs/xfs_trans.c.  Return address = 0xffffffffa013eeff
Mar 04 09:12:49 fedora23 kernel: XFS (sda5): Corruption of in-memory data detected.  Shutting down filesystem
Mar 04 09:12:49 fedora23 kernel: XFS (sda5): Please umount the filesystem and rectify the problem(s)

Comment 1 Eric Sandeen 2016-03-07 16:48:08 UTC
Hit some sort of btree corruption, I would follow the advice:

> Mar 04 09:12:49 fedora23 kernel: XFS (sda5): Please umount the filesystem and rectify the problem(s)

by the following steps:

* Unmount the filesystem
* Mount the filesystem again to replay the log if needed
* Unmount the filesystem again
* Run xfs_repair (first with the -n option to be sure it doesn't look too catastrophic)
* Save the output and attach it to this bug.

Comment 2 Christopher Bachner 2016-03-07 20:02:13 UTC
When I tried to mount the filesystem, I got a "structure needs cleaning." So I had to basically force an xfs_repair. After that I was able to mount it and copy off all my files. I decided to change to ext4 for now because I got two xfs corruptions in such a short time period. However, could this be due to bad ram? Maybe I should run some memtest?

I did all of this when I filed the bug, so I was not able to save the output of xfs_repair.

Thanks

Comment 3 Eric Sandeen 2016-03-07 20:10:25 UTC
Sounds like log replay failed too; this could indicate a storage problem as well... but without more logs, or xfs_repair output, etc, it's hard to know what has happened.