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

mongorestore panic: send on closed channel

    • Type: Icon: Bug Bug
    • Resolution: Unresolved
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: 3.4.6
    • Component/s: None
    • Labels:
      None
    • Environment:
    • 2
    • 1,668

      09:25:30 panic: send on closed channel
      09:25:30 
      09:25:30 goroutine 69 [running]:
      09:25:30 panic(0x7fe280, 0xc428b76c70)
      09:25:30     /opt/go/src/runtime/panic.go:500 +0x1a1
      09:25:30 github.com/mongodb/mongo-tools/common/archive.(*RegularCollectionReceiver).Write(0xc420126aa0, 0xc42024c010, 0x158, 0x1000000, 0xc42023f4b8, 0x1, 0x0)
      09:25:30     /data/mci/16ab06c320e36ab8cd6949542a8c0e59/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/common/archive/demultiplexer.go:337 +0x121
      09:25:30 github.com/mongodb/mongo-tools/common/archive.(*Demultiplexer).BodyBSON(0xc42427c000, 0xc42024c010, 0x158, 0x1000000, 0x0, 0x0)
      09:25:30     /data/mci/16ab06c320e36ab8cd6949542a8c0e59/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/common/archive/demultiplexer.go:208 +0x1d2
      09:25:30 github.com/mongodb/mongo-tools/common/archive.(*Parser).ReadBlock(0xc42024c000, 0xf0ff60, 0xc42427c000, 0x0, 0x0)
      09:25:30     /data/mci/16ab06c320e36ab8cd6949542a8c0e59/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/common/archive/parser.go:141 +0x166
      09:25:30 github.com/mongodb/mongo-tools/common/archive.(*Parser).ReadAllBlocks(0xc42024c000, 0xf0ff60, 0xc42427c000, 0x0, 0x0)
      09:25:30     /data/mci/16ab06c320e36ab8cd6949542a8c0e59/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/common/archive/parser.go:105 +0x57
      09:25:30 github.com/mongodb/mongo-tools/common/archive.(*Demultiplexer).Run(0xc42427c000, 0x43acb8, 0xb6d3b8)
      09:25:30     /data/mci/16ab06c320e36ab8cd6949542a8c0e59/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/common/archive/demultiplexer.go:61 +0xd9
      09:25:30 github.com/mongodb/mongo-tools/mongorestore.(*MongoRestore).Restore.func1(0xc42010a7f0, 0xc4201204e0, 0xc4201a8840)
      09:25:30     /data/mci/16ab06c320e36ab8cd6949542a8c0e59/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongorestore/mongorestore.go:399 +0x36
      09:25:30 created by github.com/mongodb/mongo-tools/mongorestore.(*MongoRestore).Restore
      09:25:30     /data/mci/16ab06c320e36ab8cd6949542a8c0e59/src/src/mongo/gotools/.gopath/src/github.com/mongodb/mongo-tools/mongorestore/mongorestore.go:401 +0xc79
      
      

      -------

      mongorestore --stopOnError \
                   --host ${HOST} \
                   --port 27017 \
                   --username ${USERNAME} \
                   --password ${PASSWORD} \
                   --drop \
                   --ssl \
                   --sslCAFile ${sslCAFile} \
                   --numParallelCollections 8 \
                   --numInsertionWorkersPerCollection 8 \
                   --authenticationDatabase admin \
                   --gzip \
                   --nsInclude ${INCLUSIONS} \
                   --nsInclude ${EXCLUSIONS} \
                   --nsTo '${TO_DB}.$collection$' \
                   --nsFrom '$db$.$collection$' \
                   --archive=${ARCHIVE_NAME}
      

      Starting happening when we started using restoring from compressed files directly.

        1. dump_server_3.2.17.json
          1 kB
        2. restore_server_3.2.9_error.json
          1 kB
        3. restore_server_3.4.6_success.json
          2 kB

            Assignee:
            Unassigned Unassigned
            Reporter:
            james@blendlabs.com James Yang
            Votes:
            3 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated: