[SERVER-41248] Ensure ReplicaSetMonitor initializes its random state with truly random data Created: 20/May/19 Updated: 29/Oct/23 Resolved: 19/Aug/19 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Internal Code |
| Affects Version/s: | 3.6.12, 4.0.9 |
| Fix Version/s: | 3.6.14, 4.0.13 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Mira Carey | Assignee: | Benjamin Caimano (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | neweng | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Backwards Compatibility: | Fully Compatible | ||||
| Operating System: | ALL | ||||
| Backport Requested: |
v4.0, v3.6
|
||||
| Sprint: | Service Arch 2019-07-15, Service Arch 2019-08-12, Service Arch 2019-08-26 | ||||
| Participants: | |||||
| Description |
|
The replica set monitor in older versions of the server initializes it's random state via:
which has the unfortunate side effect of being strongly synchronized with the system clock. This can cause non-random patterns of access across a mongos / series of mongos' in cases where all of the nodes are restarted at the same time and work is distributed evenly across the various mongos'. Switching to use a real source of randomness for seeding the prngs in each set state should improve the real randomness of later server selection Note: It appears this was fixed in 4.2 as part of unrelated code changes |
| Comments |
| Comment by Githook User [ 15/Aug/19 ] |
|
Author: {'username': 'shailejajain', 'email': 'shaileja.jain@gmail.com', 'name': 'Shaileja Jain'}Message: (cherry picked from commit ee71321881cfa25c0eba4948a71a9a6f6e5076a8) |
| Comment by Shaileja Jain (Inactive) [ 09/Aug/19 ] |
|
4.0 is in code freeze. |
| Comment by Githook User [ 09/Aug/19 ] |
|
Author: {'name': 'Shaileja Jain', 'username': 'shailejajain', 'email': 'shaileja.jain@gmail.com'}Message: |