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

cbstats exits with return code 0 for all conditions

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 4.0.0
    • 3.0.3
    • tools
    • Security Level: Public
    • None
    • CB: 3.0.3-1716-rel
    • Untriaged
    • Ubuntu 64-bit
    • Unknown

    Description

      cbstats will exit with zero status even when there are serious problems. It seems like having sys.exit(1) in some spots where there is currently only a sys.exit() might help?

      Example:

      [cb1]$ /opt/couchbase/bin/cbstats cb2.local:11210 all ; echo $?
       accepting_conns:                    1
       auth_cmds:                          0
       ...
      0
      

      Then stop cb2:

      [cb2]$ sudo service couchbase-server stop
      

      and try again:

      [cb1]$ /opt/couchbase/bin/cbstats cb2.local:11210 all ; echo $?
      Stats '' are not available from the requested engine. ([Errno 32] Broken pipe)
      0
      

      The expectation is that there be a non-zero result code in cases like the above example.

      Thanks!

      Attachments

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

        Activity

          People

            mikew Mike Wiederhold [X] (Inactive)
            bshumate Brian Shumate (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty