[SERVER-2019] _id index on capped collection : inconsistent between master and slave Created: 28/Oct/10 Updated: 02/Jul/21 Resolved: 07/Mar/14 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | Dwight Merriman | Assignee: | Dwight Merriman |
| Resolution: | Done | Votes: | 3 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
there seems to be no _id index on the replication primary but there is on the slaves what to do - create them on the primary? |
| Comments |
| Comment by Githook User [ 02/Jul/21 ] |
|
Author: {'name': 'Brian McCarthy', 'email': 'brian.mccarthy@mongodb.com', 'username': 'briananthonymccarthy'}Message: BUILD-13557 Windows vsCurrent should use Windows_Server-2019-English-Full-Base as source AMI |
| Comment by Githook User [ 02/Jul/21 ] |
|
Author: {'name': 'Brian McCarthy', 'email': 'brian.mccarthy@mongodb.com', 'username': 'briananthonymccarthy'}Message: BUILD-13557 Windows vsCurrent should use Windows_Server-2019-English-Full-Base as source AMI |
| Comment by Eric Milkie [ 07/Mar/14 ] |
|
As of 2.2, capped collections have _id index by default. |
| Comment by Hitoshi Asai [ 20/Jan/12 ] |
|
Is this fixed by the following ticket? |
| Comment by Hitoshi Asai [ 26/Nov/11 ] |
|
I'm using mongod ver.2.0.1 I understood the _id index is effective for the performance of replication. |
| Comment by Dwight Merriman [ 26/Nov/11 ] |
|
generally, in the current versions, there is a need for an _id index on secondaries otherwise replication application will be very slow. perhaps if you have many collections and they are small it might be ok but generally it isn't. we are researching what is the best long term approach. if a few have _id i wonder if old version created the index and new versions don't, that is my first thought. unless you empirically see non-index is faster, i'd recommend having _id index on secondaries for now. |
| Comment by Hitoshi Asai [ 26/Nov/11 ] |
|
I also encountered this problem. There are 100000 or more capped collections with no index in PRIMARY. I need no indices. I need no more disk use. |
| Comment by Dwight Merriman [ 28/Oct/10 ] |
|
duplicates http://jira.mongodb.org/browse/SERVER-84 |
| Comment by Dwight Merriman [ 28/Oct/10 ] |
|
it would be unfortunate to lose the high speed. maybe there is another solution, like making the slaves not be too chatty on dup keys and keep going. |
| Comment by Dwight Merriman [ 28/Oct/10 ] |
|
workaround: (1) don't insert non-unique _ids |