Operational Defect Database

BugZero found this defect 321 days ago.

MongoDB | 2382497

ReshardingCoordinatorService Index build deadlocks with OpObserver

Last update date:

3/13/2024

Affected products:

MongoDB Server

Affected releases:

No affected releases provided.

Fixed releases:

No fixed releases provided.

Description:

Info

In its _rebuildService, the ReshardingCoordinator tries to build an index. Initialization of the service cannot complete until this index is built. In the related resharding OpObserver onUpdate, we wait for the service to complete initialization, while holding an IX lock. Two-phase indexes require an S lock to complete, so that can result in deadlock if the collection is not empty when the index is built. This is extremely rare or can't happen under normal circumstances in 7.0 (because either the index exists already or the collection is empty), but if a later revision removes the index, downgrade can deadlock the service.

Top User Comments


Steps to Reproduce


Additional Resources / Links

Share:

BugZero® Risk Score

What's this?

Coming soon

Status

Backlog

Learn More

Search:

...