tpcc_start core dump on Ubuntu 9.04 64bit

Bug #997478 reported by Vincent Liu
This bug affects 2 people
Affects Status Importance Assigned to Milestone

Bug Description

Reading symbols from /lib/
Loaded symbols for /lib/
Reading symbols from /lib/
Loaded symbols for /lib/
Core was generated by `./tpcc_start -h xxx -P xxx -d tpcc -uxxx -pxxx -w 10 -c 1 -'.
Program terminated with signal 11, Segmentation fault.
[New process 31299]
[New process 31297]
#0 0x00007f4c6b17dfd2 in my_stat () from /usr/lib/
(gdb) bt
#0 0x00007f4c6b17dfd2 in my_stat () from /usr/lib/
#1 0x00007f4c6b1753b4 in ?? () from /usr/lib/
#2 0x00007f4c6b175cd0 in ?? () from /usr/lib/
#3 0x00007f4c6b175e77 in get_charset_by_csname () from /usr/lib/
#4 0x00007f4c6b1977ba in mysql_init_character_set () from /usr/lib/
#5 0x00007f4c6b1997a8 in mysql_real_connect () from /usr/lib/
#6 0x0000000000402ad1 in thread_main (arg=<value optimized out>) at main.c:668
#7 0x00007f4c6a9853ba in start_thread () from /lib/
#8 0x00007f4c6ac8002d in clone () from /lib/
#9 0x0000000000000000 in ?? ()

(gdb) run -h -P 6303 -d tpcc -umyshard -pmyshard -w 10 -c 1 -r 10 -l 60

But I tried to compile it on 32bit ubuntu and it runs well. Anyway..


=== modified file 'src/main.c'
--- src/main.c 2011-10-24 02:54:41 +0000
+++ src/main.c 2012-05-09 09:40:40 +0000
@@ -659,6 +659,7 @@
     db_string_ptr = node_string[((num_node * t_num)/num_conn)];

+ mysql_thread_init();
     /* exec sql connect :connect_string; */
     resp = mysql_real_connect(ctx[t_num], "localhost", db_user, db_password, db_string, port, NULL, 0);

Btw, the Makefile uses `mysql_config`, which may not be installed on any machine. It would be better if we could mention this a lit in README, anyway...

Good tool, thank you all so much for such a good job!

Revision history for this message
Gea-Suan Lin (gslin) wrote :

In AWS EC2 us-east-1, I can reproduce this issue on m1.small 64bits (Ubuntu 12.04 LTS).

Revision history for this message
Chang chen (baibaichen) wrote :

the root cause is we don't call mysql_thread_init() in the connection thread see

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers