Uploaded image for project: 'MongoDB Database Tools'
  1. MongoDB Database Tools
  2. TOOLS-1

mongooplog timeout not able to get cursor

    • Type: Icon: Bug Bug
    • Resolution: Incomplete
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: Legacy C++ Implementation
    • Component/s: mongooplog
    • Labels:
      None

      To reproduce:

      1) Start a replica set
      2) Pump in 50~60 millions of documents so we have plenty oplog entries.
      3) Start another replica set listening on port 27018
      4) Run mongooplog to migrate the oplog

      Expected:
      Command success, oplog is copied and applied on destination machine.

      Actual: Timeout getting oplog query:

      MacBook-Pro-13:data tjworks$ mongooplog --from localhost:27017 --host localhost:27018 -vvv
      2014-09-04T23:01:57.162+0800 creating new connection to:localhost:27018
      2014-09-04T23:01:57.162+0800 [ConnectBG] BackgroundJob starting: ConnectBG
      2014-09-04T23:01:57.163+0800 connected to server localhost:27018 (127.0.0.1)
      2014-09-04T23:01:57.163+0800 connected connection!
      connected to: localhost:27018
      2014-09-04T23:01:57.163+0800 going to connect
      2014-09-04T23:01:57.163+0800 [ConnectBG] BackgroundJob starting: ConnectBG
      2014-09-04T23:01:57.163+0800 [oplogreplay] connected to server localhost:27017 (127.0.0.1)
      2014-09-04T23:01:57.163+0800 connected
      2014-09-04T23:01:57.163+0800 starting from Sep 3 23:01:57:0
      2014-09-04T23:01:57.163+0800 [oplogreplay] repl: local.oplog.rs.find({ ts:

      { $gte: Timestamp 1409756517000|0 }

      })
      2014-09-04T23:02:27.166+0800 [oplogreplay] Socket recv() timeout 127.0.0.1:27017
      2014-09-04T23:02:27.169+0800 [oplogreplay] SocketException: remote: 127.0.0.1:27017 error: 9001 socket exception [RECV_TIMEOUT] server [127.0.0.1:27017]
      2014-09-04T23:02:27.169+0800 [oplogreplay] DBClientCursor::init call() failed
      2014-09-04T23:02:27.169+0800 [oplogreplay] User Assertion: 15910:Doesn't have cursor for reading oplog
      assertion: 15910 Doesn't have cursor for reading oplog
      MacBook-Pro-13:data tjworks$ mongo

      rs:PRIMARY> db.oplog.rs.stats()
      {
      "ns" : "local.oplog.rs",
      "count" : 46160528,
      "size" : 14990072156,
      "avgObjSize" : 324,
      "storageSize" : 15728643984,
      "numExtents" : 9,
      "nindexes" : 0,
      "lastExtentSize" : 4096,
      "paddingFactor" : 1,
      "systemFlags" : 0,
      "userFlags" : 0,
      "totalIndexSize" : 0,
      "indexSizes" : {

      },
      "capped" : true,
      "max" : NumberLong("9223372036854775807"),
      "ok" : 1
      }
      rs:PRIMARY> db.printReplicationInfo()
      configured oplog size: 15000MB
      log length start to end: 869784secs (241.61hrs)
      oplog first event time: Mon Aug 25 2014 21:27:54 GMT+0800 (HKT)
      oplog last event time: Thu Sep 04 2014 23:04:18 GMT+0800 (HKT)
      now: Thu Sep 04 2014 23:04:19 GMT+0800 (HKT)
      rs:PRIMARY>

            Assignee:
            mikeo@mongodb.com Michael O'Brien
            Reporter:
            jianfa.tang@mongodb.com Jianfa Tang (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: