Hack MySQL

Archive for the ‘MySQL’ Category

Tossing mysqlsla v1.4 Out There

without comments

Although I have not updated the website, documentation, or how to for mysqlsla, I am tossing mysqlsla v1.4 “out there” to view or wget at:

http://hackmysql.com/scripts/mysqlsla-1.4

I don’t like to release new versions without having everything else updated too, but for various reasons I’m making an exception this time.

mysqlsla v1.4 is much better than v1.3 and a lot has changed. So much has changed that the entire script was essentially re-written. Without an updated doc or how to, I suggest starting with the –help command line op, then contact me if you have specific questions or issues. I will, eventually, update the website, doc, how to, and officially package this new version.

Written by Daniel Nichter

January 17th, 2007 at 6:27 pm

Posted in MySQL,mysqlsla

Humility: Four days later, mysqlreport v3.0 fixed

without comments

mysqlreport v3.0a has been released which fixes a bug on line 93:

chomperc($mycnf{‘pass’} = <STDIN>);

should be just

chomp($mycnf{‘pass’} = <STDIN>);

Thanks to jeroen for pointing this out to me. This bug caused mysqlreport to die when using –pass to prompt for a password:

Undefined subroutine &main::chomperc called at mysqlreport line 93

In other news: thanks also to Aurimas for some technical clarifications in the mysqlreport Guide about temp tables.

Written by Daniel Nichter

December 12th, 2006 at 2:07 pm

Posted in MySQL,mysqlreport

mysqlreport v3.0 – Finally, InnoDB reports

without comments

mysqlreport v3.0 has been released (v2.8 & v2.9 were skipped) which finally has InnoDB reports for MySQL servers v5.0.2 and up. The documentation has been updated accordingly. The new options that invoke the InnoDB reports are –innodb (or -id), –innodb-only (or -ido), and –dpr (for the extra Data, Pages, Rows report).

Since this is the first release with InnoDB reports, feedback on the InnoDB reports is appreciated. Eventually, I’ll update the mysqlreport guide to explain the InnoDB reports. For now, I think the InnoDB reports are self-evident to those who know a little about how the InnoDB storage engine works.

Written by Daniel Nichter

December 8th, 2006 at 3:11 pm

Posted in MySQL,mysqlreport

mysqlreport v2.7 fixed

without comments

mysqlreport v2.7a has been released. It only fixes one bug: –host was completely ignored if a socket was available. Thanks to Sam for pointing this out to me.

Written by Daniel Nichter

November 15th, 2006 at 7:12 pm

Posted in MySQL,mysqlreport

mysqlreport v2.7 released

without comments

mysqlreport v2.7 has been released. This version sports the following changes:

  • Option “password” in ~/.my.cnf now recognized (used to be that only “pass” was recognized)
  • Options host, port, and socket now recognized in ~/.my.cnf
  • Given those two changes, the order of option precendece is such that ~/.my.cnf is read first, then command line options override ~/.my.cnf options, and if nothing else default values are assigned
  • –all actually shows all reports now (i.e. no more need to –all –tab)
  • Like mytop, mysqlreport tries to connect via a socket first, otherwise it tries via a network connection

Thank you to those who provided patches for these changes, although I wound up writing the mods myself for various reasons. To those who wanted /var/lib/mysql/mysql.sock to be the default socket, I decided instead to stay with /var/run/mysqld/mysqld.sock because this is the Debian default and (last I heard) mysqlreport is part of the MySQL Debian package so it takes precedence. For /var/lib/ sock’ers (e.g. Red Hat), you can now add socket=/var/lib/mysql/mysql.sock to ~/.my.cnf.
Also thanks to Baron Schwartz (xaprb) for his kind words and praise for mysqlreport, and my apologies to Herald and others who I told I’d fix the pass/password thing “soon” but “soon” became many weeks.

Written by Daniel Nichter

October 22nd, 2006 at 7:53 pm

Posted in MySQL,mysqlreport