mirror of
https://github.com/ceph/ceph
synced 2024-12-18 17:37:38 +00:00
mds: handle case where rank 0 has no subtrees
Previously we always asked for STOPPING in this case, but in the case of rank 0 it's definitely an error condition indicating repair is needed. Signed-off-by: John Spray <john.spray@redhat.com>
This commit is contained in:
parent
7252975ef8
commit
69a54e7bb4
@ -2249,8 +2249,15 @@ void MDS::rejoin_done()
|
||||
|
||||
// funny case: is our cache empty? no subtrees?
|
||||
if (!mdcache->is_subtrees()) {
|
||||
dout(1) << " empty cache, no subtrees, leaving cluster" << dendl;
|
||||
request_state(MDSMap::STATE_STOPPED);
|
||||
if (whoami == 0) {
|
||||
// The root should always have a subtree!
|
||||
clog->error() << "No subtrees found for root MDS rank!";
|
||||
damaged();
|
||||
assert(mdcache->is_subtrees());
|
||||
} else {
|
||||
dout(1) << " empty cache, no subtrees, leaving cluster" << dendl;
|
||||
request_state(MDSMap::STATE_STOPPED);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user