Skip to content

Commit

Permalink
Specify MySQL storage engine for mfdb temp tables.
Browse files Browse the repository at this point in the history
Since MySQL 5.5 changes the default storage engine to InnoDB, and since
many distros configure the InnoDB file path to refer to a directory on a
file system with barriers enabled, any temporary tables written to disk
will be written as InnoDB tables on the InnoDB file path, rather than
using MyISAM tables, which can be stored on the tmpdir.  This results in
severe performance issues when using mythfilldatabase with Schedules
Direct data.  Therefore, specify the use of MyISAM storage engine for
mythfilldatabase DataDirect temporary tables.

See, also:
https://bugs.launchpad.net/ubuntu/+source/mythtv/+bug/997367
  • Loading branch information
sphery committed May 23, 2012
1 parent c8fa24d commit c06b706
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mythtv/libs/libmythtv/datadirect.cpp
Expand Up @@ -1238,7 +1238,7 @@ void DataDirectProcessor::CreateATempTable(const QString &ptablename,
MSqlQuery query(MSqlQuery::DDCon());
QString querystr;
querystr = "CREATE TEMPORARY TABLE IF NOT EXISTS " + ptablename + " " +
ptablestruct + ";";
ptablestruct + " ENGINE=MyISAM;";

if (!query.exec(querystr))
MythDB::DBError("Creating temporary table", query);
Expand Down

0 comments on commit c06b706

Please sign in to comment.