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

Inserting or append/prepend to a memcache bucket crashes moxi

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • 4.0.0
    • 3.0.1
    • moxi
    • Security Level: Public
    • None
    • Untriaged
    • Ubuntu 64-bit
    • Unknown

    Description

      When doing a set() with a value larger than 1MB to a memcache bucket, moxi crashes and responds with MEMCACHED_WRITE_FAILURE on all following requests.

      A restart of the Couchbase server is needed to get up and running again.

      This can be avoided by checking the size of the value before doing a set() to Couchbase, but that is not viable when doing append/prepend, as you do not know the size of the current value. I.e if you do a 10kb append() to a key that already holds 999kb of data, the same crash happens.

      When doing the same against standard memcache, the server responds with a MEMCACHED_NOTSTORED without crashing, as expected.

      Use the following PHP-code to reproduce:

      $m = new Memcached();
      $m->addServer('localhost', 11211);
      $m->set('key', str_repeat('x', 1049000));

      Run it a couple of times and moxi will start responding with MEMCACHED_WRITE_FAILURE even if you try to set small keys.

      Test the append() issue with this code:

      $m = new Memcached();
      $m->addServer('localhost', 11211);
      $m->set('key', str_repeat('x', 1048000));
      $m->append('key', str_repeat('y', 20000));

      Attachments

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

        Activity

          People

            steve Steve Yen
            buzzy Daniele Testa
            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