Uploaded image for project: 'Percona XtraDB Cluster'
  1. Percona XtraDB Cluster
  2. PXC-1017

LP #1376727: Memcached access to InnoDB is not replicated by Galera

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Pending Release
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 5.7.21-29.26, 5.6.39-26.25
    • Fix Version/s: 5.6.41, 5.7.23
    • Component/s: None
    • Security Level: Public Bug

      Description

      **Reported in Launchpad by Przemek last update 09-06-2016 14:14:56

      Even if daemon_memcached_enable_binlog is enabled, inserts to InnoDB via memcached plugin are not replicated in cluster.

      percona11 mysql> select @@version,@@version_comment;
      ---------------------------------------------------------------------------------------------------------------------+

      @@version @@version_comment

      ---------------------------------------------------------------------------------------------------------------------+

      5.6.20-68.0-56-log Percona XtraDB Cluster (GPL), Release rel68.0, Revision 888, WSREP version 25.7, wsrep_25.7.r4126

      ---------------------------------------------------------------------------------------------------------------------+
      1 row in set (0.00 sec)

      percona11 mysql> ! netstat -lpn|grep 11211
      tcp 0 0 0.0.0.0:11211 0.0.0.0:* LISTEN 3911/mysqld
      tcp 0 0 :::11211 :::* LISTEN 3911/mysqld
      udp 0 0 0.0.0.0:11211 0.0.0.0:* 3911/mysqld
      udp 0 0 :::11211 :::* 3911/mysqld

      percona11 mysql> show variables like '%memc%';
      --------------------------------------------------+

      Variable_name Value

      --------------------------------------------------+

      daemon_memcached_enable_binlog ON
      daemon_memcached_engine_lib_name innodb_engine.so
      daemon_memcached_engine_lib_path  
      daemon_memcached_option  
      daemon_memcached_r_batch_size 1
      daemon_memcached_w_batch_size 1

      --------------------------------------------------+
      6 rows in set (0.00 sec)

      percona11 mysql> select @@log_slave_updates;
      ---------------------

      @@log_slave_updates

      ---------------------

      1

      ---------------------
      1 row in set (0.00 sec)

      [root@percona11 ~]# telnet 127.0.0.1 11211
      Trying 127.0.0.1...
      Connected to 127.0.0.1.
      Escape character is '^]'.
      set a12 10 0 9
      123456789
      STORED
      set a11 10 0 9
      123456789
      STORED
      get a11
      VALUE a11 10 9
      123456789
      END
      quit
      Connection closed by foreign host.

      percona11 mysql> select * from test.demo_test;
      --------------------------

      c1 c2 c3 c4 c5

      --------------------------

      a11 123456789 10 5 0
      a12 123456789 10 4 0

      --------------------------
      2 rows in set (0.00 sec)

      percona22 mysql> select * from test.demo_test;
      Empty set (0.00 sec)

      percona11 mysql> show binlog events in 'percona11-bin.000006';
      ---------------------------------------------------------------------------------------------------------------------------------------------+

      Log_name Pos Event_type Server_id End_log_pos Info

      ---------------------------------------------------------------------------------------------------------------------------------------------+

      percona11-bin.000006 4 Format_desc 1 120 Server ver: 5.6.20-68.0-56-log, Binlog ver: 4
      percona11-bin.000006 120 Previous_gtids 1 231 02ada5a1-426c-11e4-a2c9-080027079e3d:1-5,
      3c4dfc5e-cbca-ee1b-55bb-69faa881cdcf:1-2
      percona11-bin.000006 231 Gtid 1 279 SET @@SESSION.GTID_NEXT= '02ada5a1-426c-11e4-a2c9-080027079e3d:6'
      percona11-bin.000006 279 Query 1 352 BEGIN
      percona11-bin.000006 352 Table_map 1 412 table_id: 70 (test.demo_test)
      percona11-bin.000006 412 Write_rows 1 479 table_id: 70 flags: STMT_END_F
      percona11-bin.000006 479 Query 1 553 COMMIT
      percona11-bin.000006 553 Gtid 1 601 SET @@SESSION.GTID_NEXT= '02ada5a1-426c-11e4-a2c9-080027079e3d:7'
      percona11-bin.000006 601 Query 1 674 BEGIN
      percona11-bin.000006 674 Table_map 1 734 table_id: 70 (test.demo_test)
      percona11-bin.000006 734 Update_rows 1 834 table_id: 70 flags: STMT_END_F
      percona11-bin.000006 834 Query 1 908 COMMIT

      ---------------------------------------------------------------------------------------------------------------------------------------------+
      12 rows in set (0.00 sec)

      BEGIN
      /!/;

      1. at 352
        #700101 0:00:00 server id 1 end_log_pos 412 CRC32 0x1f2310e4 Table_map: `test`.`demo_test` mapped to number 70
      2. at 412
        #700101 0:00:00 server id 1 end_log_pos 479 CRC32 0xd4f9081e Write_rows: table id 70 flags: STMT_END_F
          1. INSERT INTO `test`.`demo_test`
          2. SET
          3. @1='a12'
          4. @2='123456789'
          5. @3=10
          6. @4=4
          7. @5=0
      3. at 479
        #700101 0:00:00 server id 1 end_log_pos 553 CRC32 0x42eeace6 Query thread_id=8 exec_time=1412253454 error_code=0
        SET TIMESTAMP=0/!/;
        COMMIT
        /!/;
      4. at 553
        #700101 0:00:00 server id 1 end_log_pos 601 CRC32 0x75b717ee GTID [commit=yes]
        SET @@SESSION.GTID_NEXT= '02ada5a1-426c-11e4-a2c9-080027079e3d:7'/!/;
      5. at 601
        #700101 0:00:00 server id 1 end_log_pos 674 CRC32 0x98313ae1 Query thread_id=8 exec_time=1412253477 error_code=0
        SET TIMESTAMP=0/!/;
        BEGIN
        /!/;
      6. at 674
        #700101 0:00:00 server id 1 end_log_pos 734 CRC32 0x6cc9947a Table_map: `test`.`demo_test` mapped to number 70
      7. at 734
        #700101 0:00:00 server id 1 end_log_pos 834 CRC32 0xb41784df Update_rows: table id 70 flags: STMT_END_F
          1. UPDATE `test`.`demo_test`
          2. WHERE
          3. @1='a11'
          4. @2='5535\x0d\x0a535'
          5. @3=10
          6. @4=3
          7. @5=0
          8. SET
          9. @1='a11'
          10. @2='123456789'
          11. @3=10
          12. @4=5
          13. @5=0
      8. at 834
        #700101 0:00:00 server id 1 end_log_pos 908 CRC32 0x615a7623 Query thread_id=8 exec_time=1412253477 error_code=0
        SET TIMESTAMP=0/!/;
        COMMIT

        Attachments

          Activity

            People

            • Assignee:
              kenn.takara Kenn Takara
              Reporter:
              lpjirasync lpjirasync (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 4 days, 7 hours
                4d 7h