[groonga-dev,00923] mroongaストレージエンジンとパーティションの併用について

Back to archive index

磯部 和広 k-iso****@rozet*****
2012年 6月 4日 (月) 19:51:22 JST


いつもお世話になっております。

たびたびすいません。

■概要■

mroongaストレージエンジンでパーティションを作成しようとするとエラーにな
り作成できません。
下記のような行がmysqlのエラーログに出現します。

/usr/local/mysql/lib/plugin/ha_mroonga.so(_ZN10ha_mroonga24primary_key_is_clusteredEv+0x7)[0x7fe66bde2b27]

■質問■

mroongaストレージエンジンではパーティションは使用できないのでしょうか。

リファレンスの「利用可能なSQLコマンドの一覧」「利用できないSQLコマンドの
一覧」の
どちらにもパーティショニングのSQLが見つかりませんでした。

■背景■

現在mroongaをストレージエンジンとして使っています。

データが千5百万件あります。

がテーブルにジャンルを示すカラムを追加しインデックスを張り、
ジャンル別に検索して高速化しようとしても出来ませんでした。

常に全件のデータに対してFullTextサーチをしてから
ジャンルで絞り込む、という動きをするようです。

また、単にジャンルだけを指定して検索をしても
インデックスを張ってあるのに全件サーチなります。

これは、ストレージエンジンとしてのmroongaが
analyze tableを受け付けないため、DB側に統計情報を持たず
その結果・・・という事なのだと思います。

そこで、ラッパーモードに変更して見ました。

※こういう操作の際に、千5百万件とかだとSSDでも40分待たされます・・・

その結果、インデックスでのジャンル指定だけの場合は高速化したのですが
今度はジャンルとFullTextサーチの併せ技が超絶遅くなりました・・・
※3倍以上

というわけで、パーティショニングをして、FullTextサーチでの全件アクセスを
高速化しようとしたのですが。

今度は
ERROR 2013 (HY000) at line 13: Lost connection to MySQL server during query
というエラーを吐いてパーティション付きのテーブルが作成できません。

エラーログには、下記のようなメッセージが書かれていました。

プライマリーキーではないカラムでパーティショニングしようとしても
同一のエラーです。

10:01:04 UTC - 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.
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.

key_buffer_size=2013265920
read_buffer_size=20971520
max_used_connections=3
max_threads=151
thread_count=2
connection_count=2
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads =
8152759 K bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

Thread pointer: 0x23a25c0
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 = 7fe65d474e68 thread_stack 0x40000
/usr/local/mysql/bin/mysqld(my_print_stacktrace+0x2e)[0x752e5e]
/usr/local/mysql/bin/mysqld(handle_fatal_signal+0x41a)[0x6489da]
/lib64/libpthread.so.0(+0xf4a0)[0x7fe751d0b4a0]
/usr/local/mysql/lib/plugin/ha_mroonga.so(_ZN10ha_mroonga24primary_key_is_clusteredEv+0x7)[0x7fe66bde2b27]
/usr/local/mysql/bin/mysqld(_ZN12ha_partition20initialize_partitionEP11st_mem_root+0xbd)[0x8ae75d]
/usr/local/mysql/bin/mysqld(_Z16get_ha_partitionP14partition_info+0x44)[0x64c324]
/usr/local/mysql/bin/mysqld(_Z26mysql_create_table_no_lockP3THDPKcS2_P24st_ha_create_informationP10Alter_infobjPb+0x5b7)[0x5bb307]
/usr/local/mysql/bin/mysqld(_Z18mysql_create_tableP3THDP10TABLE_LISTP24st_ha_create_informationP10Alter_info+0xa5)[0x5bc085]
/usr/local/mysql/bin/mysqld(_Z21mysql_execute_commandP3THD+0x4237)[0x569427]
/usr/local/mysql/bin/mysqld(_Z11mysql_parseP3THDPcjP12Parser_state+0x189)[0x5695b9]
/usr/local/mysql/bin/mysqld(_Z16dispatch_command19enum_server_commandP3THDPcj+0x11f6)[0x56af06]
/usr/local/mysql/bin/mysqld(_Z24do_handle_one_connectionP3THD+0x176)[0x5f4786]
/usr/local/mysql/bin/mysqld(handle_one_connection+0x4a)[0x5f47ea]
/lib64/libpthread.so.0(+0x77f1)[0x7fe751d037f1]
/lib64/libc.so.6(clone+0x6d)[0x7fe750a58ccd]

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (7fe654004b90): is an invalid pointer
Connection ID (thread ID): 2
Status: NOT_KILLED

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.




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