Bug #58294
closedMDS: scan_stray_dir doesn't walk through all stray inode fragment
100%
Description
After commit 28227872295ae657a0d26a3f004c54c41794db18 mds: automatically fragment stray dirs
stray dirs are allowed to be fragment.
But scan_stray_dir doesn't walk through all fragments of the stray inodes correctly.
It doesn't reset next.frag after each run of stray dir inode.
Therefore, next stray inode will start from the last fragment of previous stray inode, and the preceding fragments are all skipped.
For example,
suppose stray inode 0x601 has the following fragments
0x00
0x01
0x10
0x11
If fragment 0x01 is not complete, dir would send a fetch request and next is set with ino=0x601, fragment=0x01.
After all 0x601 fragments finishes, next remains the same as ino=0x601, fragment=0x01.
All inode 0x602~0x609's fragments that are < 0x01 won't be processed.
Updated by Venky Shankar over 1 year ago
- Subject changed from scan_stray_dir doesn't walk through all stray inode fragment to MDS: scan_stray_dir doesn't walk through all stray inode fragment
- Category set to Correctness/Safety
- Status changed from New to Fix Under Review
- Assignee set to ethan wu
- Target version set to v18.0.0
- Backport set to pacific,quincy
Updated by Venky Shankar over 1 year ago
- Status changed from Fix Under Review to Pending Backport
Updated by Backport Bot over 1 year ago
- Copied to Backport #58349: pacific: MDS: scan_stray_dir doesn't walk through all stray inode fragment added
Updated by Backport Bot over 1 year ago
- Copied to Backport #58350: quincy: MDS: scan_stray_dir doesn't walk through all stray inode fragment added
Updated by Konstantin Shalygin 8 months ago
- Status changed from Pending Backport to Resolved
- % Done changed from 0 to 100