[SERVER-32200] ISSUE: Wrong Document Count returning from MONGODBServer Created: 07/Dec/17 Updated: 07/Jan/18 Resolved: 08/Dec/17 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Index Maintenance, Querying |
| Affects Version/s: | 3.4.0 |
| Fix Version/s: | None |
| Type: | Question | Priority: | Major - P3 |
| Reporter: | Sandeep [X] | Assignee: | Mark Agarunov |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
| Participants: |
| Description |
|
Description: Issue we are facing: Note: In production, this collection can grow to have more documents (Billions of documents) Requesting you to Kindly address our below queries , How to Reproduce: 1.Create a collection say 'testCollection' with 5.5Million or more document with average document size of 1.5KiB )* |
| Comments |
| Comment by Sandeep [X] [ 14/Dec/17 ] |
|
Dear Mark, Please let us know in case new ticket needs to be opened here ... Thanks & Regards |
| Comment by Sandeep [X] [ 13/Dec/17 ] |
|
Dear Mark, Note: Thanks & Regards |
| Comment by Sandeep [X] [ 12/Dec/17 ] |
|
Dear Mark, Thank you for your inputs!!
Queries: Query2: We are not sure why other index which we created went to rejection Plan? Thanks & Regards |
| Comment by Mark Agarunov [ 08/Dec/17 ] |
|
Hello Urs, Thank you for the report. After looking over this, the incorrect counts may be due to previous unclean shutdowns. This can be fixed by running the validate command on the collection. Additional memory will likely improve performance. In addition to increasing the cache size, more memory would allow sorts to fit in memory and not have to be written to disk, causing a significant performance hit. Looking over the logs, it appears that the queries are not effectively using indexes, which is likely the cause of the long run times for these queries. Additionally, it appears that the Indexes that did exist for the table were dropped just before the queries started to get slower. In addition to using indexes for these queries, I would recommend upgrading MongoDB to at least the latest 3.4 release, as there have been many performance improvements in more recent versions, especially relating to the aggregation framework. As I do not see anything in the logs or diagnostic data to indicate a bug in MongoDB, I've closed this ticket. If additional information comes to light, or you are still seeing slow performance after upgrading and making sure the queries effectively use the index, please let us know and we can reopen the ticket. Thanks, |
| Comment by Sandeep [X] [ 08/Dec/17 ] |
|
Hello Mark, Thanks for your support, kindly find archived $dbpath/diagnostic.data directory & log.zip attached to this ticket. Thanks, |
| Comment by Mark Agarunov [ 07/Dec/17 ] |
|
Hello Urs, Thank you for the report. To get a better idea of why this may be happening, could you please provide the following:
This should give some insight into why the count is inaccurate and taking a long time. Thanks, |