Project

General

Profile

Actions

Bug #80407

closed
IG AD

MDS crash: ceph_assert(isolated_inodes.empty()) in MDCache::handle_cache_rejoin_ack at MDCache.cc:5231 during config change

Bug #80407: MDS crash: ceph_assert(isolated_inodes.empty()) in MDCache::handle_cache_rejoin_ack at MDCache.cc:5231 during config change

Added by Igor Golikov 3 months ago. Updated 6 days ago.

Status:
Backporting
Priority:
Normal
Category:
Correctness/Safety
Target version:
Due date:
% Done:

0%

Source:
Development
Backport:
umbrella,tentacle
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
MDS
Labels (FS):
crash, multimds
Pull request ID:
Tags (freeform):
Fixed In:
v22.0.0-1528-g46c97f2800
Released In:
Upkeep Timestamp:
2026-11-26T10:02:27+00:00

Description

Description
An active MDS crashed with FAILED ceph_assert(isolated_inodes.empty()) in MDCache::handle_cache_rejoin_ack() while other ranks were in up:rejoin. The cluster recovered (standby took over the rank). No client-visible outage beyond the failed daemon. Hit 1/3 runs of a multi-MDS config-change + rank-failure stress test.

This is the same assertion as #62036 / #50821. It is not #80402 or #54840 (those fire in handle_cache_rejoin_weak() on different asserts).

Crash
assert_condition: isolated_inodes.empty()
assert_func: void MDCache::handle_cache_rejoin_ack(ceph::cref_t<MMDSCacheRejoin>&)
assert_file: src/mds/MDCache.cc
assert_thread: ms_dispatch
ceph_version: 20.2.1 (tentacle)
ceph::__ceph_assert_fail()
MDCache::handle_cache_rejoin_ack()
MDCache::dispatch()
MDSRank::_dispatch()
MDSRankDispatcher::ms_dispatch()
MDSDaemon::ms_dispatch2()
DispatchQueue::entry()
At crash time the FS map showed 16/16 MDS ranks with 2 up:rejoin and 14 up:active. The crashed daemon was replaced by a standby which took over the same rank.

Cluster / workload
CephFS max_mds=16, mds_cache_memory_limit=32G
Heavy metadata + data IO (fio randwrite, mdtest, find/ls) from several clients
Around crash: ~280–350 MiB/s rd, ~70–100 MiB/s wr, ~60–85k op/s
How to reproduce
Deploy multimds CephFS (max_mds=16).
Run concurrent client IO pinned across ranks.
In a loop (~40s/cycle, ~10 cycles):
set mds_cache_memory_limit to a random value in 1G–32G
also vary mds_beacon_grace, mds_log_max_segments, mds_bal_interval
ceph mds fail two random ranks
Crash is observed during rejoin processing (seen late in the run).
Actual result
MDS aborts in handle_cache_rejoin_ack() on isolated_inodes.empty().

Expected result
Cache rejoin completes without crashing, including while MDS config is changing and other ranks are recovering.

Notes
handle_cache_rejoin_ack() builds isolated_inodes for ack dirfrags whose inode is not in cache, then expects a parent dentry in the same ack to reconnect them. The in-tree FIXME already states this can happen if the replica subtree (and the inode it is rooted in) is trimmed between sending the cache rejoin and receiving the ack.

#52648 (mds: defer trim() until after the last cache_rejoin ack being received, fixes #62036) was merged. It defers trim while this rank is still in rejoin (rejoin_done). That does not cover an already-active survivor waiting on peer rejoin acks, which is this crash: rejoin_done is null, is_cache_trimmable() is true, and shrinking mds_cache_memory_limit makes trim aggressive.

#57124 (mds/cache: defer trim() until no MDS is rejoining, #50821) tried to close that survivor gap but was not merged. Review (especially Patrick Donnelly) argued against stopping all cache trim whenever any MDS is in up:rejoin, and asked for a closer look at the original race — including whether the FIXME fully describes the failure — rather than a broad trim deferral.

This should be investigated further along those lines before another fix attempt.

Related: #62036, #50821, #60343. Distinct from #80402 and #54840.


Related issues 3 (2 open — 1 closed)

Related to CephFS - Bug #50821: qa: untar_snap_rm failure during mds thrashingDuplicateVenky Shankar

Actions
Copied to CephFS - Backport #83611: umbrella: MDS crash: ceph_assert(isolated_inodes.empty()) in MDCache::handle_cache_rejoin_ack at MDCache.cc:5231 during config changeFix Under ReviewAnthony D'Atri

Actions
Copied to CephFS - Backport #83612: tentacle: MDS crash: ceph_assert(isolated_inodes.empty()) in MDCache::handle_cache_rejoin_ack at MDCache.cc:5231 during config changeFix Under ReviewAnthony D'Atri

Actions

VS Updated by Venky Shankar about 1 month ago Actions #1

  • Category set to Correctness/Safety
  • Status changed from New to Triaged
  • Assignee set to Venky Shankar
  • Target version set to v22.0.0
  • Source set to Development
  • Backport set to umbrella,tentacle,squid
  • Component(FS) MDS added
  • Labels (FS) crash, multimds added

AD Updated by Anthony D'Atri about 1 month ago Actions #2

  • Status changed from Triaged to Fix Under Review
  • Pull request ID set to 73264

AD Updated by Anthony D'Atri about 1 month ago Actions #3

  • Backport changed from umbrella,tentacle,squid to umbrella,tentacle

VS Updated by Venky Shankar 26 days ago Actions #4

  • Related to Bug #50821: qa: untar_snap_rm failure during mds thrashing added

VS Updated by Venky Shankar 26 days ago Actions #5

  • Assignee changed from Venky Shankar to Anthony D'Atri

UB Updated by Upkeep Bot 6 days ago Actions #6

  • Copied to Backport #83611: umbrella: MDS crash: ceph_assert(isolated_inodes.empty()) in MDCache::handle_cache_rejoin_ack at MDCache.cc:5231 during config change added

UB Updated by Upkeep Bot 6 days ago Actions #7

  • Copied to Backport #83612: tentacle: MDS crash: ceph_assert(isolated_inodes.empty()) in MDCache::handle_cache_rejoin_ack at MDCache.cc:5231 during config change added

UB Updated by Upkeep Bot 6 days ago Actions #8

  • Status changed from Fix Under Review to Backporting
  • Merge Commit set to 46c97f2800a4274be3611e59476c6f386f77f51a
  • Fixed In set to v22.0.0-1528-g46c97f2800
  • Upkeep Timestamp set to 2026-11-26T10:02:27+00:00
Actions

Also available in: PDF Atom