Generate 2.5.2 sub version at 2024-02-06T17:58:35+01:00
This commit is contained in:
parent
b3a776576e
commit
30d1d9ecc6
2 changed files with 62 additions and 44 deletions
2
USAGE.md
2
USAGE.md
|
@ -1,6 +1,6 @@
|
||||||
# NAME
|
# NAME
|
||||||
|
|
||||||
MySQLTuner 2.5.1 - MySQL High Performance Tuning Script
|
MySQLTuner 2.5.2 - MySQL High Performance Tuning Script
|
||||||
|
|
||||||
# IMPORTANT USAGE GUIDELINES
|
# IMPORTANT USAGE GUIDELINES
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
#!/usr/bin/env perl
|
# mysqltuner.pl - Version 2.5.2
|
||||||
# mysqltuner.pl - Version 2.5.1
|
|
||||||
# High Performance MySQL Tuning Script
|
# High Performance MySQL Tuning Script
|
||||||
# Copyright (C) 2015-2023 Jean-Marie Renouard - jmrenouard@gmail.com
|
# Copyright (C) 2015-2023 Jean-Marie Renouard - jmrenouard@gmail.com
|
||||||
# Copyright (C) 2006-2023 Major Hayden - major@mhtx.net
|
# Copyright (C) 2006-2023 Major Hayden - major@mhtx.net
|
||||||
|
@ -57,7 +56,7 @@ use Cwd 'abs_path';
|
||||||
#use Env;
|
#use Env;
|
||||||
|
|
||||||
# Set up a few variables for use in the script
|
# Set up a few variables for use in the script
|
||||||
my $tunerversion = "2.5.1";
|
my $tunerversion = "2.5.2";
|
||||||
my ( @adjvars, @generalrec );
|
my ( @adjvars, @generalrec );
|
||||||
|
|
||||||
# Set defaults
|
# Set defaults
|
||||||
|
@ -2526,7 +2525,7 @@ sub check_architecture {
|
||||||
}
|
}
|
||||||
elsif ( `uname` =~ /Darwin/ && `uname -m` =~ /x86_64/ ) {
|
elsif ( `uname` =~ /Darwin/ && `uname -m` =~ /x86_64/ ) {
|
||||||
|
|
||||||
# Darwin gibas.local 12.5.1 Darwin Kernel Version 12.3.0: Sun Jan 6 22:37:10 PST 2013; root:xnu-2050.22.13~1/RELEASE_X86_64 x86_64
|
# Darwin gibas.local 12.5.2 Darwin Kernel Version 12.3.0: Sun Jan 6 22:37:10 PST 2013; root:xnu-2050.22.13~1/RELEASE_X86_64 x86_64
|
||||||
$arch = 64;
|
$arch = 64;
|
||||||
goodprint "Operating on 64-bit architecture";
|
goodprint "Operating on 64-bit architecture";
|
||||||
}
|
}
|
||||||
|
@ -3211,6 +3210,11 @@ sub calculations {
|
||||||
$mystat{'Innodb_buffer_pool_pages_total'}
|
$mystat{'Innodb_buffer_pool_pages_total'}
|
||||||
) if defined $mystat{'Innodb_buffer_pool_pages_total'};
|
) if defined $mystat{'Innodb_buffer_pool_pages_total'};
|
||||||
|
|
||||||
|
$mycalc{'innodb_buffer_alloc_pct'}=select_one(
|
||||||
|
"select round( 100* sum(allocated)/( select VARIABLE_VALUE ".
|
||||||
|
"FROM performance_schema.global_variables " .
|
||||||
|
"WHERE VARIABLE_NAME='innodb_buffer_pool_size' ) ,2)".
|
||||||
|
'FROM sys.x\$innodb_buffer_stats_by_table;');
|
||||||
# Binlog Cache
|
# Binlog Cache
|
||||||
if ( $myvar{'log_bin'} ne 'OFF' ) {
|
if ( $myvar{'log_bin'} ne 'OFF' ) {
|
||||||
$mycalc{'pct_binlog_cache'} = percentage(
|
$mycalc{'pct_binlog_cache'} = percentage(
|
||||||
|
@ -6355,6 +6359,20 @@ sub mysql_innodb {
|
||||||
. hr_bytes( $enginestats{'InnoDB'} )
|
. hr_bytes( $enginestats{'InnoDB'} )
|
||||||
. ") if possible." );
|
. ") if possible." );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# select round( 100* sum(allocated)/( select VARIABLE_VALUE
|
||||||
|
# FROM performance_schema.global_variables
|
||||||
|
# where VARIABLE_NAME='innodb_buffer_pool_size' )
|
||||||
|
# ,2) as "PCT ALLOC/BUFFER POOL"
|
||||||
|
#from sys.x$innodb_buffer_stats_by_table;
|
||||||
|
|
||||||
|
if ($mycalc{innodb_buffer_alloc_pct} < 80) {
|
||||||
|
badprint "Ratio Buffer Pool allocated / Buffer Pool Size: ".
|
||||||
|
$mycalc{'innodb_buffer_alloc_pct'} . '%';
|
||||||
|
} else {
|
||||||
|
goodprint "Ratio Buffer Pool allocated / Buffer Pool Size: ".
|
||||||
|
$mycalc{'innodb_buffer_alloc_pct'} . '%';
|
||||||
|
}
|
||||||
if ( $mycalc{'innodb_log_size_pct'} < 20
|
if ( $mycalc{'innodb_log_size_pct'} < 20
|
||||||
or $mycalc{'innodb_log_size_pct'} > 30 )
|
or $mycalc{'innodb_log_size_pct'} > 30 )
|
||||||
{
|
{
|
||||||
|
@ -7371,7 +7389,7 @@ __END__
|
||||||
|
|
||||||
=head1 NAME
|
=head1 NAME
|
||||||
|
|
||||||
MySQLTuner 2.5.1 - MySQL High Performance Tuning Script
|
MySQLTuner 2.5.2 - MySQL High Performance Tuning Script
|
||||||
|
|
||||||
=head1 IMPORTANT USAGE GUIDELINES
|
=head1 IMPORTANT USAGE GUIDELINES
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue