Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.1.0
    • Component/s: moxi
    • Security Level: Public
    • Labels:
      None

      Description

      on osx, running dev build of moxi with...

      MallocScribbe=1 MallocGuardEdges=1 MallocStackLogging=1 MallocErrorAbort=1 ./moxi -Z port_listen=13001,usr=Administrator,pwd=111111,default_bucket_name=default,downstream_max=1024,downstream_conn_max=16,connect_max_errors=3,connect_retry_interval=30000,connect_timeout=400,auth_timeout=100,cycle=200,downstream_conn_queue_timeout=200,downstream_timeout=5000,wait_queue_timeout=200 -z url=http://127.0.0.1:9000/pools/default/saslBucketsStreaming -p 0 -Y y -O stderr

      and memcachetest of...

      ../memcachetest/memcachetest -h 127.0.0.1:13001 -i 1000 -c 10000 -l -t 30

      then leaks shows output of...

      Leak: 0x101a47000 size=6656 zone: DefaultMallocZone_0x1000f8000 string '?'
      Call stack: [thread 0x100504000]: | thread_start | _pthread_start | worker_libevent | event_base_loop | drive_machine | try_read_command | cproxy_process_upstream_ascii | cproxy_assign_downstream | cproxy_reserve_downstream | cproxy_add_downstream | cproxy_create_downstream | cproxy_copy_behaviors | calloc | malloc_zone_calloc
      Leak: 0x101a4ba00 size=6656 zone: DefaultMallocZone_0x1000f8000 string '?'
      Call stack: [thread 0x10060a000]: | thread_start | _pthread_start | worker_libevent | event_base_loop | drive_machine | cproxy_assign_downstream | cproxy_reserve_downstream | cproxy_add_downstream | cproxy_create_downstream | cproxy_copy_behaviors | calloc | malloc_zone_calloc
      Leak: 0x101a52400 size=6656 zone: DefaultMallocZone_0x1000f8000 string '?'
      Call stack: [thread 0x100587000]: | thread_start | _pthread_start | worker_libevent | event_base_loop | drive_machine | try_read_command | cproxy_process_upstream_ascii | cproxy_assign_downstream | cproxy_reserve_downstream | cproxy_add_downstream | cproxy_create_downstream | cproxy_copy_behaviors | calloc | malloc_zone_calloc
      Leak: 0x101a53e00 size=6656 zone: DefaultMallocZone_0x1000f8000 string '?'
      Call stack: [thread 0x100587000]: | thread_start | _pthread_start | worker_libevent | event_base_loop | drive_machine | try_read_command | cproxy_process_upstream_ascii | cproxy_assign_downstream | cproxy_reserve_downstream | cproxy_add_downstream | cproxy_create_downstream | cproxy_copy_behaviors | calloc | malloc_zone_calloc
      Leak: 0x100203c30 size=48 zone: DefaultMallocZone_0x1000f8000 string '127.0.0.1:12006:default:(null):0'
      Call stack: [thread 0x100504000]: | thread_start | _pthread_start | worker_libevent | event_base_loop | drive_machine | cproxy_assign_downstream | cproxy_forward | cproxy_forward_a2b_downstream | cproxy_connect_downstream | zstored_acquire_downstream_conn | strdup | malloc | malloc_zone_malloc
      Leak: 0x100203ca0 size=48 zone: DefaultMallocZone_0x1000f8000 string '127.0.0.1:12006:default:(null):0'
      Call stack: [thread 0x100504000]: | thread_start | _pthread_start | worker_libevent | event_base_loop | drive_machine | cproxy_assign_downstream | cproxy_forward | cproxy_forward_a2b_downstream | cproxy_connect_downstream | zstored_acquire_downstream_conn | strdup | malloc | malloc_zone_malloc

      [... many repeats of those host_ident/strdup and behaviors/calloc leaks ...]

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

        Activity

        Hide
        kpankonen Kevin Pankonen added a comment -

        I'm only seeing it after a rebalance

        Show
        kpankonen Kevin Pankonen added a comment - I'm only seeing it after a rebalance
        Hide
        paf Alexander Petrossian (PAF) added a comment -

        Kevin, thanks for the update.

        There is only one code-change in master branch since 1.8.1 tag, and that does NOT fix this problem.
        https://github.com/couchbase/moxi/tree/1.8.1
        https://github.com/couchbase/moxi/tree/master

        Maybe the secret lies in "EE" suffix that Xav mentions

        Show
        paf Alexander Petrossian (PAF) added a comment - Kevin, thanks for the update. There is only one code-change in master branch since 1.8.1 tag, and that does NOT fix this problem. https://github.com/couchbase/moxi/tree/1.8.1 https://github.com/couchbase/moxi/tree/master Maybe the secret lies in "EE" suffix that Xav mentions
        Hide
        paf Alexander Petrossian (PAF) added a comment -

        I referred to
        https://github.com/couchbase/moxi/commit/52ab68feea9cbd8d3b9d871f781294e8fc1ecee5

        bugfix. Other changes do not touch main code logic.

        Show
        paf Alexander Petrossian (PAF) added a comment - I referred to https://github.com/couchbase/moxi/commit/52ab68feea9cbd8d3b9d871f781294e8fc1ecee5 bugfix. Other changes do not touch main code logic.
        Hide
        steve Steve Yen added a comment - - edited

        Hi, that fix for https://github.com/couchbase/moxi/commit/52ab68feea9cbd8d3b9d871f781294e8fc1ecee5 was for a crashing bug instead of a memory leak.

        In between 1.8 and 2.x of couchbase, there was yet another memory leak fix awhile back in a library that moxi uses, called libvbucket... https://github.com/couchbase/libvbucket/commit/677e4037932150e4d39634be7d7a5b6e241b0022 That was also, I think, for a leak that happened only on reconfig messages. But, in 2.x of couchbase, reconfig messages can happen a lot more often than in 1.8.

        Show
        steve Steve Yen added a comment - - edited Hi, that fix for https://github.com/couchbase/moxi/commit/52ab68feea9cbd8d3b9d871f781294e8fc1ecee5 was for a crashing bug instead of a memory leak. In between 1.8 and 2.x of couchbase, there was yet another memory leak fix awhile back in a library that moxi uses, called libvbucket... https://github.com/couchbase/libvbucket/commit/677e4037932150e4d39634be7d7a5b6e241b0022 That was also, I think, for a leak that happened only on reconfig messages. But, in 2.x of couchbase, reconfig messages can happen a lot more often than in 1.8.
        Hide
        paf Alexander Petrossian (PAF) added a comment - - edited

        thanks a lot, Steve.
        I came across this discussion in MB-9677 and even found there some prebuilt binaries.
        I've installed them to our ref system and we'll test them next week.

        Will return in MB-9677 with info as soon as I'll have it.
        Thanks for this NY present, colleagues
        Maybe we'll all be superbusy in near future, in that case let me wish you all a Happy Christmas and NY!
        Alexander, Moscow, Russia

        P.S. we're very happy tu use such good product as CouchBase and all these small things in question, with God's help, will go away.
        Thanks a lot!

        Show
        paf Alexander Petrossian (PAF) added a comment - - edited thanks a lot, Steve. I came across this discussion in MB-9677 and even found there some prebuilt binaries. I've installed them to our ref system and we'll test them next week. Will return in MB-9677 with info as soon as I'll have it. Thanks for this NY present, colleagues Maybe we'll all be superbusy in near future, in that case let me wish you all a Happy Christmas and NY! Alexander, Moscow, Russia P.S. we're very happy tu use such good product as CouchBase and all these small things in question, with God's help, will go away. Thanks a lot!

          People

          • Assignee:
            dipti Dipti Borkar
            Reporter:
            steve Steve Yen
          • Votes:
            2 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Gerrit Reviews

              There are no open Gerrit changes