Skip to content

squid: mds: trim mdlog when segments exceed threshold and trim was idle - #60838

Merged
mchangir merged 3 commits into
ceph:squidfrom
vshankar:wip-68919-squid
Feb 6, 2025
Merged

mchangir merged 3 commits into
ceph:squidfrom
vshankar:wip-68919-squid

Conversation

@vshankar

Copy link
Copy Markdown
Contributor

Signed-off-by: Venky Shankar <[email protected]>
(cherry picked from commit 7d11c70)
Credit goes to Patrick (@batrick) for identifying this.

When there are huge number of subtree exports (such as done in export
thrashing test), the MDS would log an EExport event. The EExport event
is relatively large in size. This causes the MDS to log new minor log
segments frequently. Moreover, the MDS logs a major segment (boundary)
after a certain number of events have been logged. This casues large
number of (minor) events to get build up and cause delays in trimming
expired segments, since journal expire position is updated on segment
boundaries.

To mitigate this issue, the MDS now starts a major segment after a
configured number of minor segments have been logged. This threshold
is configurable by adjusting `mds_log_minor_segments_per_major_segment`
MDS config (defaults to 16).

Fixes: https://tracker.ceph.com/issues/66948
Signed-off-by: Venky Shankar <[email protected]>
(cherry picked from commit 718afe2)

Conflicts:
    src/common/options/mds.yaml.in

Minor conflict in mds.yaml.in for missing configs in squid release.
Signed-off-by: Venky Shankar <[email protected]>
(cherry picked from commit f54be33)
@vshankar
vshankar requested a review from a team as a code owner November 26, 2024 05:20
@vshankar vshankar added this to the squid milestone Nov 26, 2024
@vshankar vshankar added the cephfs Ceph File System label Nov 26, 2024
@vshankar

vshankar commented Jan 5, 2025

Copy link
Copy Markdown
Contributor Author

@batrick

batrick commented Jan 9, 2025

Copy link
Copy Markdown
Member

If you're not set to merge this yet, it'd be nice to include https://tracker.ceph.com/issues/69426#note-3 with this PR.

@vshankar

Copy link
Copy Markdown
Contributor Author

If you're not set to merge this yet, it'd be nice to include https://tracker.ceph.com/issues/69426#note-3 with this PR.

I'll rebuild the branch with the additional fix.

@mchangir mchangir left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mchangir
mchangir merged commit 656977f into ceph:squid Feb 6, 2025
afreen23 pushed a commit to rhcs-dashboard/ceph that referenced this pull request Jul 29, 2026
squid: mds: trim mdlog when segments exceed threshold and trim was idle
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants