[SERVER-16939] Server 2.6 should respect userFlags when creating a new replica Created: 20/Jan/15  Updated: 06/Dec/22  Resolved: 23/Nov/16

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: 2.6.7
Fix Version/s: None

Type: Bug Priority: Minor - P4
Reporter: Tony Nelson Assignee: Backlog - Replication Team
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Replication
Operating System: ALL
Steps To Reproduce:

Create a small replica set
Create a collection with usePowerOf2Size disabled
Add a new member to the replica set
This new member will change the value of usePowerOf2Size

Participants:

 Description   

Replica sets created by 2.6 servers always set the usePowerOf2Sizes flag for all collections it creates, even if the source collection being replicated does not have this flag set.

My GridFS collection almost doubled in size on the new server because most of my documents were created with an old driver version. This issue is described here: SERVER-13331 .

I believe the correct workaround is to copy the data files from an existing replica member before joining the replica set, but I haven't tested that yet.



 Comments   
Comment by Spencer Brody (Inactive) [ 23/Nov/16 ]

2.6 is EOL

Comment by Ramon Fernandez Marina [ 20/Jan/15 ]

hhubris, we can observe the behavior you describe and we're investigating.

A possible workaround is to start the new secondary with

--setParameter newCollectionsUsePowerOf2Sizes=false

or to add the equivalent entry in the config file for this secondary:

setParameter: {newCollectionsUsePowerOf2Sizes: false}

Generated at Thu Feb 08 03:42:46 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.