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

Server crashes upon shutdown after unsuccessful start with wrong innodb_page_size

    XMLWordPrintable

Details

    Description

      --source include/have_innodb.inc
       
      --let $restart_parameters= --innodb-page-size=32K --innodb-buffer-pool-size=32M
      --source include/restart_mysqld.inc
       
      select 1;
      

      On 10.1, it causes expected refusal to start:

      InnoDB: Error: Current page size 32768 !=  page size on page 16384
      2017-07-16 23:51:32 140669026166656 [Note] InnoDB: Restoring page 0 of tablespace 0
      2017-07-16 23:51:32 140669026166656 [Warning] InnoDB: Doublewrite does not have page_no=0 of space: 0
      2017-07-16 23:51:32 140669026166656 [ERROR] InnoDB: innodb-page-size mismatch in data file ./ibdata1
      2017-07-16 23:51:32 140669026166656 [ERROR] InnoDB: Could not open or create the system tablespace. If you tried to add new data files to the system tablespace, and it failed here, you should now edit innodb_data_file_path in my.cnf back to what it was, and remove the new ibdata files InnoDB created in this failed attempt. InnoDB only wrote those files full of zeros, but did not yet use them in any way. But be careful: do not remove old data files which contain your precious data!
      2017-07-16 23:51:32 140669026166656 [ERROR] Plugin 'InnoDB' init function returned error.
      2017-07-16 23:51:32 140669026166656 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
      

      However, on 10.2 and 10.3 after that the server aborts upon shutdown:

      2017-07-16 23:52:05 140554313041728 [ERROR] InnoDB: Data file './ibdata1' uses page size 16384, but the innodb_page_size start-up parameter is 32768
      2017-07-16 23:52:05 140554313041728 [ERROR] InnoDB: Corrupted page [page id: space=0, page number=0] of datafile './ibdata1' could not be found in the doublewrite buffer.
      2017-07-16 23:52:05 140554313041728 [ERROR] InnoDB: Plugin initialization aborted at srv0start.cc[1946] with error Generic error
      2017-07-16 23:52:05 140554313041728 [Note] InnoDB: Starting shutdown...
      170716 23:52:06 [ERROR] mysqld got signal 6 ;
       
      #5  0x00007fd55638c448 in __GI_abort () at abort.c:89
      #6  0x00007fd5563c91b4 in __libc_message (do_abort=do_abort@entry=1, fmt=fmt@entry=0x7fd5564be210 "*** Error in `%s': %s: 0x%s ***\n") at ../sysdeps/posix/libc_fatal.c:175
      #7  0x00007fd5563ce98e in malloc_printerr (action=1, str=0x7fd5564be238 "munmap_chunk(): invalid pointer", ptr=<optimized out>) at malloc.c:4996
      #8  0x00007fd5592c273c in LatchCounter::~LatchCounter (this=0x7fd55b6b5f48, __in_chrg=<optimized out>) at /data/src/10.2/storage/innobase/include/sync0types.h:598
      #9  0x00007fd5592c4332 in LatchMeta<LatchCounter>::~LatchMeta (this=0x7fd55b6b5f20, __in_chrg=<optimized out>) at /data/src/10.2/storage/innobase/include/sync0types.h:785
      #10 0x00007fd5592c232a in sync_latch_meta_destroy () at /data/src/10.2/storage/innobase/sync/sync0debug.cc:1608
      #11 0x00007fd5592c25c8 in sync_check_close () at /data/src/10.2/storage/innobase/sync/sync0debug.cc:1825
      #12 0x00007fd5592b1488 in innodb_shutdown () at /data/src/10.2/storage/innobase/srv/srv0start.cc:2937
      #13 0x00007fd5590efa98 in innobase_init (p=0x7fd55b6b30f0) at /data/src/10.2/storage/innobase/handler/ha_innodb.cc:4436
      #14 0x00007fd558eaa425 in ha_initialize_handlerton (plugin=0x7fd55b5c0278) at /data/src/10.2/sql/handler.cc:512
      #15 0x00007fd558c54c81 in plugin_initialize (tmp_root=0x7ffd0e2e3c80, plugin=0x7fd55b5c0278, argc=0x7fd55a17e730 <remaining_argc>, argv=0x7fd55b4791f0, options_only=false) at /data/src/10.2/sql/sql_plugin.cc:1413
      #16 0x00007fd558c5588a in plugin_init (argc=0x7fd55a17e730 <remaining_argc>, argv=0x7fd55b4791f0, flags=2) at /data/src/10.2/sql/sql_plugin.cc:1695
      #17 0x00007fd558b62322 in init_server_components () at /data/src/10.2/sql/mysqld.cc:5255
      #18 0x00007fd558b633a7 in mysqld_main (argc=146, argv=0x7fd55b4791f0) at /data/src/10.2/sql/mysqld.cc:5845
      #19 0x00007fd558b58280 in main (argc=24, argv=0x7ffd0e2e4a18) at /data/src/10.2/sql/main.cc:25
      

      Attachments

        Issue Links

          Activity

            People

              marko Marko Mäkelä
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.