Operational Defect Database

BugZero found this defect 82 days ago.

MongoDB | 2590932

Race in _finishReplSetReconfig with background compaction

Last update date:

3/13/2024

Affected products:

MongoDB Server

Affected releases:

No affected releases provided.

Fixed releases:

8.0 Required

Description:

Info

When background compaction is enabled (as shown here and here), one may hit the following invariant: "expr":"_rsConfigState == kConfigReconfiguring","file":"src/mongo/db/repl/replication_coordinator_impl.cpp","line":4224 suganthi.mani@mongodb.com started to investigate the issue: It seems like your change has exposed a bug in repl layer. Enabling the auto compaction as part of notifyReplRecoveryComplete (internally called by replSetInitiate cmd code path) , makes replSetInitiate cmd to take longer time to complete (few milliseconds) and that causes to race with stepup thread and leading to the invariant failure

Top User Comments


Steps to Reproduce

See those patches to see the diff: patch build patch build

Additional Resources / Links

Share:

BugZero® Risk Score

What's this?

Coming soon

Status

In Code Review

Learn More

Search:

...