[groonga-dev,01399] mariadbでmroongaがクラッシュしてしまう現象について

Back to archive index

WING☆ wings****@wing-*****
2013年 5月 18日 (土) 01:45:50 JST


WING☆です。
いつも大変お世話になっております。

wingリポジトリでmariadb用のmroongaを公開していましたが、
show engines;でしか確認しておらず、今までそれ以降の確認
を怠っていたのですが、こちらでもお世話になっている磯部様
よりmroongaがクラッシュする情報をご報告頂きました。

ただ、更にこちらでもお世話になっていますyoku様からは、
ソースでビルドした場合には再現しなかったとの情報も
頂きましたため、私のビルド方法に問題がある可能性がある
ため大変心苦しいのですが、アドバイス等を頂けると大変
助かります。

<環境>
・CentOS 6.4 i386/x86_64両方で確認
・epel、wingリポジトリ使用
・以下、groonga、mroonga、mariadbに関するrpm
groonga-3.0.3-1.el6_11.wing.i686
groonga-devel-3.0.3-1.el6_11.wing.i686
groonga-libs-3.0.3-1.el6_11.wing.i686
groonga-normalizer-mysql-1.0.3-1.el6_2.wing.i686
groonga-plugin-suggest-3.0.3-1.el6_11.wing.i686
mariadb-5.5.30-3.el6_2.wing.i686
mariadb-libs-5.5.30-3.el6_2.wing.i686
mariadb-mroonga-3.03-1.el6_13.wing.i686
mariadb-server-5.5.30-3.el6_2.wing.i686
mecab-0.996-1.el6_2.wing.i686
mecab-devel-0.996-1.el6_2.wing.i686
mysqlclient16-5.1.69-1.el6_3.wing.i686

これらをインストール後、show engines;を確認し、

CREATE DATABASE wingtest;
USE wingtest;
CREATE TABLE bbb (id INT) ENGINE=mroonga;

を実施しましたところ、

ERROR 2013 (HY000): Lost connection to MySQL server during query

とエラーが発生し、/var/lib/mysqld.logを確認しますと、以下が
記録されていました。
(mysqld got signal 11からがそのログです。)

