Hi all. I have replica set set up as one shard in a cluster, and over
the weekend the primary went down and the secondary took over as
primary. I've been trying to bring a new box up to act as the
primary, and the initial sync has failed at least 3-4 times.
It copies over the initial data (takes about 12 hours), and then
begins applying the oplog, and each time I get this in the logs:
Tue Nov 1 17:37:57 [rsSync] build index done 54628 records 0.294 secs
Tue Nov 1 17:37:57 [rsSync] replSet initial sync cloning db: config
Tue Nov 1 17:37:57 [rsSync] replSet initial sync query minValid
Tue Nov 1 17:38:04 [rsSync] replSet initial oplog application from
mongobackup.cloudsmtp.com:27018 starting at Nov 1 07:11:22:8 to Nov
1 17:37:57:d7
Tue Nov 1 17:38:04 [rsSync] replSet info adding missing object
Tue Nov 1 17:38:04 [rsSync] Assertion failure !e.eoo() db/
repl/../../bson/bsonobjbuilder.h 120
0x57eeb6 0x589d6b 0x827cbe 0x82bbc1 0x82da98 0x823168 0x82439a
0x824820 0xaa4560 0x7f57856639ca 0x7f5784c1270d
mongod(_ZN5mongo12sayDbContextEPKc+0x96) [0x57eeb6]
mongod(_ZN5mongo8assertedEPKcS1_j+0xfb) [0x589d6b]
mongod(_ZN5mongo11ReplSetImpl27initialSyncOplogApplicationEPKNS_6MemberENS_6OpTimeES4_
+0x341e) [0x827cbe]
mongod(_ZN5mongo11ReplSetImpl18_syncDoInitialSyncEv+0x1261)
[0x82bbc1]
mongod(_ZN5mongo11ReplSetImpl17syncDoInitialSyncEv+0x28) [0x82da98]
mongod(_ZN5mongo11ReplSetImpl11_syncThreadEv+0x58) [0x823168]
mongod(_ZN5mongo11ReplSetImpl10syncThreadEv+0x4a) [0x82439a]
mongod(_ZN5mongo15startSyncThreadEv+0xa0) [0x824820]
mongod(thread_proxy+0x80) [0xaa4560]
/lib/libpthread.so.0(+0x69ca) [0x7f57856639ca]
/lib/libc.so.6(clone+0x6d) [0x7f5784c1270d]
Tue Nov 1 17:38:04 [rsSync] replSet initial sync failing, error
applying oplog 0 assertion db/repl/../../bson/bsonobjbuilder.h:120
Tue Nov 1 17:38:04 [rsSync] replSet initial sync failed during
applyoplog
Tue Nov 1 17:38:04 [rsSync] replSet cleaning up [1]
Tue Nov 1 17:38:04 [rsSync] replSet cleaning up [2]
Tue Nov 1 17:38:10 [rsSync] replSet initial sync pending
Tue Nov 1 17:38:10 [rsSync] replSet syncing to:
mongobackup.cloudsmtp.com:27018
Tue Nov 1 17:38:10 [rsSync] replSet initial sync drop all databases
Tue Nov 1 17:38:10 [rsSync] dropAllDatabasesExceptLocal 71
It then begins the sync all over again. How can I add a new member to
this replica set? Anything I can do to further debug the problem?