diff --git a/common/intents/intent.go b/common/intents/intent.go index 47227950..4b82567e 100644 --- a/common/intents/intent.go +++ b/common/intents/intent.go @@ -119,7 +119,8 @@ func (it *Intent) IsSystemProfile() bool { } func (intent *Intent) IsSpecialCollection() bool { - return intent.IsSystemIndexes() || intent.IsUsers() || intent.IsRoles() || intent.IsAuthVersion() || intent.IsSystemProfile() || intent.IsOplog() + // can't see oplog as special collection because when restore from archive it need to be a RegularCollectionReceiver + return intent.IsSystemIndexes() || intent.IsUsers() || intent.IsRoles() || intent.IsAuthVersion() || intent.IsSystemProfile() } func (it *Intent) IsView() bool { diff --git a/mongodump/mongodump.go b/mongodump/mongodump.go index 3d2f6ade..a9122fa8 100644 --- a/mongodump/mongodump.go +++ b/mongodump/mongodump.go @@ -541,7 +541,7 @@ func (dump *MongoDump) DumpIntent(intent *intents.Intent, buffer resettableOutpu case dump.OutputOptions.ViewsAsCollections: // views have an implied aggregation which does not support snapshot fallthrough - case dump.InputOptions.TableScan || intent.IsSpecialCollection(): + case dump.InputOptions.TableScan || intent.IsSpecialCollection() || intent.IsOplog(): // ---forceTablesScan runs the query without snapshot enabled // The system.profile collection has no index on _id so can't be hinted. findQuery = session.DB(intent.DB).C(intent.C).Find(nil)