xfs
[Top] [All Lists]

xfs_repair missing freetab entry

To: linux-xfs@xxxxxxxxxxx
Subject: xfs_repair missing freetab entry
From: Masanori TSUDA <tsuda@xxxxxxxxxxxxxx>
Date: Wed, 14 Dec 2005 21:14:12 +0900
Sender: linux-xfs-bounce@xxxxxxxxxxx
Hi,

I encountered a problem that xfs_repair outputs the corruption
message below.

  (snip)
  Phase 6 - check inode connectivity...
          - traversing filesystem starting at / ...
  missing freetab entry 2039 for directory inode 131
          - traversal finished ...
          - traversing all unattached subtrees ...
          - traversals finished ...
          - moving disconnected inodes to lost+found ...
  (snip)

My environment is as follows.

 kernel   : 2.4.31
 xfsprogs : 2.7.9-1

I investigated this problem using xfs_db etc.
I think that this problem was caused by xfs_repair judge miss.

When the count of valid entries in the intermediate freespace block
of the directory is below 2040(XFS_DIR2_MAX_FREE_BESTS(mp)) or the
intermediate freespace block is hole,
xfs_repair outputs "missing freetab entry...".
But its filesystem is correct. Because kernel space functions
xfs_dir2_node_addname_int(), xfs_dir2_leafn_remove() make its
state.

I made patch to solve this problem.
The xfs_preair added the patch was running with no corruption
messages.

Could you please comment the attached patch.

attached files
 T001_xfs.sh : reproducible script
 phase6.patch : xfs_repair patch

Regards,

---
 Masanori Tsuda

Attachment: T001_xfs.sh
Description: Binary data

Attachment: phase6.patch
Description: Binary data

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