MySQLTuner 2

Requests for RPMS, or new coding projects related to server administration, Plesk, security, or anything else you can think of.
dayo
Forum Regular
Forum Regular
Posts: 158
Joined: Sun Jul 12, 2009 1:33 pm

MySQLTuner 2

Unread post by dayo »

Would you consider a switch to MySQLTuner 2 particularly since the original developer said that he doesn't have the time to maintain V1 anymore back in January 2010?

Seems some interesting developments are being put into v2.

Thanks
Kalimari
Forum Regular
Forum Regular
Posts: 526
Joined: Wed Jan 02, 2008 3:21 pm
Location: United Kingdom

Re: MySQLTuner 2

Unread post by Kalimari »

dayo: There is a typo in the link posted, should be: https://launchpad.net/mysqltuner - would be interested in seeing the project continue. Might be worth reading Major Hayden's Blog: http://blog.mysqltuner.com/2010/01/sear ... /#comments - some folks seem to have issue with its future under Pythian (?) - its gone quiet the past couple of months though.

The output of the 2.1 (Sheeri Cabral) version is different from 1.1.1 (Major Hayden) version, although the same info is there, no recommendations are made - which is the key to its popularity. Anyone else taken a look?

My biggest issue with current (1.1.1) version is InnoDB tables no longer support optimize (using recreate + analyze instead) so the MySQL Tuner report: "Run OPTIMIZE TABLE to defragment tables for better performance" is misleading.
dayo
Forum Regular
Forum Regular
Posts: 158
Joined: Sun Jul 12, 2009 1:33 pm

Re: MySQLTuner 2

Unread post by dayo »

Probably best to stick with the 1.x branch when all is said and done.
Kalimari
Forum Regular
Forum Regular
Posts: 526
Joined: Wed Jan 02, 2008 3:21 pm
Location: United Kingdom

Re: MySQLTuner 2

Unread post by Kalimari »

Following an earlier post where I mentioned:
"My biggest issue with current (1.1.1) version is InnoDB tables no longer support optimize (using recreate + analyze instead) so the MySQL Tuner report: "Run OPTIMIZE TABLE to defragment tables for better performance" is misleading."
I discovered a simple solution was to alter line 473 of mysqltuner from:

Code: Select all

$fragtables = `mysql $mysqllogin -Bse "SELECT COUNT(TABLE_NAME) FROM information_schema.TABLES WHERE TABLE_SCHEMA NOT IN ('information_schema','mysql') AND Data_free > 0 AND NOT ENGINE='MEMORY';"`;
To:

Code: Select all

$fragtables = `mysql $mysqllogin -Bse "SELECT COUNT(TABLE_NAME) FROM information_schema.TABLES WHERE TABLE_SCHEMA NOT IN ('information_schema','mysql') AND Data_free > 0 AND NOT ENGINE='MEMORY' AND NOT ENGINE='InnoDB';"`;
Essentially removing InnoDB tables from the fragmentation check. No doubt there is a better way... but the stuff I need to focus on uses MyISAM and this might be useful to others.
Post Reply