Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-8156

Assertion failure in file log0crypt.cc line 220 on server restart

    XMLWordPrintable

    Details

    • Sprint:
      10.1.6-1

      Description

      If the server was previously started with InnoDB log encryption, restarting the server without the encryption plugin causes the assertion failure as below. On a release build, there is no assertion failure, but a crash with SIGABRT.

      I realize it cannot really work without the plugin on encrypted logs, and expect it to abort, but it would be good to have clear diagnostics for this rather than the scary crash.

      Also, I thought it might work with innodb_fast_shutdown turned off, but it doesn't make a difference.

      150513  3:32:01 [ERROR] InnoDB: Redo log crypto: getting mysqld crypto key from key version failed.
      2015-05-13 03:32:01 7f4331ff6760  InnoDB: Assertion failure in thread 139926578358112 in file log0crypt.cc line 220
      InnoDB: We intentionally generate a memory trap.

      Stack trace from 10.1 commit c8ad5b2f

      #5  0x00007f432fbd33e0 in *__GI_abort () at abort.c:92
      #6  0x00007f4332962742 in init_crypt_key (info=0x7ffce3e6e010) at 10.1/storage/xtradb/log/log0crypt.cc:220
      #7  0x00007f4332962884 in add_crypt_info (info=0x7ffce3e6e010) at 10.1/storage/xtradb/log/log0crypt.cc:254
      #8  0x00007f4332962fa3 in log_crypt_read_checkpoint_buf (buf=0x7f432f015b36 "") at 10.1/storage/xtradb/log/log0crypt.cc:474
      #9  0x00007f433295bcfb in recv_find_max_checkpoint (max_group=0x7ffce3e6eb58, max_field=0x7ffce3e6eb60) at 10.1/storage/xtradb/log/log0recv.cc:813
      #10 0x00007f433295fbac in recv_recovery_from_checkpoint_start_func (type=78656949, limit_lsn=18446744073709551615, min_flushed_lsn=1616911, max_flushed_lsn=1616911) at 10.1/storage/xtradb/log/log0recv.cc:3162
      #11 0x00007f4332a411dc in innobase_start_or_create_for_mysql () at 10.1/storage/xtradb/srv/srv0start.cc:2528
      #12 0x00007f43328d87fa in innobase_init (p=0x7f432f02e270) at 10.1/storage/xtradb/handler/ha_innodb.cc:4083
      #13 0x00007f433272c2f0 in ha_initialize_handlerton (plugin=0x7f432f1446e8) at 10.1/sql/handler.cc:512
      #14 0x00007f4332513fa8 in plugin_initialize (tmp_root=0x7ffce3e728e0, plugin=0x7f432f1446e8, argc=0x7f43337f59d0, argv=0x7f432f01e6c0, options_only=false) at 10.1/sql/sql_plugin.cc:1403
      #15 0x00007f4332514b7a in plugin_init (argc=0x7f43337f59d0, argv=0x7f432f01e6c0, flags=2) at 10.1/sql/sql_plugin.cc:1676
      #16 0x00007f43324363e7 in init_server_components () at 10.1/sql/mysqld.cc:5041
      #17 0x00007f4332437528 in mysqld_main (argc=12, argv=0x7f432f01e6c0) at 10.1/sql/mysqld.cc:5631
      #18 0x00007f433242d100 in main (argc=11, argv=0x7ffce3e73628) at 10.1/sql/main.cc:25

      To reproduce:

      • start server with

        [mysqld]
        plugin-load-add=file_key_management.so
        loose-file_key_management_filename=/home/elenst/git/10.1/mysql-test/std_data/keys.txt
        innodb-encrypt-log=on

      • shut down the server
      • start the server without the options above.

        Attachments

          Activity

            People

            Assignee:
            jplindst Jan Lindström
            Reporter:
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: