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

Crash in subselect

    XMLWordPrintable

Details

    • 10.1.15

    Description

      MariaDB (10.1.13 release) crashes with the following error:

      ...
      2016-05-04 12:55:45 9176 [Note] InnoDB: Online DDL : Completed
      2016-05-04 12:55:45 9176 [Note] InnoDB: Online DDL : Completed
      2016-05-04 12:55:45 9176 [Note] InnoDB: Online DDL : Completed
      2016-05-04 12:55:45 9176 [Note] InnoDB: Online DDL : Completed
      2016-05-04 12:55:45 9176 [Note] InnoDB: Online DDL : Completed
      2016-05-04 12:55:45 9176 [Note] InnoDB: Online DDL : Completed
      2016-05-04 12:55:45 9176 [Note] InnoDB: Online DDL : Completed
      160504 13:50:40 [ERROR] mysqld got exception 0xc0000005 ;
      This could be because you hit a bug. It is also possible that this binary
      or one of the libraries it was linked against is corrupt, improperly built,
      or misconfigured. This error can also be caused by malfunctioning hardware.
       
      To report this bug, see https://mariadb.com/kb/en/reporting-bugs
       
      We will try our best to scrape up some info that will hopefully help
      diagnose the problem, but since we have already crashed, 
      something is definitely wrong and this may fail.
       
      Server version: 10.1.13-MariaDB
      key_buffer_size=8388608
      read_buffer_size=65536
      max_used_connections=24
      max_threads=1001
      thread_count=14
      It is possible that mysqld could use up to 
      key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 333936 K  bytes of memory
      Hope that's ok; if not, decrease some variables in the equation.
       
      Thread pointer: 0x0x239e8338
      Attempting backtrace. You can use the following information to find out
      where mysqld died. If you see no messages after this, something went
      terribly wrong...
      mysqld.exe!Item_in_subselect::fix_fields()[item_subselect.cc:3159]
      mysqld.exe!Item_in_optimizer::fix_fields()[item_cmpfunc.cc:1345]
      mysqld.exe!setup_conds()[sql_base.cc:8625]
      mysqld.exe!mysql_prepare_delete()[sql_delete.cc:771]
      mysqld.exe!mysql_delete()[sql_delete.cc:275]
      mysqld.exe!mysql_execute_command()[sql_parse.cc:4092]
      mysqld.exe!sp_instr_stmt::exec_core()[sp_head.cc:3215]
      mysqld.exe!sp_lex_keeper::reset_lex_and_exec_core()[sp_head.cc:2979]
      mysqld.exe!sp_instr_stmt::execute()[sp_head.cc:3131]
      mysqld.exe!sp_head::execute()[sp_head.cc:1317]
      mysqld.exe!sp_head::execute_trigger()[sp_head.cc:1646]
      mysqld.exe!Table_triggers_list::process_triggers()[sql_trigger.cc:2177]
      mysqld.exe!mysql_delete()[sql_delete.cc:600]
      mysqld.exe!mysql_execute_command()[sql_parse.cc:4092]
      mysqld.exe!Prepared_statement::execute()[sql_prepare.cc:4269]
      mysqld.exe!Prepared_statement::execute_loop()[sql_prepare.cc:3901]
      mysqld.exe!mysqld_stmt_execute()[sql_prepare.cc:2979]
      mysqld.exe!dispatch_command()[sql_parse.cc:1431]
      mysqld.exe!do_command()[sql_parse.cc:1107]
      mysqld.exe!threadpool_process_request()[threadpool_common.cc:239]
      mysqld.exe!io_completion_callback()[threadpool_win.cc:568]
      kernel32.dll!BaseFormatTimeOut()
      ntdll.dll!RtlEqualDomainName()
      ntdll.dll!RtlValidateHeap()
      kernel32.dll!BaseThreadInitThunk()
      ntdll.dll!RtlUserThreadStart()
       
      Trying to get some variables.
      Some pointers may be invalid and cause the dump to abort.
      Query (0x2542c570): DELETE FROM feature 
          WHERE  id IN (SELECT * 
                  FROM   (SELECT f.id 
                      FROM   feature f 
                         LEFT JOIN compound c 
                            ON f.id = c.feature_id 
                      WHERE  f.id = old.feature_id 
                         AND c.id IS NULL) AS temp)
      Connection ID (thread ID): 782
      Status: NOT_KILLED
       
      Optimizer switch: index_merge=on,index_merge_union=on,index_merge_sort_union=on,index_merge_intersection=on,index_merge_sort_intersection=off,engine_condition_pushdown=off,index_condition_pushdown=on,derived_merge=on,derived_with_keys=on,firstmatch=on,loosescan=on,materialization=on,in_to_exists=on,semijoin=on,partial_match_rowid_merge=on,partial_match_table_scan=on,subquery_cache=on,mrr=off,mrr_cost_based=off,mrr_sort_keys=off,outer_join_with_cache=on,semijoin_with_cache=on,join_cache_incremental=on,join_cache_hashed=on,join_cache_bka=on,optimize_join_buffer_size=off,table_elimination=on,extended_keys=on,exists_to_in=on
      ...
      

      This issue appears randomly during normal use.

      Hint:
      From the error you can see that it's an access violation (0xc0000005) exception.
      Moreover, item_subselect.cc:3159 was char const *save_where= thd->where at the time.
      So, you one can deduce, that 'thd' is an invalid pointer.

      Attachments

        1. create_table.sql
          6 kB
        2. index.txt
          1 kB
        3. my.ini
          0.9 kB
        4. trigger.txt
          24 kB

        Issue Links

          Activity

            People

              sanja Oleksandr Byelkin
              cskristof Csonkás Kristóf
              Votes:
              1 Vote for this issue
              Watchers:
              7 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.