[SERVER-14092] MongoDB upgrade 2.4 to 2.6 check returns error in internal collections Created: 30/May/14  Updated: 16/Nov/21  Resolved: 30/May/14

Status: Closed
Project: Core Server
Component/s: Internal Code
Affects Version/s: 2.6.1
Fix Version/s: 2.6.2, 2.7.2

Type: Bug Priority: Major - P3
Reporter: Sasa Skevin Assignee: Matt Dannenberg
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Completed:
Steps To Reproduce:

N/A

Participants:

 Description   

I have a replica set and wanted to upgrade MongoDB from version 2.4.5 to 2.6.1 and before replacing binaries have used this command: db.upgradeCheckAllDBs()

However this error returned:

...
Checking collection local.replset.minvalid
Document Error: document is no longer valid in 2.6 because DollarPrefixedFieldName: $set is not valid for storage.: {  "_id" : ObjectId("50101a875b51c70037b81c30"),  "ts" : Timestamp(1398232884, 51),  "h"
 : NumberLong("4590312020654652586"),  "op" : "u",  "ns" : "jumbo.jumboFile2Upload",  "o2" : {  "_id" : ObjectId("510b039031c82133929bd77f") },  "o" : {  "$set" : {  "operation" : {  "operation" : "upload
",  "total" : NumberLong(1048768),  "done" : NumberLong(671576) } } } }
...

To fix the problems above please consult http://dochub.mongodb.org/core/upgrade_checker_help
false

This error is in internal MongoDB collection (local.replset.minvalid). Mentioned link states:

To resolve, remove the document and re-insert with the appropriate corrections.

What does this local.replset.minvalid do? I do not feel comfortable updating internal MongoDB collections.

This collection local.replset.minvalid contains only one document:

set0:PRIMARY> db.replset.minvalid.findOne()
{
        "_id" : ObjectId("50101a875b51c70037b81c30"),
        "ts" : Timestamp(1398232884, 51),
        "h" : NumberLong("4590312020654652586"),
        "op" : "u",
        "ns" : "jumbo.jumboFile2Upload",
        "o2" : {
                "_id" : ObjectId("510b039031c82133929bd77f")
        },
        "o" : { 
                "$set" : {
                        "operation" : {
                                "operation" : "upload",
                                "total" : NumberLong(1048768),
                                "done" : NumberLong(671576)
                        }
                }
        }
}

Is this a bug? What should I do?



 Comments   
Comment by Githook User [ 30/May/14 ]

Author:

{u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}

Message: SERVER-14092 ignore local.replset.minvalid in upgradeChecker

(cherry picked from commit 79c5492d92e661e169d852c218ec393f31337db7)
Branch: v2.6
https://github.com/mongodb/mongo/commit/c73f7c12cde09575b11db1dba91d852c724d076c

Comment by Githook User [ 30/May/14 ]

Author:

{u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}

Message: SERVER-14092 ignore local.replset.minvalid in upgradeChecker
Branch: master
https://github.com/mongodb/mongo/commit/79c5492d92e661e169d852c218ec393f31337db7

Comment by Sasa Skevin [ 30/May/14 ]

Thank you. MongoDB upgraded to 2.6.1 and it works.
Sasa

Comment by Matt Dannenberg [ 30/May/14 ]

Hello Sasa,

Your intuition is correct. This is a bug. local.replset.minvalid is an internal collection and you should not modify it. You should ignore the message and proceed with your upgrade (assuming all other problems have been resolved).

Thanks for reporting this. A fix should appear in the next release,
Matt

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