SHOW CREATE TABLE of PBXT table crashes server

Bug #618758 reported by David Shrewsbury
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Drizzle
Fix Released
Critical
Paul McCullagh
Dexter
Fix Released
Critical
Paul McCullagh

Bug Description

Server crash on Ubuntu 10.04 with revno 1711.

Start the server with pbxt:
  sbin/drizzled --datadir=$PWD/var --plugin-add=pbxt

Run the following:
  create database test;
  use test;
  create table t (id int) engine=pbxt;
  show create table t;

Program terminated with signal 11, Segmentation fault.
#0 0x00007f74f2d2ec57 in myxt_setup_dictionary (self=0x2346208, dic=0x2429940)
    at plugin/pbxt/src/myxt_xt.cc:2656
2656 min_data_size = curr_field->key_length();
(gdb) bt
#0 0x00007f74f2d2ec57 in myxt_setup_dictionary (self=0x2346208, dic=0x2429940)
    at plugin/pbxt/src/myxt_xt.cc:2656
#1 0x00007f74f2d2f739 in myxt_load_dictionary (self=0x2346208, dic=0x2429940,
    db=0x2050a18, tab_path=0x233f298) at plugin/pbxt/src/myxt_xt.cc:2951
#2 0x00007f74f2d49b2f in tab_new_handle (self=0x2346208,
    r_tab=0x7f74d8100d50, db=0x2050a18, tab_id=1, tab_path=0x233f298,
    missing_ok=0, dic=0x0) at plugin/pbxt/src/table_xt.cc:1318
#3 0x00007f74f2d4af70 in xt_use_table_no_lock (self=0x2346208, db=0x2050a18,
    name=0x233f298, no_load=0, missing_ok=0, dic=0x0)
    at plugin/pbxt/src/table_xt.cc:1488
#4 0x00007f74f2d4f4ac in xt_use_table (self=0x2346208, name=0x233f298,
    no_load=0, missing_ok=0) at plugin/pbxt/src/table_xt.cc:2496
#5 0x00007f74f2ce269e in ha_open_share (self=0x2346208, share=0x2345eb8)
    at plugin/pbxt/src/ha_pbxt.cc:357
#6 0x00007f74f2ce5b17 in ha_pbxt::open (this=0x23458d0,
    table_path=0x2344988 "./test/t") at plugin/pbxt/src/ha_pbxt.cc:2316
#7 0x00000000006081f9 in drizzled::Cursor::doOpen (this=0x23458d0,
    identifier=..., mode=2, test_if_locked=2) at drizzled/cursor.cc:222
#8 0x00000000006082c4 in drizzled::Cursor::ha_open (this=0x23458d0,
    identifier=..., table_arg=0x23449a0, name=0x2345218 "./test/t", mode=2,
    test_if_locked=2) at drizzled/cursor.cc:241
#9 0x0000000000819dd9 in drizzled::TableShare::open_table_from_share (
    this=0x2344470, session=0x7f74d40185e0, identifier=...,
    alias=0x233cfc0 "t", db_stat=39, ha_open_flags=0, outparam=...)
    at drizzled/table_share.cc:1981
#10 0x000000000078923f in open_unireg_entry (session=0x7f74d40185e0,
    entry=0x23449a0, alias=0x233cfc0 "t", identifier=...)
    at drizzled/sql_base.cc:2018
#11 0x00000000007886b7 in drizzled::Session::openTable (this=0x7f74d40185e0,
    table_list=0x233cfc8, refresh=0x7f74d810126f, flags=0)
    at drizzled/sql_base.cc:1440
#12 0x0000000000789553 in drizzled::Session::open_tables_from_list (
    this=0x7f74d40185e0, start=0x7f74d81012a0, counter=0x7f74d81012b8, flags=0)
    at drizzled/sql_base.cc:2158
#13 0x000000000076f116 in drizzled::Session::openTables (this=0x7f74d40185e0,
    tables=0x233cfc8, flags=0) at drizzled/session.cc:1882
#14 0x00000000007828d3 in drizzled::drizzled_show_create (
    session=0x7f74d40185e0, table_list=0x233cfc8, is_if_not_exists=false)
    at drizzled/show.cc:129
#15 0x0000000000802783 in drizzled::statement::ShowCreate::execute (
    this=0x2344920) at drizzled/statement/show_create.cc:34
#16 0x00000000007a82df in mysql_execute_command (session=0x7f74d40185e0)
    at drizzled/sql_parse.cc:478
#17 0x00000000007a8fd5 in drizzled::mysql_parse (session=0x7f74d40185e0,
    inBuf=0x23428b8 "show create table t", length=19)
    at drizzled/sql_parse.cc:737
#18 0x00000000007a7c79 in drizzled::dispatch_command (
    command=drizzled::COM_QUERY, session=0x7f74d40185e0,
    packet=0x7f74d4019cf1 "show create table t", packet_length=19)
    at drizzled/sql_parse.cc:223
#19 0x000000000076a5bb in drizzled::Session::executeStatement (
    this=0x7f74d40185e0) at drizzled/session.cc:659
#20 0x0000000000769ea3 in drizzled::Session::run (this=0x7f74d40185e0)
    at drizzled/session.cc:518
#21 0x00007f74f2fb0a56 in MultiThreadScheduler::runSession (this=0x1ffcfd0,
    session=0x7f74d40185e0) at ./plugin/multi_thread/multi_thread.h:67
#22 0x00007f74f2fae9c2 in session_thread (arg=0x7f74d40185e0)
    at plugin/multi_thread/multi_thread.cc:47
#23 0x00007f74f60509ca in start_thread () from /lib/libpthread.so.0
#24 0x00007f74f5dad6fd in clone () from /lib/libc.so.6
#25 0x0000000000000000 in ?? ()

Tags: crash

Related branches

Revision history for this message
David Shrewsbury (dshrews) wrote :

It seems ANY operation on a PBXT table (like SELECT, etc) causes the server die.

Changed in drizzle:
assignee: nobody → Paul McCullagh (paul-mccullagh)
Revision history for this message
Stewart Smith (stewart) wrote : Re: [Bug 618758] Re: SHOW CREATE TABLE of PBXT table crashes server

On Mon, 16 Aug 2010 16:43:49 -0000, David Shrewsbury <email address hidden> wrote:
> It seems ANY operation on a PBXT table (like SELECT, etc) causes the
> server die.

Interesting... I just added some PBXT tests recently to ensure that we
didn't completely break things....

--
Stewart Smith

Revision history for this message
David Shrewsbury (dshrews) wrote :

Based on the stack trace, this is probably the same bug affecting bug 615232.

Revision history for this message
Andrew Hutchings (linuxjedi) wrote :

Confirmed bug#615232 is a duplicate. Any PBXT table open triggers this.

Changed in drizzle:
status: New → Confirmed
importance: Undecided → Critical
Revision history for this message
Andrew Hutchings (linuxjedi) wrote :

I think the problem is self->st_database is wrong. It seems to have the dbname set to '.'

Changed in drizzle:
status: Confirmed → In Progress
Changed in drizzle:
status: In Progress → Fix Committed
Changed in drizzle:
status: Fix Committed → In Progress
Changed in drizzle:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.