-
Type: Task
-
Resolution: Fixed
-
Priority: Critical - P2
-
Affects Version/s: 4.4.4
-
Component/s: None
-
Fully Compatible
-
v5.0, v4.4
-
Sharding 2021-03-22, Sharding 2021-04-05
In version 4.4+, a cluster can get a BSONObjectTooLarge error when attempting to migrate chunks. The _migrateClone command that the recipient invokes has logic here and here to ensure that we don't return too big of a vector to be placed in the command. The particular error is below:
{"t": {"$date":"2021-03-10T21:27:33.038Z"} ,"s":"W","c":"SHARDING","id":23777,"ctx":"MoveChunk","msg":"Error while doing moveChunk","attr":{"error":"OperationFailed: Data transfer error: migrate failed: BSONObjectTooLarge: _migrateClone failed: :: caused by :: BSONObj size: 16861227 (0x101482B) is invalid. Size must be between 0 and 16793600(16MB) First element: ...REDACTED] }"}}
The goal of this ticket is to reproduce the error and determine the best way to mitigate the situation. The parameters internalQueryExecYieldIterations/internalQueryExecYieldPeriodMS have been suggested as a possible work around, but runtime effects of changing the parameters should be evaluated.