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

mongoreplay: out of bounds error in "shortenreply" during record

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 3.4.1, 3.5.2
    • Affects Version/s: None
    • Component/s: mongoreplay
    • Labels:
      None
    • Platforms 2016-11-21
    • v3.4

      > sudo mongoreplay record -p /data/playback.bson -i em1
      panic: runtime error: slice bounds out of range
      
      goroutine 66 [running]:
      panic(0x8ad500, 0xc420010140)
      	/opt/go/src/runtime/panic.go:500 +0x1a1
      github.com/mongodb/mongo-tools/mongoreplay.(*RawOp).ShortenReply(0xc4232d25a0, 0xc421262240, 0xc42006df18)
      	/data/mci/7506acf77b1562807d9a828fda6d1667/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongoreplay/raw_op.go:69 +0xd9
      github.com/mongodb/mongo-tools/mongoreplay.Record.func1(0xc4212c8000, 0xc4212404c0, 0x7fffc6ac5900, 0xc4212404e0)
      	/data/mci/7506acf77b1562807d9a828fda6d1667/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongoreplay/record.go:158 +0x2e3
      created by github.com/mongodb/mongo-tools/mongoreplay.Record
      	/data/mci/7506acf77b1562807d9a828fda6d1667/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongoreplay/record.go:172 +0xa2
      
      Similar error recording playback from pcap -
      
      > sudo tcpdump -i em1 -n "port 27017" -w traffic.pcap
      > sudo mongoreplay record -f traffic.pcap -p playback.bson
      panic: runtime error: slice bounds out of range
      
      goroutine 57 [running]:
      panic(0x8b0140, 0xc420012100)
      	/opt/go/src/runtime/panic.go:500 +0x1a1
      github.com/mongodb/mongo-tools/mongoreplay.(*RawOp).ShortenReply(0xc4226af3b0, 0xc42125e300, 0xc4234edf18)
      	/data/mci/c1b6352e0693cc4dfaec9f2148876fca/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongoreplay/raw_op.go:69 +0xd9
      github.com/mongodb/mongo-tools/mongoreplay.Record.func1(0xc42125e540, 0xc4212524e0, 0x7ffe4e48c700, 0xc421252500)
      	/data/mci/c1b6352e0693cc4dfaec9f2148876fca/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongoreplay/record.go:158 +0x2e3
      created by github.com/mongodb/mongo-tools/mongoreplay.Record
      	/data/mci/c1b6352e0693cc4dfaec9f2148876fca/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongoreplay/record.go:172 +0xa2
      
      

            Assignee:
            gabriel.russell@mongodb.com Gabriel Russell (Inactive)
            Reporter:
            mikeo@mongodb.com Michael O'Brien
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: