Commit graph

825 commits

Author SHA1 Message Date
root
ba2ea1f0f3 merged version 2015-06-17 23:28:50 +02:00
Jean-Marie RENOUARD
61ba60e1ee Fix for innodb buffer pool instances when buffer pool is lower than 1Go 2015-06-17 18:03:44 +02:00
Jean-Marie RENOUARD
bf922481b7 activate nocollor when reportfile is set 2015-06-17 17:50:06 +02:00
Jean-Marie RENOUARD
512cb3de1d activate nocollor when reportfile is set 2015-06-17 17:46:52 +02:00
root
0736ef7c56 adding --reportfile for file output result 2015-06-16 23:38:17 +02:00
Christian Loos
1f27eb393e fix fetching memory values on non-english Linux systems 2015-06-16 14:26:08 +02:00
Christian Loos
0b07468e43 move innodb_buffer_pool_instances output after innodb_buffer_pool_size 2015-06-16 13:34:41 +02:00
Christian Loos
1e7fe0d394 update innodb_buffer_pool_instances output
* make the output more consistent with the other InnoDB outputs
* calculate a value for 'Variables to adjust'
2015-06-16 13:21:58 +02:00
Christian Loos
9d50475025 don't mention innodb_buffer_pool_size again
innodb_buffer_pool_size is reported previously, so no need to do this
here again
2015-06-16 12:24:42 +02:00
Christian Loos
f2f2bdcf57 don't mention MySQL version again
The MySQL version is mentioned previously, so no need to do this here
again.
Also the version mentioned was wrong as innodb_buffer_pool_instances was
introduced in 5.5.4:
http://dev.mysql.com/doc/refman/5.5/en/innodb-parameters.html#sysvar_innodb_buffer_pool_instances
2015-06-16 12:19:38 +02:00
Jean-Marie RENOUARD
e231e21d1e Adding advice for buffer_pool_size_instances variables for 5.6.6+ mysql version 2015-06-15 16:22:51 +02:00
Jean-Marie RENOUARD
c8043c2965 Warning message for lagging slave 2015-06-15 15:34:29 +02:00
Jean-Marie RENOUARD
7d51d2f69e adding --passwordfile option 2015-06-15 15:23:05 +02:00
Jean-Marie RENOUARD
50d7718c07 some debug output cleanup. 2015-06-15 09:47:24 +02:00
Jean-Marie RENOUARD
e919e904ba Adding extra security test for password based on password list 2015-06-12 16:09:59 +02:00
Rene Schmidt
836bed3891 added option mysqlcmd so you can give a custom mysql command to mysqltuner.pl 2015-04-16 16:58:48 +02:00
Nick Ostrovsky
33c85281e9 Update mysqltuner.pl 2014-12-29 21:15:13 +07:00
Major Hayden
4f472521d7 Version 1.4.0 2014-12-04 09:56:31 -06:00
Cole Turner
3b12ccb773 Added name to contributor list. 2014-12-04 10:52:28 -05:00
Cole Turner
5f1e12f11d Adding check for autoincrement keys
Not familiar with Perl, please double check.
2014-12-04 02:14:02 -05:00
Erik Ljungstrom
604900d536 Fixed reporting for temporary tables created on disk. Created_tmp_disk_tables is a subset of Created_tmp_tables 2014-12-02 12:58:57 +00:00
Joe Horn
dee239f243 Update mysqltuner.pl
* information_schema.ENGINES doesn't exist before MySQL 5.1
* table cache var. depends on MySQL version
2014-11-06 19:43:43 +08:00
Cristi
f5355b4349 added new option
added the "--buffers" option to print all global and thread buffer values for easier tuning
2014-10-23 13:37:11 +03:00
Major Hayden
2c69d953f8 Merge pull request #45 from altblue/master
improve "$arch" variable usage
2014-08-12 07:31:53 -05:00
Baebeca
a5a9455245 Update mysqltuner.pl
minor format fixes
2014-08-10 19:18:16 +02:00
Major Hayden
9341faf56a Correct table_cache_var bug
Fixes #49 by correcting a small error from #48. Sorry, folks!
2014-06-05 20:45:16 -05:00
Aron Rotteveel
ab58b15ef0 Fix for MySQL 5.6 table_open_cache
MySQL 5.6 fails silently when table_cache is used instead of table_open_cache. MySQLTuner should indicate table_open_cache instead of table_cache when printing variable suggestions.
2014-06-05 21:57:30 +02:00
Marius Feraru
8347fafe4e improve "$arch" variable usage
- handle the (default!) undefined case;
- really treat it as a number (cause that's the way it is defined everywhere in "check_architecture", and it is compared to a number too);
- (try to) avoid extra ops by reordering the operations.
2014-03-21 17:38:40 +02:00
zequeitor
7a28b64ecf check query cache verification on mysql >= 5.6.8
Add query cache type verification
MySQL >= 5.6.8 has query_cache_type OFF by default. It will disables the entire cache. 
http://dev.mysql.com/doc/refman/5.6/en/server-system-variables.html#sysvar_query_cache_type
2014-03-06 18:22:02 -02:00
Blake Swopes
a07f7a16e3 Shifting InnoDB log waits block up into the have_innodb block.
This should prevent any attempt to access an undefined Innodb_log_waits value.

resolves #42
2014-03-03 14:24:36 -08:00
Major Hayden
dbcb8178ed Version 1.3.0 2014-02-21 19:43:08 -06:00
Major Hayden
216bade70e Merge pull request #18 from meghuizen/patch-1
Add DirectAdmin support.
2014-02-21 19:15:04 -06:00
Major Hayden
35955db67f Merge pull request #19 from DanBUK/master
Swap position of innodb buffer pool size and data size arguments
2014-02-21 19:13:46 -06:00
Major Hayden
e23a798563 Add more flexible engine display support
Fixes #22.
2014-02-21 19:04:45 -06:00
Major Hayden
6c9ed7cdb8 Hide stderr if which svcprop fails
Fixes #29.
2014-02-21 18:44:12 -06:00
Major Hayden
7571672419 Merge branch 'master' of https://github.com/sunfoxcz/MySQLTuner-perl into sunfoxcz-master 2014-02-21 18:40:15 -06:00
Major Hayden
18eed21ecd Cleanup of custom mysqladmin command code
Fixes #30.
2014-02-21 11:32:49 -06:00
Major Hayden
7b0664bbbf Merge branch 'master' of https://github.com/aylazhang/MySQLTuner-perl into aylazhang-master 2014-02-21 11:23:41 -06:00
Major Hayden
37d1703b6f Merge pull request #32 from gibas/add-darwin-arch
Add darwin arch
2014-02-21 11:16:02 -06:00
Major Hayden
bdca23452c Removed version checking routines until I can figure out something different
Somewhat fixes #33. I'll open a new issue to work on a new version checker.
2014-02-21 11:13:34 -06:00
Major Hayden
18b4b8f982 Adding warning about big table caches
This isn't the ideal fix, but at least the warning is there. Many thanks to @ywarnier for pointing this out to me on GitHub. ;)

Fixes #36.
2014-02-21 11:09:59 -06:00
Major Hayden
47e3dd2350 Avoid divide by zero error with key_buffer_size
Fixes #35.
2014-02-21 11:04:38 -06:00
Major Hayden
1ed12ad68c Adds suggestion for innodb_log_buffer_size
Fixes #38
2014-02-21 10:44:43 -06:00
Major Hayden
aba4d3b444 Fixed version parse errors for MariaDB 10.x
MariaDB 10.x still has limited support in MySQLTuner.  Using this script with MariaDB may cause your server to start chasing cars. :)

This fixes #34.
2014-02-21 10:36:26 -06:00
Krzysztof Gibas
fda5bad78d fixed uname execution syntax 2013-05-24 19:43:26 +02:00
Krzysztof Gibas
fffef5c7c2 added Darwin as 64bit architecture, as kaalis pointed out in https://github.com/rackerhacker/MySQLTuner-perl/pull/27#issuecomment-15450764 2013-05-24 19:24:23 +02:00
Krzysztof Gibas
4b95c66d33 added Darwin as 64bit architecture, as kaalis pointed out in https://github.com/rackerhacker/MySQLTuner-perl/pull/27#issuecomment-15450764 2013-05-24 19:11:08 +02:00
aylazh
dbdddf4775 nothing. 2013-03-19 18:09:29 +08:00
aylazhang@gmail.com
8824bb49f1 little modify 2013-03-19 18:05:29 +08:00
zhangyan
2d1b2bd32d add mysqladmin option 2013-03-19 17:56:01 +08:00
foxycode
d07b504f8c Added Solaris SMF and SmartOS/Percona Quickbackup detection to get credentials automatically. 2013-02-12 23:53:51 +01:00
Krzysztof Gibas
1188149f32 fixed finding a 64bit architecture on NetBSD/OpenBSD and FreeBSD 2012-12-21 13:39:36 +01:00
Krzysztof Gibas
409884e597 fix finding a 64bit architecture on FreeBSD 2012-12-21 13:11:38 +01:00
Krzysztof Gibas
7dd218760b fix memory detection on FreeBSD 2012-12-21 12:51:28 +01:00
Daniel
9f40efe480 Swap position of innodb buffer pool size and data size arguments to match key buffer size args. 2012-05-17 15:30:51 +01:00
Michiel
33d97c672c Add DirectAdmin support. Also tested on DirectAdmin v 1.40.3 on Debian 6 - 64 bits #17 2012-04-26 15:49:29 +03:00
Markus Köberl
27f1454b0e update comments and logging messages 2011-04-21 14:36:10 +02:00
Markus Köberl
2e347611ff use the option --defaults-file ... 2011-04-21 08:32:29 +02:00
Markus Köberl
18bab70c84 use the maintanance account on debian system 2011-04-20 13:23:30 +02:00
Ville Skyttä
6add6186bc Use portable /dev/null from File::Spec. 2011-04-02 15:03:32 +03:00
Ville Skyttä
32b1eb2111 Ignore output from stty for portability (e.g. Windows). 2011-04-02 14:56:42 +03:00
Ville Skyttä
46bdd402f4 Simplify MySQL version checks. 2011-04-02 14:54:00 +03:00
Ville Skyttä
a49c091457 Avoid some awk and grep invocations for portability (e.g. Windows). 2011-04-02 14:51:06 +03:00
Ville Skyttä
c88f07fa73 Grammar fix. 2011-04-01 21:17:33 +03:00
Ville Skyttä
b5dd0397bf Trim trailing whitespace. 2011-03-08 20:38:37 +02:00
Ville Skyttä
d6c7f9ac4d Add Emacs indentation settings. 2011-03-08 20:37:58 +02:00
mhayden
05813a1faa Version bump to 1.2.0 2011-03-06 18:50:36 -06:00
Ville Skyttä
778cc60885 Work around MySQL bug #59393 wrt. ignore-builtin-innodb. 2011-03-06 13:04:08 +02:00
Ville Skyttä
4df766729c Check engine availability also with SHOW ENGINES.
have_$engine are deprecated and will be removed in MySQL 5.6, and some
of them are either missing in some versions before that or show wrong
values - see e.g. MySQL bugs #47286 and #59393.
2011-03-06 12:59:46 +02:00
Ville Skyttä
a1d7114759 Fix detection of Federated engine availability.
The variable is have_federated_engine, not have_federated.
2011-03-06 12:53:32 +02:00
Ville Skyttä
0bd59c3330 List users without passwords as user@host, sorted. 2009-12-24 23:29:45 +02:00
rackerhacker
b2dfc8789a Bumped version number to 1.1.1 2009-09-17 23:26:12 +00:00
rackerhacker
f0f9f3f325 Added AIX 5L support (patch from Baptiste M. via the blog)
Adjusted the version number (should have been done for the 1.1.0 tagged release)
2009-09-17 23:24:33 +00:00
rackerhacker
32cf710293 Added in a check for users without passwords and check for slaves running with read_only disabled (patch from Isart Montane) 2009-09-17 23:13:22 +00:00
rackerhacker
9d002146d5 Forgot to change the old assembla svn note in the script over to github. :| 2009-09-17 22:42:53 +00:00
major
e29c3d342c Version bump to 1.1.0
Added git tag 'v1.1.0
2009-09-16 01:00:56 +00:00
Major Hayden
fff47e9a6f Fixed a Solaris awk bug, found a more reliable way to get the home directory, and fixed a syntactical error. (Thanks to Adam Stein) 2009-05-28 02:16:16 +00:00
Major Hayden
e425897b41 Fixed an issue where the percentage of keys pulled from memory would not exist if no keys have been read since the server started. (Thanks to Simon Greenaway) 2009-05-28 01:54:39 +00:00
Major Hayden
c4bb3c0d26 A warning is now provided if if the query_cache_size goes over 128M. (Thanks to Tim Soderstrom) 2009-05-28 01:50:29 +00:00
Major Hayden
e419c79356 Fixed an issue where null storage engines appeared when querying INFORMATION_SCHEMA. 2009-05-28 01:23:55 +00:00
Major Hayden
a2bb3ab149 Fixed an issue where MEMORY tables would appear in the fragmented table list, which caused some confusion. (Thanks to Gary Barrueto) 2009-05-28 00:57:31 +00:00
Major Hayden
62e42e3c25 When counting index size for MyISAM tables, the INFORMATION_SCHEMA query included all engines. (Thanks to Tom Krouper) 2009-05-28 00:40:43 +00:00
Major Hayden
a462d4d01d Version bump to 1.0.0
Small spelling correction
Contributors list updated
2008-12-01 23:37:24 +00:00
Major Hayden
c0ab5bc196 Version bump to 1.0.0-rc1
Fixed memory calculation problem in NetBSD where the amount of memory overflowed a 32-bit integer.  Used "sysctl -n hw.physmem64" rather than "sysctl -n hw.physmem" in those situations. (Thanks to Dave Burgess)
Fixed an issue where the script would suggest adding skip-isam to the MySQL configuration in 4.0.x, but the directive wasn't available until 4.1.1. (Thanks to Ryan Novosielski)
Fixed an issue with MySQL 5.1 where table_open_cache needed to be adjusted, rather than open_cache. (Thanks to Michael Scheidell and Blair Christensen)
Adjusted some misleading wording when MySQL's memory usage is very high relative to the amount of physical memory installed. Increased threshold to 90%. (Thanks to Hans du Plooy)
Fixed an issue where MySQL logins failed when a socket was specified but a .my.cnf file was also present. (Thanks to Victor Trac)
Added full support for Solaris. (Big thanks to Bill Bradford)
2008-11-02 18:25:55 +00:00
Major Hayden
e328934a19 Fixed an issue with NULL storage engines appearing on some servers. 2008-09-08 20:40:22 +00:00
Major Hayden
c8c2dd9518 Bumped version to 0.9.9
Added --socket option to use an alternative socket (thanks Mark!)
Added OpenBSD memory checking support (thanks Giovanni!)
Added counts to report lines to provide additional detail
Fixed error where disabling BDB was recommended even when BDB tables were present (thanks Greg!)
Fixed an issue with big integers (> 2^32) from key calculations (thanks Aubin!)
Fixed an error on Solaris machines (thanks Bill!)
Fixed an issue where the key buffer calculation caused errors when no indexes were present
Added Giovanni Bechis, Greg Eden, Aubin Galinotti, Mark Imbriaco and Bill Bradford to the contributors list
2008-09-08 01:16:39 +00:00
Major Hayden
e475bfa48b Version bump to 0.9.8
Added new options to help output
Made version checking off by default, enabled by --checkversion option
2008-07-21 16:19:50 +00:00
Major Hayden
ec4180839a Version bump to 0.9.5
Support is now available for remote servers
Can force the script to assume that a certain amount of memory is present (thanks Jason!)
Usernames and passwords can now be passed on the command line
Added Jason Gill to the contributors list
2008-07-13 03:18:20 +00:00
Major Hayden
af3b70578f Version bump to 0.9.1
Added checks for fragmented tables
Fixed login routine to allow zero-length passwords without re-prompting for the password repeatedly
Added workaround for wget 1.11 timestamping bug
Fixed a math error in the temporary table calculations
Fixed an error that occurred when the status variable Open_files returned zero
Added table cache change in preparation for MySQL 6.x
Thanks to Ville Skytta, Trent Hornibrook and Luuk Vosslamber for the bug reports and feature requests!
2008-06-19 02:33:54 +00:00
Major Hayden
7a154d635e Fixed an issue with table_cache in MySQL 6.x (it's now table_open_cache in MySQL 6.x) 2008-04-08 21:43:05 +00:00
Major Hayden
59eaf76f47 Version bump to 0.9.0
Fixed a bug where NULL may appear when enumerating tables on MySQL 5
MySQLTuner now checks for updates and allows the checks to be disabled
2008-04-06 15:17:10 +00:00
Major Hayden
6311b077cd Version bump to 0.8.9
Added an option to skip the enumeration/sizing of tables (--skipsize), which should help on servers with lots of tables
Changed the table enumeration/sizing method for MySQL 5 to use information_schema (increased performance drastically)
Adjusted the query_cache_limit recommendation to include the currently set value, rather than 1M each time
Changed the wording for tmp_table_size/max_heap_table_size to make it less confusing
2008-04-05 16:34:57 +00:00
Major Hayden
dc73ed5328 Version bump.
Added Shawn Ashlee to contributors.
2008-02-27 03:13:03 +00:00
Major Hayden
734a8a4a2f Added lines between sections to increase readability.
Corrected a bug where storage engine statuses were still in color even with --nocolor.
Excluded information_schema tables from calculations (they were showing up as usual MEMORY tables).
2008-02-27 03:07:15 +00:00
Major Hayden
2f2235fabc Bumped to version 0.8.5
Fixed copy/paste bug with OK/!!/-- output (Thanks to Nils!)
Fixed a data length calculation bug in MySQL 4.0.x
Fixed a key buffer calculation bug in MySQL 4.0.x
Added in a notification for situations when no recommendations are available
Added Nils Breunese to the contributors list
2008-02-11 17:53:26 +00:00
Major Hayden
5e8c2311fa Corrected the total key buffer calculation when symlinks are used
Went to traditional versioning scheme starting at 0.8.0
2008-02-01 00:55:34 +00:00
Major Hayden
9edfd8fb0f Version bump 2008-01-16 03:57:51 +00:00
Major Hayden
218a41df8a Removing a minor left over comment 2008-01-16 03:54:19 +00:00
Major Hayden
e693649bf9 Fixed a bug in MySQL 3.23 where the storage engine checks had problems
Adjusted some of the Perl code to be more compact, organized, and factored
2008-01-16 03:39:36 +00:00
Major Hayden
9ccae41ead Fix for the bugfix in r24. 2008-01-15 01:38:47 +00:00
Major Hayden
c56383201c Version bump and tab fix 2008-01-15 01:30:51 +00:00
Major Hayden
d63d6fc23a Fixed two bugs relating to the database crawler when database names contained a hyphen. (Thanks to Mike
Jackson)
2008-01-15 01:24:25 +00:00
Major Hayden
aee3d61131 Added lots of InnoDB support
Flipped spaces to tabs
Added more storage engine checks
Adjusted output display
2008-01-14 00:57:46 +00:00
Major Hayden
bc69094412 * Added innodb_log_file_size checks
* Added 32-bit/64-bit checks and warnings (maximum memory > 2GB = bad)
* Fixed temporary table recommendation bug (would never recommend increase)
* Fixed thread cache recommendations/warnings
* Merged increase/decrease variable recommendations into one category
2007-12-01 22:04:00 +00:00
Major Hayden
34b5cba861 * Changed indexing calculations so that all tables are not opened in MySQL 5 (thanks Jon!)
* Adjusted some of the commented lines at the top of the script
2007-12-01 20:31:15 +00:00
Major Hayden
33928700a3 * Added NetBSD support (thanks to Dave Burgess)
* Switched username/password prompts to STDERR so they won't appear in printouts
2007-11-06 23:20:09 +00:00
Major Hayden
d98fa91a3d * Adjusted infoprint to use asterisks (cosmetic)
* Per-thread/global buffer counts are now displayed
* Key buffer increases are only recommended if the buffer is smaller than total indexes and key buffer hit rate is < 95%
* Dropped max_seeks_for_key checks
* Temporary table size increases are not recommended over 256M
* Aborted connection calculation and recommendation adjustments
2007-10-16 01:45:09 +00:00
Major Hayden
b267fc7636 Very small bugfix for MySQL 3.23 on line 408 2007-10-07 14:54:20 +00:00
Major Hayden
b3fd62e953 Added aborted connection checks
Added % reads/writes counts
Adjusted recommendations for slow query logging, max seeks per key, and joins without indexes
2007-09-07 00:29:18 +00:00
Major Hayden
44f465ae0a Minor fix if no selects have been run (Thanks Kevin) 2007-08-15 12:30:08 +00:00
Major Hayden
efc984f945 Fixed a dumb logic error with the concurrent_insert check 2007-08-13 22:01:28 +00:00
Major Hayden
04e84a7752 Minor divide by zero error in query cache calculations 2007-08-12 19:11:35 +00:00
Major Hayden
c6498519a5 Tremendous overhaul of massive proportions.
Thanks to suggestions from Mike Jackson, BK Box, Bryan Tholen, and Shawn Ashlee.
MySQLTuner's new home is now at: http://rackerhacker.com/mysqltuner/
The big feature changes will be documented there.
2007-08-12 18:51:10 +00:00
Major Hayden
63faf9e7dc Adjusted key_buffer_size logic checks.\nChanged max_connections wording.\nAdded max_seeks_for_key check. 2007-08-03 02:27:37 +00:00
Major Hayden
6ca1761b3f Added explanations for key max_connections and fixed a Plesk bug when you run the script as a non-root user 2007-08-03 01:55:56 +00:00
Major Hayden
433c0b8749 Fixed bug with 'explainonly' argument. 2007-06-06 15:57:19 +00:00
Major Hayden
beaeaf26e8 Added option to disable colors.
Explanation option is disabled by default.
2007-06-06 15:31:48 +00:00
Major Hayden
a4f7c5bbe0 Completed long explanation portion for slow query log section.
Created 'explainonly' command line argument for long explanations only.
Adjusted memory usage long explanation.
2007-06-06 15:14:06 +00:00
Major Hayden
be69a0063a Initial verbose explain output configuration (there you go Mike!) 2007-06-04 16:31:29 +00:00
Major Hayden
4589601af0 Massive changes... output filtering, usage information, and temporary table corrections with regards to max memory calculations 2007-06-01 03:26:26 +00:00
Major Hayden
89044755e1 Changed all prints to use subroutines to allow for exclusions via command line arguments (coming up next) 2007-06-01 01:27:18 +00:00
Major Hayden
f76e2746a4 Script now requires MySQL 4.1 or higher (4.0 is EOL, and support for that is lame...) 2007-06-01 01:19:01 +00:00
Major Hayden
270bb7364f Corrected memory calculation issue in OS X / Darwin 2007-06-01 01:13:36 +00:00
Major Hayden
810df8eded Added check to see if MySQL is even installed 2007-06-01 01:03:11 +00:00
Major Hayden
d38d22a80a Initial Import 2007-05-31 03:30:15 +00:00