xfs-masters
[Top] [All Lists]

[Bug 844] New: xfs_repair from git segfaults in stage 6

To: xfs-masters@xxxxxxxxxxx
Subject: [Bug 844] New: xfs_repair from git segfaults in stage 6
From: bugzilla-daemon@xxxxxxxxxxx
Date: Wed, 22 Jul 2009 15:54:33 -0500
Auto-submitted: auto-generated
http://oss.sgi.com/bugzilla/show_bug.cgi?id=844

           Summary: xfs_repair from git segfaults in stage 6
           Product: XFS
           Version: Current
          Platform: All
        OS/Version: Linux
            Status: NEW
          Severity: major
          Priority: P5
         Component: xfsprogs
        AssignedTo: xfs-masters@xxxxxxxxxxx
        ReportedBy: arekm@xxxxxxxx
   Estimated Hours: 0.0
    Classification: Unclassified


I had a oops

[   64.417171] Filesystem "dm-0": Disabling barriers, trial barrier write
failed
[   64.417334] XFS mounting filesystem dm-0
[   64.583245] Starting XFS recovery on filesystem: dm-0 (logdev: internal)
[  112.931354] XFS internal error XFS_WANT_CORRUPTED_GOTO at line 1545 of file
fs/xfs/xfs_alloc.c.  Caller 0xffffffffa00c4120
[  112.931359] Pid: 2797, comm: mount Not tainted 2.6.28.9-3 #1
[  112.931361] Call Trace:
[  112.931386]  [<ffffffffa00c4120>] xfs_free_extent+0xa0/0xc0 [xfs]
[  112.931397]  [<ffffffffa00c244d>] xfs_alloc_log_agf+0x64d/0x810 [xfs]
[  112.931407]  [<ffffffffa00c4120>] xfs_free_extent+0xa0/0xc0 [xfs]
[  112.931417]  [<ffffffffa010d0a8>] xfs_trans_get_efd+0x28/0x40 [xfs]
[  112.931428]  [<ffffffffa0100fa0>] xlog_pack_data+0x400/0x4d0 [xfs]
[  112.931438]  [<ffffffffa0101031>] xlog_pack_data+0x491/0x4d0 [xfs]
[  112.931448]  [<ffffffffa0103a3c>] xlog_recover_finish+0x1c/0x250 [xfs]
[  112.931458]  [<ffffffffa01082a2>] xfs_mountfs+0x4e2/0x680 [xfs]
[  112.931470]  [<ffffffffa00ebb00>] xfs_filestream_lookup_ag+0x60/0x4f0 [xfs]
[  112.931479]  [<ffffffffa0114dcb>] kmem_zalloc+0x2b/0x40 [xfs]
[  112.931488]  [<ffffffffa0121652>] xfs_blkdev_get+0x492/0x660 [xfs]
[  112.931494]  [<ffffffff802d7c64>] get_sb_bdev+0x174/0x1a0
[  112.931503]  [<ffffffffa01213f0>] xfs_blkdev_get+0x230/0x660 [xfs]
[  112.931508]  [<ffffffff802a6844>] kstrdup+0x54/0x70
[  112.931513]  [<ffffffff802d75f6>] vfs_kern_mount+0x86/0x250
[  112.931516]  [<ffffffff802d7823>] do_kern_mount+0x53/0x120
[  112.931519]  [<ffffffff802f14cd>] do_mount+0x2ed/0xa50
[  112.931521]  [<ffffffff802f1d29>] sys_mount+0xf9/0x110
[  112.931524]  [<ffffffff802031bb>] system_call_fastpath+0x16/0x1b
[  112.931532] Failed to recover EFIs on filesystem: dm-0
[  112.931534] XFS: log mount finish failed

rebooted and tried to xfs_repair -L partition. Unfortunately xfs_repair
segfaulted. Tested 3.0.1 and git version (kernel.org tree). Both segfault.

xfs_metadump of filesystem is at ftp://phobos.maven.pl/xfs-problem.bz2

xfs_repair (git version) end of output:
        - agno = 20
        - agno = 21
        - agno = 22
        - agno = 23
        - agno = 24
        - agno = 25
        - agno = 26
no . entry for directory 3503084373
no .. entry for directory 3503084373
        - agno = 27
        - agno = 28
        - agno = 29
        - agno = 30
        - agno = 31
Phase 5 - rebuild AG headers and trees...
        - reset superblock...
Phase 6 - check inode connectivity...
        - resetting contents of realtime bitmap and summary inodes
        - traversing filesystem ...
entry "stdio-common" in dir ino 2858345118 doesn't have a .. entry, will set it
in ino 3503084373.
empty data block 0 in directory inode 3503084373: junking block

gdb says:
Program received signal SIGSEGV, Segmentation fault.
0x00000000004231c7 in xfs_dir2_block_tail_p (block=<value optimized out>,
mp=<value optimized out>) at ../include/xfs/xfs_dir2_block.h:66
66      ../include/xfs/xfs_dir2_block.h: Nie ma takiego pliku ani katalogu.
        in ../include/xfs/xfs_dir2_block.h
(gdb)

(gdb) bt
#0  0x00000000004231c7 in xfs_dir2_block_tail_p (block=<value optimized out>,
mp=<value optimized out>) at ../include/xfs/xfs_dir2_block.h:66
#1  longform_dir2_entry_check (block=<value optimized out>, mp=<value optimized
out>) at phase6.c:2532
#2  0x0000000000428247 in process_dir_inode (mp=0x7fff9ec5b380, agno=<value
optimized out>, irec=<value optimized out>, ino_offset=<value optimized out>)
    at phase6.c:3290
#3  0x0000000000428784 in traverse_function (arg=<value optimized out>,
agno=<value optimized out>, wq=<value optimized out>) at phase6.c:3606
#4  traverse_ags (arg=<value optimized out>, agno=<value optimized out>,
wq=<value optimized out>) at phase6.c:3648
#5  phase6 (arg=<value optimized out>, agno=<value optimized out>, wq=<value
optimized out>) at phase6.c:3745
#6  0x00000000004327db in main (argc=<value optimized out>, argv=<value
optimized out>) at xfs_repair.c:733


66 line of xfs_dir2_block.h file is:
static inline xfs_dir2_block_tail_t *
xfs_dir2_block_tail_p(struct xfs_mount *mp, xfs_dir2_block_t *block)
{
        return (((xfs_dir2_block_tail_t *)
                ((char *)(block) + (mp)->m_dirblksize)) - 1);
}

-- 
Configure bugmail: http://oss.sgi.com/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

<Prev in Thread] Current Thread [Next in Thread>