Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-32220

Alice CLONE[MB-31479] - panic when replication stops because of nil error

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 6.0.1
    • 6.0.0
    • XDCR
    • Untriaged
    • Unknown

    Description

      Saw the following dump in logs in MB-31477. A nil error caused xdcr to panic.

      The code is in utils.ExponentialBackoffExecutorWithFinishSignal().

      err = fmt.Errorf("%v %v Last error: %v", name, base.ErrorFailedAfterRetry.Error(), err.Error())

       err.Error() would panic if err is nil.

      err is always not nil in normal execution path. err could be nil when the method exits due to timeout, though.

       

      2018-10-01T16:02:48.904-07:00 WARN GOXDCR.Utils: ExponentialBackoffExecutorWithFinishSignal for StatsMapOnVBToSeqno aborting because of finch closure
      2018-10-01T16:02:48.904-07:00 INFO GOXDCR.CheckpointMgr: Done one time checkpointing for replication 56588e1ffae793e05948c77a6e28360d/mem/rep-mem
      panic: runtime error: invalid memory address or nil pointer dereference
      [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7cbec9]

      goroutine 2028 [running]:
      github.com/couchbase/goxdcr/utils.(*Utilities).ExponentialBackoffExecutorWithFinishSignal(0xc42000e1a8, 0xa3ede2, 0x13, 0xbebc200, 0x5, 0x2, 0xc420abd3c0, 0x0, 0x0, 0xc42087efc0, ...)
      goproj/src/github.com/couchbase/goxdcr/utils/utils.go:2416 +0x419
      github.com/couchbase/goxdcr/pipeline_svc.(*CheckpointManager).getHighSeqnoAndVBUuidForServerWithRetry(0xc420175b00, 0xc420878800, 0x38, 0xc420423400, 0x200, 0x200, 0xc42024e000, 0xc42087efc0)
      goproj/src/github.com/couchbase/goxdcr/pipeline_svc/checkpoint_manager.go:445 +0x18c
      github.com/couchbase/goxdcr/pipeline_svc.(*CheckpointManager).getHighSeqnoAndVBUuidFromTarget(0xc420175b00, 0xc42087efc0, 0x0)
      goproj/src/github.com/couchbase/goxdcr/pipeline_svc/checkpoint_manager.go:407 +0x172
      github.com/couchbase/goxdcr/pipeline_svc.(*CheckpointManager).PerformCkpt(0xc420175b00, 0xc42087efc0)
      goproj/src/github.com/couchbase/goxdcr/pipeline_svc/checkpoint_manager.go:1020 +0x58d
      github.com/couchbase/goxdcr/pipeline_svc.(*CheckpointManager).CheckpointBeforeStop.func1(0xc420175b00, 0xc42087efc0, 0xc42087ef50)
      goproj/src/github.com/couchbase/goxdcr/pipeline_svc/checkpoint_manager.go:485 +0x35
      created by github.com/couchbase/goxdcr/pipeline_svc.(*CheckpointManager).CheckpointBeforeStop
      goproj/src/github.com/couchbase/goxdcr/pipeline_svc/checkpoint_manager.go:487 +0x216

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              pavithra.mahamani Pavithra Mahamani (Inactive)
              yu Yu Sui (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty