-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 2.6.0-rc0
-
Component/s: None
-
None
-
Fully Compatible
-
ALL
to reproduce:
start a 2.4 mongod (source), insert a bunch of users with addUser.
start a 2.6 mongod (target), insert one test user with createUser.
shut down both mongod's.
dump the source database using mongodump --dbpath <source dbpath>.
restore it into the target database using mongorestore-2.6 --dbpath <target dbpath>.
It will print this error and then exit, which seems fine/normal:
Restoring to admin.system.users without dropping. Restored data will be inserted without raising errors; check your server log Server has authorization schema version 3, but found a schema version 1 user: { _id: ObjectId('530e5146c7fc46d67a0beab8'), user: "user", pwd: "58a5ef6a66ff3b073530259153e94ae2", roles: [ "readWriteAnyDatabase" ] }
However, after exiting, a non-empty mongod.lock file is left behind by mongorestore.
When trying to start the target mongod again, it fails:
m50102| ************** m50102| old lock file: /data/db/mongod-50102/mongod.lock. probably means unclean shutdown, m50102| but there are no journal files to recover. m50102| this is likely human error or filesystem corruption. m50102| please make sure that your journal directory is mounted. m50102| found 2 dbs. m50102| see: http://dochub.mongodb.org/core/repair for more information m50102| *************