---
130518 01:02:46 mysqld_safe Starting mysqld daemon with databases from
/var/lib/mysql
130518  1:02:46 InnoDB: The InnoDB memory heap is disabled
130518  1:02:46 InnoDB: Mutexes and rw_locks use GCC atomic builtins
130518  1:02:46 InnoDB: Compressed tables use zlib 1.2.3
130518  1:02:46 InnoDB: Using Linux native AIO
130518  1:02:46 InnoDB: Initializing buffer pool, size = 128.0M
130518  1:02:46 InnoDB: Completed initialization of buffer pool
InnoDB: The first specified data file ./ibdata1 did not exist:
InnoDB: a new database to be created!
130518  1:02:46  InnoDB: Setting file ./ibdata1 size to 10 MB
InnoDB: Database physically writes the file full: wait...
130518  1:02:46  InnoDB: Log file ./ib_logfile0 did not exist: new to be
created
InnoDB: Setting log file ./ib_logfile0 size to 5 MB
InnoDB: Database physically writes the file full: wait...
130518  1:02:46  InnoDB: Log file ./ib_logfile1 did not exist: new to be
created
InnoDB: Setting log file ./ib_logfile1 size to 5 MB
InnoDB: Database physically writes the file full: wait...
InnoDB: Doublewrite buffer not found: creating new
InnoDB: Doublewrite buffer created
InnoDB: 127 rollback segment(s) active.
InnoDB: Creating foreign key constraint system tables
InnoDB: Foreign key constraint system tables created
130518  1:02:47  InnoDB: Waiting for the background threads to start
130518  1:02:48 Percona XtraDB (http://www.percona.com)
5.5.30-MariaDB-30.1 started; log sequence number 0
130518  1:02:48 [Note] Plugin 'FEEDBACK' is disabled.
130518  1:02:48 [Note] Event Scheduler: Loaded 0 events
130518  1:02:48 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.5.30-MariaDB'  socket: '/var/lib/mysql/mysql.sock'  port:
3306  MariaDB Server
130518  1:03:51 [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.30-MariaDB
key_buffer_size=134217728
read_buffer_size=131072
max_used_connections=1
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 =
465355 K  bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

Thread pointer: 0x0x1cd2910
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 = 0x931b62ac thread_stack 0x48000
??:0(??)[0x9219ad]
buf/buf0buf.c:1854(buf_page_make_young_if_needed)[0x53975f]
??:0(??)[0x16a400]
??:0(??)[0x5246955]
buf/buf0buf.c:4144(buf_page_io_complete)[0x53d357]
sql/sql_base.h:445(DML_prelocking_strategy)[0x490d8e]
include/buf0buf.ic:1137(buf_page_hash_get_low)[0x53e6c3]
archive/ha_archive.cc:302(archive_discover(handlerton*, THD*, char
const*, char const*, unsigned char**, unsigned int*))[0x49bbd4]
sql/sql_delete.cc:1025(multi_delete::send_eof())[0x46911b]
sql/sql_delete.cc:52(mysql_delete(THD*, TABLE_LIST*, Item*,
SQL_I_List<st_order>*, unsigned long long, unsigned long long))[0x469ef3]
sql/sql_string.h:240(String::free())[0x3f9046]
sql/item_timefunc.h:751(~Item_func_sec_to_time)[0x3f9639]
sql/key.cc:87(find_ref_key(st_key*, unsigned int, unsigned char*,
Field*, unsigned int*, unsigned int*))[0x3fb058]
sql/key.cc:114(key_copy(unsigned char*, unsigned char*, st_key*,
unsigned int, bool))[0x3fb826]
handler/ha_innodb.cc:3267(innobase_copy_repl_coords_to_trx)[0x4b3605]
handler/ha_innodb.cc:9379(ha_innobase::info_low(unsigned int,
bool))[0x4b3760]
??:0(??)[0x171a49]
??:0(??)[0xb74f6aee]

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (0x932047c0): is an invalid pointer
Connection ID (thread ID): 3
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.
130518 01:03:52 mysqld_safe Number of processes running now: 0
130518 01:03:52 mysqld_safe mysqld restarted
130518  1:03:52 InnoDB: The InnoDB memory heap is disabled
130518  1:03:52 InnoDB: Mutexes and rw_locks use GCC atomic builtins
130518  1:03:52 InnoDB: Compressed tables use zlib 1.2.3
130518  1:03:52 InnoDB: Using Linux native AIO
130518  1:03:52 InnoDB: Initializing buffer pool, size = 128.0M
130518  1:03:52 InnoDB: Completed initialization of buffer pool
130518  1:03:52 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!
130518  1:03:52  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
130518  1:03:52  InnoDB: Waiting for the background threads to start
130518  1:03:53 Percona XtraDB (http://www.percona.com)
5.5.30-MariaDB-30.1 started; log sequence number 1597945
130518  1:03:53 [Note] Plugin 'FEEDBACK' is disabled.
130518  1:03:53 [ERROR] mysqld: Table './mysql/plugin' is marked as
crashed and should be repaired
130518  1:03:53 [Warning] Checking table:   './mysql/plugin'
130518  1:03:53 [ERROR] mysql.plugin: 1 client is using or hasn't closed
the table properly
130518  1:03:53 [ERROR] mysqld: Table './mysql/func' is marked as
crashed and should be repaired
130518  1:03:53 [Warning] Checking table:   './mysql/func'
130518  1:03:53 [ERROR] mysql.func: 1 client is using or hasn't closed
the table properly
130518  1:03:53 [Note] Event Scheduler: Loaded 0 events
130518  1:03:53 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.5.30-MariaDB'  socket: '/var/lib/mysql/mysql.sock'  port:
3306  MariaDB Server
---

そもそも、yoku様のソースビルドでの環境では問題が出ていない
ため、私のmariadb-5.5.30のビルド方法に問題があると推測して
いるのですが、何か心当たりがあれば、ご教示頂きたいと存じます。

基本的にmariadbは、Fedora19(開発中)のspecを参考にしており、
なるべく素の状態でビルドするためにPatchを当てずにビルドしたり
試してみましたが、結果は同じ。
cmakeでは以下のオプションでビルドしています。

cmake . -DBUILD_CONFIG=mysql_release \
        -DFEATURE_SET="community" \
        -DINSTALL_LAYOUT=RPM \
        -DCMAKE_INSTALL_PREFIX="%{_prefix}" \
        -DINSTALL_INCLUDEDIR=include/mysql \
        -DINSTALL_INFODIR=share/info \
        -DINSTALL_LIBDIR="%{_lib}/mysql" \
        -DINSTALL_MANDIR=share/man \
        -DINSTALL_MYSQLSHAREDIR=share/mysql \
        -DINSTALL_MYSQLTESTDIR=share/mysql-test \
        -DINSTALL_PLUGINDIR="%{_lib}/mysql/plugin" \
        -DINSTALL_SBINDIR=libexec \
        -DINSTALL_SCRIPTDIR=bin \
        -DINSTALL_SQLBENCHDIR=share \
        -DINSTALL_SUPPORTFILESDIR=share/mysql \
        -DMYSQL_DATADIR="/var/lib/mysql" \
        -DMYSQL_UNIX_ADDR="/var/lib/mysql/mysql.sock" \
        -DENABLED_LOCAL_INFILE=ON \
        -DENABLE_DTRACE=OFF \
        -DWITH_EMBEDDED_SERVER=ON \
        -DWITH_READLINE=ON \
        -DWITH_SSL=system \
        -DWITH_ZLIB=system \
        -DWITH_MYSQLD_LDFLAGS="-Wl,-z,relro,-z,now"

私が公開しています、rpmのURLは以下のとおりです。

http://wing-net.ddo.jp/wing/6/

大変ややこしい事例になってしまっているかと思いますが、
何卒、よろしくお願い致します。
-- 
━━━━━━━━━━━━………‥‥‥・・・
WING☆
http://wingse.blog57.fc2.com/
http://sourceforge.jp/projects/wing-repo/
twitter:wingstars555
Facebook:http://facebook.com/ason.fukui.5
━━━━━━━━━━━━……‥‥・・




groonga-dev メーリングリストの案内
Back to archive index