Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Make Innodb the new default type for all new Piwik installations (VS Myisam) #4611

Closed
mattab opened this Issue · 8 comments

3 participants

@mattab
Owner

This change will lead to better performance and reliability.

After much experience with using Myisam table type by default, a few team members and users have requested that we should use Innodb by default.

Steps:

  • Change all tables type to use Innodb instead of Myisam
  • Add type=innodb to the [database] section of config.ini.php
    • this will allow users to change the default type of tables to myasam if they want
    • Add FAQ "How do I change the Mysql table types from Innodb to Myasam?"
  • do not convert existing tables. (it's ok to use both myisam for old tables, and innodb for future created archive tables, or plugin tables)
  • mention we use innodb in the performance guide: http://piwik.org/docs/optimize-how-to/ and http://piwik.org/docs/optimize/ ( reference mysql)
  • Only run OPTIMIZE table statements if tables are not innodb
@halfdan
Collaborator

Why support both? Is there any reason for someone to stick with MyISAM?

Personally I think we can just turn the switch and create InnoDB tables in the future and don't need the additional configuration setting.

@mattab
Owner

Not sure if there is a real reason.

Maybe we could only use Innodb, if nobody cares about myasam?

@tsteur
Owner

In f85b6f0: refs #4611 use InnoDB by default, added config option to change to different storage engine, introduced new API method to create tables which will automatically use configured engine, run optimize table only for InnoDB tables

@tsteur
Owner

I added a config setting for now though. Maybe there is no reason to use MyISAM but a reason to use another storage engine (eg infinidb?). It is not really changeable by the user anyway as it is defined in the global config and not changeable during installation. More or less people would have to change it in the global config before installing Piwik and afterwards put it in the user config to make sure it won't be overwritten by an update and to make sure new tables will be created with specified storage engine.

Of course we can also just remove the setting later

@mattab
Owner

In 280be96: Fix logic: only run OPTIMIZE table on Myisam tables. Refs #4611

@mattab
Owner

In b104b4b: Remove $schema = 'Myisam' from all update methods refs #4611

@mattab
Owner

In 36a9626: Streamline config. fixes #4611

@tsteur
Owner

In e9c5c11: refs #4611 fix fatal error because getProfiler and fetchCol methods did not exist when executed in tracker mode

@mattab mattab added this to the 2.1 - Piwik 2.1 milestone
@tsteur tsteur was assigned by mattab
@sabl0r sabl0r referenced this issue from a commit in sabl0r/piwik
@tsteur tsteur refs #4611 use InnoDB by default, added config option to change to di…
…fferent storage engine, introduced new API method to create tables which will automatically use configured engine, run optimize table only for InnoDB tables
f85b6f0
@sabl0r sabl0r referenced this issue from a commit in sabl0r/piwik
@mattab mattab Streamline config. fixes #4611 36a9626
@sabl0r sabl0r referenced this issue from a commit in sabl0r/piwik
@tsteur tsteur refs #4611 fix fatal error because getProfiler and fetchCol methods d…
…id not exist when executed in tracker mode
e9c5c11
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.