Project

General

Profile

Feature #55214

mds: add asok/tell command to clear stale omap entries

Added by Venky Shankar 8 months ago. Updated 8 months ago.

Status:
New
Priority:
Normal
Assignee:
Category:
Administration/Usability
Target version:
% Done:

0%

Source:
Tags:
Backport:
quincy, pacific
Reviewed:
Affected Versions:
Component(FS):
MDS
Labels (FS):
Pull request ID:

Description

Its rather easy to end up with an on-disk inode object that stays un-fragmented, with omap count exceeding `mds_bal_split_size' (default: 10000 entries). This can be achieved as follows:

  1. mkdir d0
  2. touch d0/file{0..11000}
  3. mkdir d0/.snap/snap_a
  4. rm -f d0/file*
    #rmdir d0/.snap/snap_a

Since the MDS does not fragment directory snapshots, the omap count for the directory inode is 11000. Doing this over and over again increases the omap count to a point if it exceeds `osd_deep_scrub_large_omap_object_key_threshold' (default: 200000), the cluster experiences "large omap" warnings with state HEALTH_WARN. Removing the snapshot does not purge stale omap entries and those stay there until the MDS loads the dirfrag.

Provide an asok/tell command to force the MDS to clear stale omap entries.

To rectify this state,


Related issues

Related to CephFS - Feature #55215: mds: fragment directory snapshots Fix Under Review

History

#1 Updated by Venky Shankar 8 months ago

(formatting description)

Its rather easy to end up with an on-disk inode object that stays un-fragmented, with omap count exceeding `mds_bal_split_size' (default: 10000 entries). This can be achieved as follows:

  1. mkdir d0
  2. touch d0/file{0..11000}
  3. mkdir d0/.snap/snap_a
  4. rm -f d0/file*
  5. #rmdir d0/.snap/snap_a

Since the MDS does not fragment directory snapshots, the omap count for the directory inode is 11000. Doing this over and over again increases the omap count to a point if it exceeds `osd_deep_scrub_large_omap_object_key_threshold' (default: 200000), the cluster experiences "large omap" warnings with state HEALTH_WARN. Removing the snapshot does not purge stale omap entries and those stay there until the MDS loads the dirfrag.

Provide an asok/tell command to force the MDS to clear stale omap entries.

#2 Updated by Venky Shankar 8 months ago

#3 Updated by Venky Shankar 8 months ago

  • Assignee set to Venky Shankar

Also available in: Atom PDF