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

Update w/ sub-query causes signal 11 crash

    XMLWordPrintable

    Details

      Description

      When executing an update involving a sub-query the database crashes. Commenting out the last sub-query in the update will allow the query to execute (although not with the right results). The crash is consistent and can be recreated.

      UPDATE dcs.dcs_item di
      SET di.current_level =
      (SELECT dsd.status_code
      FROM dcs.dcs_status_definition dsd
      WHERE dsd.description = 'Deployed To QA')
      WHERE di.current_level =
      (SELECT dsd.status_code
      FROM dcs.dcs_status_definition dsd
      WHERE dsd.description = 'HOLD')
      AND di.change_request_id IN
      (SELECT r.id
      FROM requests.requests r,
      requests.release re,
      requests.datacenter dc
      WHERE r.release_id = re.release_id
      AND re.datacenter_id = dc.datacenter_id
      AND dc.datacenter_id = 2
      AND re.automated_build = 1);

      Version: '5.5.56-MariaDB' socket: '/var/lib/mysql/mysql.sock' port: 3306 MariaDB Server
      180521 9:33:57 [ERROR] mysqld got signal 11 ;
      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 http://kb.askmonty.org/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: 5.5.56-MariaDB
      key_buffer_size=536870912
      read_buffer_size=131072
      max_used_connections=7
      max_threads=153
      thread_count=1
      It is possible that mysqld could use up to
      key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 859927 K bytes of memory
      Hope that's ok; if not, decrease some variables in the equation.

      Thread pointer: 0x56256bd77c90
      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...
      stack_bottom = 0x7f2e20220dc0 thread_stack 0x48000
      /usr/libexec/mysqld(my_print_stacktrace+0x3d)[0x5625691d496d]
      /usr/libexec/mysqld(handle_fatal_signal+0x515)[0x562568dea285]
      /lib64/libpthread.so.0(+0xf5e0)[0x7f2e246be5e0]
      /usr/libexec/mysqld(+0x396724)[0x562568cde724]
      /usr/libexec/mysqld(_Z20get_best_combinationP4JOIN+0x35b)[0x562568ce4dcb]
      /usr/libexec/mysqld(+0x3b73b3)[0x562568cff3b3]
      /usr/libexec/mysqld(_ZN4JOIN8optimizeEv+0x675)[0x562568d02625]
      /usr/libexec/mysqld(_ZN13st_select_lex31optimize_unflattened_subqueriesEb+0xc8)[0x562568cb1b18]
      /usr/libexec/mysqld(Z12mysql_updateP3THDP10TABLE_LISTR4ListI4ItemES6_PS4_jP8st_ordery15enum_duplicatesbPySB+0x3f9)[0x562568d43359]
      /usr/libexec/mysqld(_Z21mysql_execute_commandP3THD+0x2de5)[0x562568cbc815]
      /usr/libexec/mysqld(_Z11mysql_parseP3THDPcjP12Parser_state+0x125)[0x562568cc08c5]
      /usr/libexec/mysqld(_Z16dispatch_command19enum_server_commandP3THDPcj+0x1753)[0x562568cc2923]
      /usr/libexec/mysqld(_Z24do_handle_one_connectionP3THD+0x1c2)[0x562568d74632]
      /usr/libexec/mysqld(handle_one_connection+0x4a)[0x562568d746da]
      /lib64/libpthread.so.0(+0x7e25)[0x7f2e246b6e25]
      /lib64/libc.so.6(clone+0x6d)[0x7f2e22eb434d]

      Trying to get some variables.
      Some pointers may be invalid and cause the dump to abort.
      Query (0x7f2dc80eec98): UPDATE dcs.dcs_item di SET di.current_level = (SELECT dsd.status_code FROM dcs.dcs_status_definition dsd WHERE dsd.description = 'Deployed To QA') WHERE di.current_level = (SELECT dsd.status_code FROM dcs.dcs_status_definition dsd WHERE dsd.description = 'HOLD') AND di.change_request_id IN (SELECT r.id FROM requests.requests r, requests.release re, requests.datacenter dc WHERE r.release_id = re.release_id AND re.datacenter_id = dc.datacenter_id AND dc.datacenter_id = 2 AND re.automated_build = 1)
      Connection ID (thread ID): 58294
      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=off

      The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
      information that should help you find out what is causing the crash.
      180521 09:33:57 mysqld_safe Number of processes running now: 0
      180521 09:33:57 mysqld_safe mysqld restarted
      180521 9:33:57 [Note] /usr/libexec/mysqld (mysqld 5.5.56-MariaDB) starting as process 38127 ...
      180521 9:33:57 InnoDB: The InnoDB memory heap is disabled
      180521 9:33:57 InnoDB: Mutexes and rw_locks use GCC atomic builtins
      180521 9:33:57 InnoDB: Compressed tables use zlib 1.2.7
      180521 9:33:57 InnoDB: Using Linux native AIO
      180521 9:33:57 InnoDB: Initializing buffer pool, size = 128.0M
      180521 9:33:57 InnoDB: Completed initialization of buffer pool
      180521 9:33:57 InnoDB: highest supported file format is Barracuda.
      InnoDB: The log sequence number in ibdata files does not match
      InnoDB: the log sequence number in the ib_logfiles!
      InnoDB: Restoring possible half-written data pages from the doublewrite buffer...
      180521 9:33:57 InnoDB: Waiting for the background threads to start
      180521 9:33:58 Percona XtraDB (http://www.percona.com) 5.5.52-MariaDB-38.3 started; log sequence number 167870375
      180521 9:33:59 [Note] Plugin 'FEEDBACK' is disabled.
      180521 9:33:59 [Note] Server socket created on IP: '0.0.0.0'.
      180521 9:33:59 [Note] Event Scheduler: Loaded 0 events
      180521 9:33:59 [Note] /usr/libexec/mysqld: ready for connections.
      Version: '5.5.56-MariaDB' socket: '/var/lib/mysql/mysql.sock' port: 3306 MariaDB Server

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              kseymour Kevin Seymour
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:

                  Git Integration

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