Just how do you pick a MySQL data source engine

Specifically, just how do you pick in between MyISAM and also InnoDB, when neither is missing out on a called for attribute (e.g. you do not require international keys).

Does it constantly boil down to attempting both and also gauging? Or exist excellent general rules pertaining to the number and also regularity of reviews versus creates, and also various other actions like that? Does the dimension of the table have any kind of result on the regular selection?

2019-05-07 02:46:35
Source Share
Answers: 5

There are attributes that you will certainly locate really valuable, for functional factors, also if your application does not definitely need them:

  • InnoDB has MVCC which suggests you can take non - obstructing regular back-ups
  • InnoDB has automated recuperation which suggests no extensive REPAIR TABLE procedures after a dirty closure
  • With InnoDB, viewers never ever obstruct authors and also the other way around, definition (usually talking) better concurrency (this need not suggest far better efficiency in the basic instance though)
  • InnoDB collections its rows on the main key, which MAY suggest less IO procedures for read procedures IF the main key was picked completely well.

So regardless of international key restraints, you possibly intend to make use of InnoDB anyhow.

certainly this is ServerFault, not Stack Overflow, so the correct solution is:

  • You have to constantly make use of the engine that the application programmers have actually picked
  • If they have not picked a details engine, they aren't really significant concerning making use of MySQL, and also possibly do not recognize just how to utilize it effectively.
  • You can not switch over to a various engine to the one which your application was examined on, it might present pests.
2019-05-31 06:43:23

There are an excellent variety of standards around for various MySQL data source engines. There's a suitable one contrasting MyISAM, InnoDB and also Falcon on the Percona MySQL Performance Blog, see here.

An additional point to take into consideration in between both abovementioned engines (MyISAM and also InnoDB) are their strategies to securing. MyISAM executes table - securing, whilst InnoDB executes row - securing. There are a selection of points to take into consideration, not just downright efficiency numbers.

2019-05-09 00:57:07

If it's simply a straightforward store/ record system I make use of MyISAM for its raw efficiency.

I would certainly make use of InnoDB if I was worried concerning numerous simultaneous accessibilities with great deals of creates, to capitalize on row - degree securing.

2019-05-09 00:56:21

The solution is you need to constantly gauge, ideally with your very own information and also work if in all feasible.

Given that the information accessibility patterns can differ substantially from application to application, it's tough to claim and also probably difficult to establish a "ideal" storage space engine for all work.

Nonetheless, there are really motivating growths in the MySQL room having actually participated in MySQLConf/Percona Performance Conf recently.

Several of the different storage space engines:

  1. XtraDB (fork of InnoDB)
  2. InnoDB plugin
  3. PBXT
  4. TokuDB

Additionally, Percona, Google, etc have actually added spots that aid substantially with InnoDB performance. Directly, I run an OurDelta construct. It functions perfectly for me and also I urge looking into the OurDelta and also Percona constructs.

2019-05-09 00:37:49

My hosting carrier suggested us to remove MyISAM entirely and also switch over to InnoDB, unless it is not feasible.

In our instance we were having extreme information corruption which began to show from a couple of times to a couple of times daily, constantly calling for REPAIR TABLE and also relevant commands, which took ages on huge tables.

As soon as we transformed (or : were transformed) to InnoDB, the troubles promptly vanished. Downsides/caveats we had :

  • Can't transform tables with FULLTEXT index (this trouble vanished with time on its own ; it was changed with a Solr/Lucene based remedy which has better top quality anyhow)
  • Big tables with numerous rows which usually call for COUNT (*) were really slow-moving, we were unable to switch over those either.

Yet note : this is all details to our setting, etc, so it might not usually use.

2019-05-08 13:05:08