Bug 10981
Summary: | XFS filesystem corruption when running out of space | ||
---|---|---|---|
Product: | File System | Reporter: | Török Edwin (edwin+bugs) |
Component: | XFS | Assignee: | XFS Guru (xfs-masters) |
Status: | CLOSED OBSOLETE | ||
Severity: | normal | CC: | alan |
Priority: | P1 | ||
Hardware: | All | ||
OS: | Linux | ||
Kernel Version: | 2.6.26-rc4-00168-gc3b25b3 | Subsystem: | |
Regression: | No | Bisected commit-id: |
Description
Török Edwin
2008-06-25 06:40:46 UTC
Mount has encountered a corrupt AGF. You will have to destroy the log and run repair so this filesystem can be mounted again. Fortunately the panic occured after the log was replayed so the damage should be minimised. But before you do that could you do the following? # xfs_db /dev/sda6 xfs_db> agf 0 xfs_db> print magicnum = 0x58414746 versionnum = 1 ... xfs_db> agf 1 xfs_db> print magicnum = 0x58414746 versionnum = 1 ... and keep doing that for each AG in the filesystem and post the output. There shouldn't be too many AGs (probably about 4). And if possible run xfs_metadump on this filesystem. (In reply to comment #1) > Mount has encountered a corrupt AGF. You will have to destroy the log and > run > repair so this filesystem can be mounted again. Fortunately the panic > occured > after the log was replayed so the damage should be minimised. But before you > do > that could you do the following? > I had 15 agf, here is the output: # xfs_db /dev/sda6 xfs_db: cannot init perag data (117) xfs_db> agf 0 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 0 length = 152617 bnoroot = 21179 cntroot = 2977 bnolevel = 2 cntlevel = 2 flfirst = 13 fllast = 18 flcount = 6 freeblks = 1809 longest = 10 btreeblks = 4 xfs_db> agf 1 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 1 length = 152617 bnoroot = 170 cntroot = 648 bnolevel = 1 cntlevel = 1 flfirst = 126 fllast = 1 flcount = 4 freeblks = 1360 longest = 10 btreeblks = 0 xfs_db> agf 2 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 2 length = 152617 bnoroot = 4350 cntroot = 4490 bnolevel = 1 cntlevel = 1 flfirst = 108 fllast = 111 flcount = 4 freeblks = 1410 longest = 10 btreeblks = 0 xfs_db> agf 3 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 3 length = 152617 bnoroot = 915 cntroot = 1677 bnolevel = 1 cntlevel = 1 flfirst = 118 fllast = 121 flcount = 4 freeblks = 1640 longest = 10 btreeblks = 0 xfs_db> agf 4 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 4 length = 152617 bnoroot = 2582 cntroot = 3055 bnolevel = 2 cntlevel = 2 flfirst = 124 fllast = 1 flcount = 6 freeblks = 4294967292 longest = 11 btreeblks = 4 xfs_db> agf 5 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 5 length = 152617 bnoroot = 169 cntroot = 180 bnolevel = 1 cntlevel = 1 flfirst = 85 fllast = 88 flcount = 4 freeblks = 860 longest = 10 btreeblks = 0 xfs_db> agf 6 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 6 length = 152617 bnoroot = 315 cntroot = 1213 bnolevel = 1 cntlevel = 1 flfirst = 60 fllast = 63 flcount = 4 freeblks = 998 longest = 11 btreeblks = 0 xfs_db> agf 7 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 7 length = 152617 bnoroot = 699 cntroot = 753 bnolevel = 1 cntlevel = 1 flfirst = 66 fllast = 69 flcount = 4 freeblks = 849 longest = 10 btreeblks = 0 xfs_db> agf 8 pxfs_db> rint magicnum = 0x58414746 versionnum = 1 seqno = 8 length = 152617 bnoroot = 12543 cntroot = 12545 bnolevel = 2 cntlevel = 2 flfirst = 34 fllast = 39 flcount = 6 freeblks = 1696 longest = 12 btreeblks = 4 xfs_db> agf 9 pxfs_db> rint magicnum = 0x58414746 versionnum = 1 seqno = 9 length = 152617 bnoroot = 18838 cntroot = 14324 bnolevel = 2 cntlevel = 2 flfirst = 124 fllast = 1 flcount = 6 freeblks = 4048 longest = 12 btreeblks = 4 xfs_db> agf 10 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 10 length = 152617 bnoroot = 2102 cntroot = 3239 bnolevel = 1 cntlevel = 1 flfirst = 7 fllast = 10 flcount = 4 freeblks = 1384 longest = 10 btreeblks = 0 xfs_db> agf 11 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 11 length = 152617 bnoroot = 465 cntroot = 1211 bnolevel = 1 cntlevel = 1 flfirst = 112 fllast = 115 flcount = 4 freeblks = 433 longest = 10 btreeblks = 0 xfs_db> agf 12 prxfs_db> int magicnum = 0x58414746 versionnum = 1 seqno = 12 length = 152617 bnoroot = 139 cntroot = 265 bnolevel = 2 cntlevel = 2 flfirst = 55 fllast = 60 flcount = 6 freeblks = 3203 longest = 10 btreeblks = 5 xfs_db> agf 13 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 13 length = 152617 bnoroot = 29595 cntroot = 218 bnolevel = 2 cntlevel = 2 flfirst = 59 fllast = 64 flcount = 6 freeblks = 2018 longest = 10 btreeblks = 4 xfs_db> agf 14 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 14 length = 152617 bnoroot = 2813 cntroot = 4492 bnolevel = 1 cntlevel = 1 flfirst = 89 fllast = 92 flcount = 4 freeblks = 499 longest = 10 btreeblks = 0 xfs_db> agf 15 xfs_db> print magicnum = 0x58414746 versionnum = 1 seqno = 15 length = 152617 bnoroot = 76 cntroot = 145 bnolevel = 2 cntlevel = 2 flfirst = 40 fllast = 45 flcount = 6 freeblks = 2482 longest = 10 btreeblks = 4 xfs_db> agf 16 bad allocation group number 16 Here is the metadump of the filesystem (19M bzip2 compressed): http://www.hotlinkfiles.com/files/1499548_on9su/metadump_1.bz2 I have run xfs_repair -L /dev/sda6, and mounted the filesystem. Here is xfs_info: meta-data=/dev/sda6 isize=256 agcount=16, agsize=152617 blks = sectsz=512 attr=2 data = bsize=4096 blocks=2441872, imaxpct=25 = sunit=0 swidth=0 blks, unwritten=1 naming =version 2 bsize=4096 log =internal bsize=4096 blocks=2560, version=2 = sectsz=512 sunit=0 blks, lazy-count=1 realtime =none extsz=65536 blocks=0, rtextents=0 Is there any other information you'd need? AGF 4 has a bogus free block count of 4294967292 (should be less than 152617). Thanks for the metadump, I'll pull it down and see what else I can dig out of it. Closing as obsolete, please re-open if this is incorrect |