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

CREATE VIEW containing WITH clause Signal 11

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Critical
    • Resolution: Fixed
    • 10.3.17, 10.4.12, 10.2(EOL), 10.3(EOL), 10.4(EOL), 10.5
    • 10.2.37, 10.3.28, 10.4.18, 10.5.9
    • Optimizer - CTE
    • None
    • Reproducible on OpenSUSE Tumbleweed (10.4.12) and CentOS 8.1.1911 (Core) (10.3.17)

    Description

      Attempting to create a view with a WITH clause crashes every time.

      Steps to reproduce:

       
      MariaDB [(none)]> CREATE TABLE test.tbl1 ( f CHAR(1));
      Query OK, 0 rows affected (0.019 sec)
       
      MariaDB [(none)]> CREATE VIEW test.vw1 AS WITH t1 AS (SELECT * FROM test.tbl1) SELECT * FROM t1;
      ERROR 2013 (HY000): Lost connection to MySQL server during query
      

      I have grabbed the core file, will provide if needed

      mysql log:

      200602 13:14:42 [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 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.4.12-MariaDB
      key_buffer_size=134217728
      read_buffer_size=131072
      max_used_connections=1
      max_threads=153
      thread_count=7
      It is possible that mysqld could use up to 
      key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 467756 K  bytes of memory
      Hope that's ok; if not, decrease some variables in the equation.
       
      Thread pointer: 0x7f5dd0000c48
      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 = 0x7f5e3c0c8de8 thread_stack 0x49000
      /usr/sbin/mysqld(my_print_stacktrace+0x38)[0x5589fbb90b68]
      /usr/sbin/mysqld(handle_fatal_signal+0x4dd)[0x5589fc0220dd]
      /lib64/libpthread.so.0(+0x141e0)[0x7f5e3fe181e0]
      /usr/sbin/mysqld(strnmov+0x10)[0x5589fbb3a5a0]
      /usr/sbin/mysqld(_Z7acl_getPKcS0_S0_S0_c+0x85)[0x5589fc2bb1c5]
      /usr/sbin/mysqld(_Z31fill_effective_table_privilegesP3THDP13st_grant_infoPKcS4_+0x79)[0x5589fc2a8669]
      /usr/sbin/mysqld(_Z20create_view_precheckP3THDP10TABLE_LISTS2_21enum_view_create_mode+0xe1)[0x5589fc185d11]
      /usr/sbin/mysqld(_Z17mysql_create_viewP3THDP10TABLE_LIST21enum_view_create_mode+0x89)[0x5589fc18de09]
      /usr/sbin/mysqld(_Z21mysql_execute_commandP3THD+0x3199)[0x5589fc23c919]
      /usr/sbin/mysqld(_Z11mysql_parseP3THDPcjP12Parser_statebb+0x25f)[0x5589fbadaf0f]
      /usr/sbin/mysqld(_Z16dispatch_command19enum_server_commandP3THDPcjbb+0x129b)[0x5589fc243bab]
      /usr/sbin/mysqld(_Z10do_commandP3THD+0x14f)[0x5589fc245d3f]
      /usr/sbin/mysqld(_Z24do_handle_one_connectionP7CONNECT+0x1d4)[0x5589fc145154]
      /usr/sbin/mysqld(handle_one_connection+0x32)[0x5589fc1452a2]
      /lib64/libpthread.so.0(+0x8efa)[0x7f5e3fe0cefa]
      /lib64/libc.so.6(clone+0x3f)[0x7f5e3f45e3df]
       
      Trying to get some variables.
      Some pointers may be invalid and cause the dump to abort.
      Query (0x7f5dd000ff70): CREATE VIEW test.vw1 AS WITH t1 AS (SELECT * FROM test.tbl1) SELECT * FROM t1
      Connection ID (thread ID): 9
      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=on,table_elimination=on,extended_keys=on,exists_to_in=on,orderby_uses_equalities=on,condition_pushdown_for_derived=on,split_materialized=on,condition_pushdown_for_subquery=on,rowid_filter=on,condition_pushdown_from_having=on
       
      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.
      Writing a core file...
      Working directory at /var/lib/mysql
      Resource Limits:
      Limit                     Soft Limit           Hard Limit           Units     
      Max cpu time              unlimited            unlimited            seconds   
      Max file size             unlimited            unlimited            bytes     
      Max data size             unlimited            unlimited            bytes     
      Max stack size            8388608              unlimited            bytes     
      Max core file size        unlimited            unlimited            bytes     
      Max resident set          unlimited            unlimited            bytes     
      Max processes             15625                15625                processes 
      Max open files            4186                 4186                 files     
      Max locked memory         65536                65536                bytes     
      Max address space         unlimited            unlimited            bytes     
      Max file locks            unlimited            unlimited            locks     
      Max pending signals       15625                15625                signals   
      Max msgqueue size         819200               819200               bytes     
      Max nice priority         0                    0                    
      Max realtime priority     0                    0                    
      Max realtime timeout      unlimited            unlimited            us        
      Core pattern: /tmp/corefiles/core
      

      Attachments

        Issue Links

          Activity

            People

              igor Igor Babaev
              sgonzalez3884 Sal Gonzalez
              Votes:
              0 Vote for this issue
              Watchers:
              6 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.