[groonga-dev,03688] ラッパーモードのテーブルがあるときにmysql_upgradeするとデータ消滅

Back to archive index

Tomohiro 'Tomo-p' KATO tomop****@teamg*****
2015年 11月 26日 (木) 18:56:07 JST


 こんばんは。かとうです。

  mysql_upgradeを実行するとmrnファイルに格納されていたデータが
 消滅します。


実験環境:
-----------------------------------------------------------------
[groonga-dev,03673]に記した環境を以下に差し替えたもの
- Mroonga: v5.09-58-gefa1d9b
- Groonga: v5.0.9-201-g0bc8767
-----------------------------------------------------------------

再現用クエリ: crash.sql
-----------------------------------------------------------------
DROP TABLE IF EXISTS STORAGE_TEST;
CREATE TABLE STORAGE_TEST (
HOGE int NOT NULL PRIMARY KEY
) ENGINE=Mroonga;

DROP TABLE IF EXISTS WRAPPER_TEST;
CREATE TABLE WRAPPER_TEST (
HOGE int NOT NULL PRIMARY KEY
) ENGINE=Mroonga COMMENT='engine "InnoDB"';
-----------------------------------------------------------------
注1: STORAGE_TESTの部分だけを何度繰り返しても発生しない
注2: WRAPPER_TESTの部分だけにした場合は2回繰り返すと発生する


再現手順:
-----------------------------------------------------------------
# mysqladmin create MROONGA_TEST
# mysql MROONGA_TEST < crash.sql
# mysql_upgrade --force
(snip)
OK

# mysqldump MROONGA_TEST
(snip)
mysqldump: Couldn't execute 'show fields from `STORAGE_TEST`': mroonga: failed to open table: <STORAGE_TEST> (1016)

# mysqldump MROONGA_TEST WRAPPER_TEST
(snip)
mysqldump: Couldn't execute 'show fields from `WRAPPER_TEST`': mroonga: failed to open table: <WRAPPER_TEST> (1016)
-----------------------------------------------------------------

再現後の状況:
-----------------------------------------------------------------
# cat groonga.log
2015-11-26 18:51:53.887937|n|71df1700|DDL:table_create mroonga_operations
2015-11-26 18:51:53.889307|n|71df1700|DDL:column_create mroonga_operations type
2015-11-26 18:51:53.899663|n|71df1700|DDL:column_create mroonga_operations table
2015-11-26 18:51:53.909104|n|71df1700|DDL:column_create mroonga_operations record

# groonga /var/lib/mysql/MROONGA_TEST.mrn
> table_list
[[0,1448530843.3061,0.00527167320251465],[[["id","UInt32"],["name","ShortText"],["path","ShortText"],["flags","ShortText"],["domain","ShortText"],["range","ShortText"],["default_tokenizer","ShortText"],["normalizer","ShortText"]],[256,"mroonga_operations","MROONGA_TEST.mrn.0000100","TABLE_NO_KEY|PERSISTENT",null,null,null,null]]]
-----------------------------------------------------------------

-- 
    __________________________________________________
  _/_/  Tomohiro "Tomo-p" KATO  <tomop****@teamg*****>
 _/_/  Team Gedoh Network  http://www.teamgedoh.net/
_/_/  Key fingerprint: 3347 89D9 5B87 29E6 33A2  30C1 B12F A313 30C4 13F0




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