您好,欢迎访问一九零五行业门户网

TokuDB gotchas: slow INFORMATION_SCHEMA TABLES_MySQL

we are usingpercona server + tokudb engineextensively inpercona cloud toolsand getting real usage operational experience with this engine. so i want to share some findings we came across, in hope it may help someone in their work with tokudb.
so, one problem i faced is thatselect * from information_schema.tablesis quite slow when i have thousands tables in tokudb. how slow? for example…
select * from information_schema.tables limit 1000;...1000 rows in set (18 min 31.93 sec)
select*frominformation_schema.tableslimit1000;
...
1000rowsinset(18min31.93sec)
this is very similar to what innodb faced a couple years back. innodb solved it by addingvariableinnodb_stats_on_metadata.
so what happens with tokudb? there is an explanation from rich prohaska at tokutek: “tokudb has too much overhead for table opens. tokudb does a calculation on the table when it is opened to see if it is empty. this calculation can be disabled when ‘tokudb_empty_scan=disabled‘. ”
so let’s see what we have withtokudb_empty_scan=disabled
select * from information_schema.tables limit 1000;...1000 rows in set (3 min 4.59 sec)
select*frominformation_schema.tableslimit1000;
...
1000rowsinset(3min4.59sec)
an impressive improvement, but still somewhat slow. tokutek promises a fix to improve it in the next tokudb 7.2 release.
其它类似信息

推荐信息