Update Vulnerabilities list
Indenting mysqltuner Update Usage information
This commit is contained in:
parent
57b4f69680
commit
390977624e
2 changed files with 102 additions and 290 deletions
189
mysqltuner.pl
189
mysqltuner.pl
|
@ -62,54 +62,54 @@ my ( @adjvars, @generalrec );
|
||||||
|
|
||||||
# Set defaults
|
# Set defaults
|
||||||
my %opt = (
|
my %opt = (
|
||||||
"silent" => 0,
|
"silent" => 0,
|
||||||
"nobad" => 0,
|
"nobad" => 0,
|
||||||
"nogood" => 0,
|
"nogood" => 0,
|
||||||
"noinfo" => 0,
|
"noinfo" => 0,
|
||||||
"debug" => 0,
|
"debug" => 0,
|
||||||
"nocolor" => ( !-t STDOUT ),
|
"nocolor" => ( !-t STDOUT ),
|
||||||
"color" => 0,
|
"color" => 0,
|
||||||
"forcemem" => 0,
|
"forcemem" => 0,
|
||||||
"forceswap" => 0,
|
"forceswap" => 0,
|
||||||
"host" => 0,
|
"host" => 0,
|
||||||
"socket" => 0,
|
"socket" => 0,
|
||||||
"port" => 0,
|
"port" => 0,
|
||||||
"user" => 0,
|
"user" => 0,
|
||||||
"pass" => 0,
|
"pass" => 0,
|
||||||
"password" => 0,
|
"password" => 0,
|
||||||
"ssl-ca" => 0,
|
"ssl-ca" => 0,
|
||||||
"skipsize" => 0,
|
"skipsize" => 0,
|
||||||
"checkversion" => 0,
|
"checkversion" => 0,
|
||||||
"updateversion" => 0,
|
"updateversion" => 0,
|
||||||
"buffers" => 0,
|
"buffers" => 0,
|
||||||
"passwordfile" => 0,
|
"passwordfile" => 0,
|
||||||
"bannedports" => '',
|
"bannedports" => '',
|
||||||
"maxportallowed" => 0,
|
"maxportallowed" => 0,
|
||||||
"outputfile" => 0,
|
"outputfile" => 0,
|
||||||
"noprocess" => 0,
|
"noprocess" => 0,
|
||||||
"dbstat" => 0,
|
"dbstat" => 0,
|
||||||
"nodbstat" => 0,
|
"nodbstat" => 0,
|
||||||
"server-log" => '',
|
"server-log" => '',
|
||||||
"tbstat" => 0,
|
"tbstat" => 0,
|
||||||
"notbstat" => 0,
|
"notbstat" => 0,
|
||||||
"colstat" => 0,
|
"colstat" => 0,
|
||||||
"nocolstat" => 0,
|
"nocolstat" => 0,
|
||||||
"idxstat" => 0,
|
"idxstat" => 0,
|
||||||
"noidxstat" => 0,
|
"noidxstat" => 0,
|
||||||
"sysstat" => 0,
|
"sysstat" => 0,
|
||||||
"nosysstat" => 0,
|
"nosysstat" => 0,
|
||||||
"pfstat" => 0,
|
"pfstat" => 0,
|
||||||
"nopfstat" => 0,
|
"nopfstat" => 0,
|
||||||
"skippassword" => 0,
|
"skippassword" => 0,
|
||||||
"noask" => 0,
|
"noask" => 0,
|
||||||
"template" => 0,
|
"template" => 0,
|
||||||
"json" => 0,
|
"json" => 0,
|
||||||
"prettyjson" => 0,
|
"prettyjson" => 0,
|
||||||
"reportfile" => 0,
|
"reportfile" => 0,
|
||||||
"verbose" => 0,
|
"verbose" => 0,
|
||||||
"defaults-file" => '',
|
"defaults-file" => '',
|
||||||
"defaults-extra-file" => '',
|
"defaults-extra-file" => '',
|
||||||
"protocol" => '',
|
"protocol" => '',
|
||||||
);
|
);
|
||||||
|
|
||||||
# Gather the options from the command line
|
# Gather the options from the command line
|
||||||
|
@ -204,7 +204,7 @@ if ( $opt{verbose} ) {
|
||||||
$opt{nocolor} = 1 if defined( $opt{outputfile} );
|
$opt{nocolor} = 1 if defined( $opt{outputfile} );
|
||||||
$opt{tbstat} = 0 if ( $opt{notbstat} == 1 ); # Don't print table information
|
$opt{tbstat} = 0 if ( $opt{notbstat} == 1 ); # Don't print table information
|
||||||
$opt{colstat} = 0 if ( $opt{nocolstat} == 1 ); # Don't print column information
|
$opt{colstat} = 0 if ( $opt{nocolstat} == 1 ); # Don't print column information
|
||||||
$opt{dbstat} = 0 if ( $opt{nodbstat} == 1 ); # Don't print database information
|
$opt{dbstat} = 0 if ( $opt{nodbstat} == 1 ); # Don't print database information
|
||||||
$opt{noprocess} = 0
|
$opt{noprocess} = 0
|
||||||
if ( $opt{noprocess} == 1 ); # Don't print process information
|
if ( $opt{noprocess} == 1 ); # Don't print process information
|
||||||
$opt{sysstat} = 0 if ( $opt{nosysstat} == 1 ); # Don't print sysstat information
|
$opt{sysstat} = 0 if ( $opt{nosysstat} == 1 ); # Don't print sysstat information
|
||||||
|
@ -326,7 +326,7 @@ sub hr_bytes {
|
||||||
return "0B" unless defined($num);
|
return "0B" unless defined($num);
|
||||||
return "0B" if $num eq "NULL";
|
return "0B" if $num eq "NULL";
|
||||||
|
|
||||||
if ( $num >= ( 1024**3 ) ) { # GB
|
if ( $num >= ( 1024**3 ) ) { # GB
|
||||||
return sprintf( "%.1f", ( $num / ( 1024**3 ) ) ) . "G";
|
return sprintf( "%.1f", ( $num / ( 1024**3 ) ) ) . "G";
|
||||||
}
|
}
|
||||||
elsif ( $num >= ( 1024**2 ) ) { # MB
|
elsif ( $num >= ( 1024**2 ) ) { # MB
|
||||||
|
@ -365,7 +365,7 @@ sub hr_bytes_rnd {
|
||||||
return "0B" unless defined($num);
|
return "0B" unless defined($num);
|
||||||
return "0B" if $num eq "NULL";
|
return "0B" if $num eq "NULL";
|
||||||
|
|
||||||
if ( $num >= ( 1024**3 ) ) { # GB
|
if ( $num >= ( 1024**3 ) ) { # GB
|
||||||
return int( ( $num / ( 1024**3 ) ) ) . "G";
|
return int( ( $num / ( 1024**3 ) ) ) . "G";
|
||||||
}
|
}
|
||||||
elsif ( $num >= ( 1024**2 ) ) { # MB
|
elsif ( $num >= ( 1024**2 ) ) { # MB
|
||||||
|
@ -917,17 +917,21 @@ sub mysql_setup {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elsif ( $opt{'defaults-extra-file'} ne '' and -r "$opt{'defaults-extra-file'}" ) {
|
elsif ( $opt{'defaults-extra-file'} ne ''
|
||||||
|
and -r "$opt{'defaults-extra-file'}" )
|
||||||
|
{
|
||||||
|
|
||||||
# defaults-extra-file
|
# defaults-extra-file
|
||||||
debugprint "defaults extra file detected: $opt{'defaults-extra-file'}";
|
debugprint "defaults extra file detected: $opt{'defaults-extra-file'}";
|
||||||
my $mysqlclidefaults = `$mysqlcmd --print-defaults`;
|
my $mysqlclidefaults = `$mysqlcmd --print-defaults`;
|
||||||
debugprint "MySQL Client Extra Default File: $opt{'defaults-extra-file'}";
|
debugprint
|
||||||
|
"MySQL Client Extra Default File: $opt{'defaults-extra-file'}";
|
||||||
|
|
||||||
$mysqllogin = "--defaults-extra-file=" . $opt{'defaults-extra-file'};
|
$mysqllogin = "--defaults-extra-file=" . $opt{'defaults-extra-file'};
|
||||||
my $loginstatus = `$mysqladmincmd $mysqllogin ping 2>&1`;
|
my $loginstatus = `$mysqladmincmd $mysqllogin ping 2>&1`;
|
||||||
if ( $loginstatus =~ /mysqld is alive/ ) {
|
if ( $loginstatus =~ /mysqld is alive/ ) {
|
||||||
goodprint "Logged in using credentials from extra defaults file account.";
|
goodprint
|
||||||
|
"Logged in using credentials from extra defaults file account.";
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1190,7 +1194,7 @@ sub get_all_vars {
|
||||||
$dummyselect = select_one "SELECT VERSION()";
|
$dummyselect = select_one "SELECT VERSION()";
|
||||||
if ( not defined($dummyselect) or $dummyselect eq "" ) {
|
if ( not defined($dummyselect) or $dummyselect eq "" ) {
|
||||||
badprint
|
badprint
|
||||||
"You probably do not have enough privileges to run MySQLTuner ...";
|
"You probably do not have enough privileges to run MySQLTuner ...";
|
||||||
exit(256);
|
exit(256);
|
||||||
}
|
}
|
||||||
$dummyselect =~ s/(.*?)\-.*/$1/;
|
$dummyselect =~ s/(.*?)\-.*/$1/;
|
||||||
|
@ -1288,8 +1292,8 @@ sub get_all_vars {
|
||||||
my @lineitems = ();
|
my @lineitems = ();
|
||||||
foreach my $line (@mysqlslaves) {
|
foreach my $line (@mysqlslaves) {
|
||||||
debugprint "L: $line ";
|
debugprint "L: $line ";
|
||||||
@lineitems = split /\s+/, $line;
|
@lineitems = split /\s+/, $line;
|
||||||
$myslaves{ $lineitems[0] } = $line;
|
$myslaves{ $lineitems[0] } = $line;
|
||||||
$result{'Replication'}{'Slaves'}{ $lineitems[0] } = $lineitems[4];
|
$result{'Replication'}{'Slaves'}{ $lineitems[0] } = $lineitems[4];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1440,7 +1444,7 @@ sub log_file_recommendations {
|
||||||
$numLi++;
|
$numLi++;
|
||||||
debugprint "$numLi: $logLi"
|
debugprint "$numLi: $logLi"
|
||||||
if $logLi =~ /warning|error/i and $logLi !~ /Logging to/;
|
if $logLi =~ /warning|error/i and $logLi !~ /Logging to/;
|
||||||
$nbErrLog++ if $logLi =~ /error/i and $logLi !~ /Logging to/;
|
$nbErrLog++ if $logLi =~ /error/i and $logLi !~ /Logging to/;
|
||||||
$nbWarnLog++ if $logLi =~ /warning/i;
|
$nbWarnLog++ if $logLi =~ /warning/i;
|
||||||
push @lastShutdowns, $logLi
|
push @lastShutdowns, $logLi
|
||||||
if $logLi =~ /Shutdown complete/ and $logLi !~ /Innodb/i;
|
if $logLi =~ /Shutdown complete/ and $logLi !~ /Innodb/i;
|
||||||
|
@ -2204,7 +2208,7 @@ sub get_replication_status {
|
||||||
"This replication slave is not running but seems to be configured.";
|
"This replication slave is not running but seems to be configured.";
|
||||||
}
|
}
|
||||||
if ( defined($io_running)
|
if ( defined($io_running)
|
||||||
&& $io_running =~ /yes/i
|
&& $io_running =~ /yes/i
|
||||||
&& $sql_running =~ /yes/i )
|
&& $sql_running =~ /yes/i )
|
||||||
{
|
{
|
||||||
if ( $myvar{'read_only'} eq 'OFF' ) {
|
if ( $myvar{'read_only'} eq 'OFF' ) {
|
||||||
|
@ -2254,7 +2258,8 @@ sub validate_mysql_version {
|
||||||
. $myvar{'version'}
|
. $myvar{'version'}
|
||||||
. " is EOL software. Upgrade soon!";
|
. " is EOL software. Upgrade soon!";
|
||||||
push( @generalrec,
|
push( @generalrec,
|
||||||
"You are using an unsupported version for production environments" );
|
"You are using an unsupported version for production environments"
|
||||||
|
);
|
||||||
push( @generalrec,
|
push( @generalrec,
|
||||||
"Upgrade as soon as possible to a supported version !" );
|
"Upgrade as soon as possible to a supported version !" );
|
||||||
|
|
||||||
|
@ -2554,7 +2559,7 @@ sub check_storage_engines {
|
||||||
{
|
{
|
||||||
badprint "MyISAM is enabled but isn't being used";
|
badprint "MyISAM is enabled but isn't being used";
|
||||||
push( @generalrec,
|
push( @generalrec,
|
||||||
"Add skip-isam to MySQL configuration to disable MyISAM (MySQL > 4.1.0)"
|
"Add skip-isam to MySQL configuration to disable MyISAM (MySQL > 4.1.0)"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2562,24 +2567,26 @@ sub check_storage_engines {
|
||||||
if ( $fragtables > 0 ) {
|
if ( $fragtables > 0 ) {
|
||||||
badprint "Total fragmented tables: $fragtables";
|
badprint "Total fragmented tables: $fragtables";
|
||||||
push @generalrec,
|
push @generalrec,
|
||||||
'Run ALTER TABLE ... FORCE or OPTIMIZE TABLE to defragment tables for better performance';
|
'Run ALTER TABLE ... FORCE or OPTIMIZE TABLE to defragment tables for better performance';
|
||||||
my $total_free = 0;
|
my $total_free = 0;
|
||||||
foreach my $table_line ( @{ $result{'Tables'}{'Fragmented tables'} } ) {
|
foreach my $table_line ( @{ $result{'Tables'}{'Fragmented tables'} } ) {
|
||||||
my ( $table_schema, $table_name, $engine, $data_free ) =
|
my ( $table_schema, $table_name, $engine, $data_free ) =
|
||||||
split /\t/msx, $table_line;
|
split /\t/msx, $table_line;
|
||||||
$data_free = $data_free / 1024 / 1024;
|
$data_free = $data_free / 1024 / 1024;
|
||||||
$total_free += $data_free;
|
$total_free += $data_free;
|
||||||
my $generalrec;
|
my $generalrec;
|
||||||
if ( $engine eq 'InnoDB' ) {
|
if ( $engine eq 'InnoDB' ) {
|
||||||
$generalrec = " ALTER TABLE `$table_schema`.`$table_name` FORCE;";
|
$generalrec =
|
||||||
} else {
|
" ALTER TABLE `$table_schema`.`$table_name` FORCE;";
|
||||||
|
}
|
||||||
|
else {
|
||||||
$generalrec = " OPTIMIZE TABLE `$table_schema`.`$table_name`;";
|
$generalrec = " OPTIMIZE TABLE `$table_schema`.`$table_name`;";
|
||||||
}
|
}
|
||||||
$generalrec .= " -- can free $data_free MiB";
|
$generalrec .= " -- can free $data_free MiB";
|
||||||
push @generalrec, $generalrec;
|
push @generalrec, $generalrec;
|
||||||
}
|
}
|
||||||
push @generalrec,
|
push @generalrec,
|
||||||
"Total freed space after defragmentation : $total_free MiB";
|
"Total freed space after defragmentation : $total_free MiB";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
goodprint "Total fragmented tables: $fragtables";
|
goodprint "Total fragmented tables: $fragtables";
|
||||||
|
@ -2636,8 +2643,7 @@ my %mycalc;
|
||||||
|
|
||||||
sub calculations {
|
sub calculations {
|
||||||
if ( $mystat{'Questions'} < 1 ) {
|
if ( $mystat{'Questions'} < 1 ) {
|
||||||
badprint
|
badprint "Your server has not answered any queries: cannot continue...";
|
||||||
"Your server has not answered any queries: cannot continue...";
|
|
||||||
exit 2;
|
exit 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3066,7 +3072,8 @@ sub mysql_stats {
|
||||||
. " global + "
|
. " global + "
|
||||||
. hr_bytes( $mycalc{'per_thread_buffers'} )
|
. hr_bytes( $mycalc{'per_thread_buffers'} )
|
||||||
. " per thread ($myvar{'max_connections'} max threads)";
|
. " per thread ($myvar{'max_connections'} max threads)";
|
||||||
infoprint "Performance_schema Max memory usage: " . hr_bytes_rnd( get_pf_memory() );
|
infoprint "Performance_schema Max memory usage: "
|
||||||
|
. hr_bytes_rnd( get_pf_memory() );
|
||||||
$result{'Performance_schema'}{'memory'} = get_pf_memory();
|
$result{'Performance_schema'}{'memory'} = get_pf_memory();
|
||||||
$result{'Performance_schema'}{'pretty_memory'} =
|
$result{'Performance_schema'}{'pretty_memory'} =
|
||||||
hr_bytes_rnd( get_pf_memory() );
|
hr_bytes_rnd( get_pf_memory() );
|
||||||
|
@ -3680,8 +3687,8 @@ sub mysql_myisam {
|
||||||
if ( $mycalc{'pct_key_buffer_used'} < 90 ) {
|
if ( $mycalc{'pct_key_buffer_used'} < 90 ) {
|
||||||
badprint "Key buffer used: $mycalc{'pct_key_buffer_used'}% ("
|
badprint "Key buffer used: $mycalc{'pct_key_buffer_used'}% ("
|
||||||
. hr_bytes( $myvar{'key_buffer_size'} -
|
. hr_bytes( $myvar{'key_buffer_size'} -
|
||||||
$mystat{'Key_blocks_unused'} *
|
$mystat{'Key_blocks_unused'} * $myvar{'key_cache_block_size'}
|
||||||
$myvar{'key_cache_block_size'} )
|
)
|
||||||
. " used / "
|
. " used / "
|
||||||
. hr_bytes( $myvar{'key_buffer_size'} )
|
. hr_bytes( $myvar{'key_buffer_size'} )
|
||||||
. " cache)";
|
. " cache)";
|
||||||
|
@ -3699,8 +3706,8 @@ sub mysql_myisam {
|
||||||
else {
|
else {
|
||||||
goodprint "Key buffer used: $mycalc{'pct_key_buffer_used'}% ("
|
goodprint "Key buffer used: $mycalc{'pct_key_buffer_used'}% ("
|
||||||
. hr_bytes( $myvar{'key_buffer_size'} -
|
. hr_bytes( $myvar{'key_buffer_size'} -
|
||||||
$mystat{'Key_blocks_unused'} *
|
$mystat{'Key_blocks_unused'} * $myvar{'key_cache_block_size'}
|
||||||
$myvar{'key_cache_block_size'} )
|
)
|
||||||
. " used / "
|
. " used / "
|
||||||
. hr_bytes( $myvar{'key_buffer_size'} )
|
. hr_bytes( $myvar{'key_buffer_size'} )
|
||||||
. " cache)";
|
. " cache)";
|
||||||
|
@ -3908,16 +3915,17 @@ sub mysqsl_pfs {
|
||||||
if ( $myvar{'performance_schema'} eq 'ON' ) {
|
if ( $myvar{'performance_schema'} eq 'ON' ) {
|
||||||
infoprint "Performance_schema is activated.";
|
infoprint "Performance_schema is activated.";
|
||||||
debugprint "Performance schema is " . $myvar{'performance_schema'};
|
debugprint "Performance schema is " . $myvar{'performance_schema'};
|
||||||
infoprint "Memory used by Performance_schema: " . hr_bytes( get_pf_memory() );
|
infoprint "Memory used by Performance_schema: "
|
||||||
|
. hr_bytes( get_pf_memory() );
|
||||||
}
|
}
|
||||||
|
|
||||||
unless ( grep /^sys$/, select_array("SHOW DATABASES") ) {
|
unless ( grep /^sys$/, select_array("SHOW DATABASES") ) {
|
||||||
infoprint "Sys schema is not installed.";
|
infoprint "Sys schema is not installed.";
|
||||||
push( @generalrec,
|
push( @generalrec,
|
||||||
"Consider installing Sys schema from https://github.com/mysql/mysql-sys for MySQL"
|
"Consider installing Sys schema from https://github.com/mysql/mysql-sys for MySQL"
|
||||||
) unless ( mysql_version_le( 5, 6 ) );
|
) unless ( mysql_version_le( 5, 6 ) );
|
||||||
push( @generalrec,
|
push( @generalrec,
|
||||||
"Consider installing Sys schema from https://github.com/FromDual/mariadb-sys for MariaDB"
|
"Consider installing Sys schema from https://github.com/FromDual/mariadb-sys for MariaDB"
|
||||||
) unless ( mysql_version_ge( 10, 0 ) );
|
) unless ( mysql_version_ge( 10, 0 ) );
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
@ -5620,19 +5628,19 @@ having sum(if(c.column_key in ('PRI','UNI'), 1,0)) = 0"
|
||||||
or get_wsrep_option('wsrep_slave_threads') < ( (cpu_cores) * 2 ) )
|
or get_wsrep_option('wsrep_slave_threads') < ( (cpu_cores) * 2 ) )
|
||||||
{
|
{
|
||||||
badprint
|
badprint
|
||||||
"wsrep_slave_threads is not equal to 2, 3 or 4 times the number of CPU(s)";
|
"wsrep_slave_threads is not equal to 2, 3 or 4 times the number of CPU(s)";
|
||||||
push @adjvars, "wsrep_slave_threads = " . ( (cpu_cores) * 4 );
|
push @adjvars, "wsrep_slave_threads = " . ( (cpu_cores) * 4 );
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
goodprint
|
goodprint
|
||||||
"wsrep_slave_threads is equal to 2, 3 or 4 times the number of CPU(s)";
|
"wsrep_slave_threads is equal to 2, 3 or 4 times the number of CPU(s)";
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( get_wsrep_option('wsrep_slave_threads') > 1 ) {
|
if ( get_wsrep_option('wsrep_slave_threads') > 1 ) {
|
||||||
infoprint
|
infoprint
|
||||||
"wsrep parallel slave can cause frequent inconsistency crash.";
|
"wsrep parallel slave can cause frequent inconsistency crash.";
|
||||||
push @adjvars,
|
push @adjvars,
|
||||||
"Set wsrep_slave_threads to 1 in case of HA_ERR_FOUND_DUPP_KEY crash on slave";
|
"Set wsrep_slave_threads to 1 in case of HA_ERR_FOUND_DUPP_KEY crash on slave";
|
||||||
|
|
||||||
# check options for parallel slave
|
# check options for parallel slave
|
||||||
if ( get_wsrep_option('wsrep_slave_FK_checks') eq "OFF" ) {
|
if ( get_wsrep_option('wsrep_slave_FK_checks') eq "OFF" ) {
|
||||||
|
@ -5675,7 +5683,7 @@ having sum(if(c.column_key in ('PRI','UNI'), 1,0)) = 0"
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
goodprint
|
goodprint
|
||||||
"Flow control fraction seems to be OK (wsrep_flow_control_paused <= 0.02)";
|
"Flow control fraction seems to be OK (wsrep_flow_control_paused <= 0.02)";
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( scalar(@primaryKeysNbTables) > 0 ) {
|
if ( scalar(@primaryKeysNbTables) > 0 ) {
|
||||||
|
@ -5737,14 +5745,14 @@ having sum(if(c.column_key in ('PRI','UNI'), 1,0)) = 0"
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
badprint
|
badprint
|
||||||
"There are $nbNodesSize nodes in wsrep_cluster_size. Prefer 3 or 5 nodes architecture.";
|
"There are $nbNodesSize nodes in wsrep_cluster_size. Prefer 3 or 5 nodes architecture.";
|
||||||
push @generalrec, "Prefer 3 or 5 nodes architecture.";
|
push @generalrec, "Prefer 3 or 5 nodes architecture.";
|
||||||
}
|
}
|
||||||
|
|
||||||
# wsrep_cluster_address doesn't include garbd nodes
|
# wsrep_cluster_address doesn't include garbd nodes
|
||||||
if ( $nbNodes > $nbNodesSize ) {
|
if ( $nbNodes > $nbNodesSize ) {
|
||||||
badprint
|
badprint
|
||||||
"All cluster nodes are not detected. wsrep_cluster_size less than node count in wsrep_cluster_address";
|
"All cluster nodes are not detected. wsrep_cluster_size less than node count in wsrep_cluster_address";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
goodprint "All cluster nodes detected.";
|
goodprint "All cluster nodes detected.";
|
||||||
|
@ -5782,14 +5790,15 @@ having sum(if(c.column_key in ('PRI','UNI'), 1,0)) = 0"
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
badprint "Galera Notify command is not defined.";
|
badprint "Galera Notify command is not defined.";
|
||||||
push( @adjvars, "set up parameter wsrep_notify_cmd to be notified" );
|
push( @adjvars,
|
||||||
|
"set up parameter wsrep_notify_cmd to be notified" );
|
||||||
}
|
}
|
||||||
if ( trim( $myvar{'wsrep_sst_method'} ) !~ "^xtrabackup.*"
|
if ( trim( $myvar{'wsrep_sst_method'} ) !~ "^xtrabackup.*"
|
||||||
and trim( $myvar{'wsrep_sst_method'} ) !~ "^mariabackup" )
|
and trim( $myvar{'wsrep_sst_method'} ) !~ "^mariabackup" )
|
||||||
{
|
{
|
||||||
badprint "Galera SST method is not xtrabackup based.";
|
badprint "Galera SST method is not xtrabackup based.";
|
||||||
push( @adjvars,
|
push( @adjvars,
|
||||||
"set up parameter wsrep_sst_method to xtrabackup based parameter"
|
"set up parameter wsrep_sst_method to xtrabackup based parameter"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -5891,10 +5900,10 @@ sub mysql_innodb {
|
||||||
$defengine = $myvar{'default_storage_engine'}
|
$defengine = $myvar{'default_storage_engine'}
|
||||||
if defined( $myvar{'default_storage_engine'} );
|
if defined( $myvar{'default_storage_engine'} );
|
||||||
badprint
|
badprint
|
||||||
"InnoDB Storage engine is disabled. $defengine is the default storage engine"
|
"InnoDB Storage engine is disabled. $defengine is the default storage engine"
|
||||||
if $defengine eq 'InnoDB';
|
if $defengine eq 'InnoDB';
|
||||||
infoprint
|
infoprint
|
||||||
"InnoDB Storage engine is disabled. $defengine is the default storage engine"
|
"InnoDB Storage engine is disabled. $defengine is the default storage engine"
|
||||||
if $defengine ne 'InnoDB';
|
if $defengine ne 'InnoDB';
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
@ -6557,7 +6566,7 @@ sub mysql_indexes {
|
||||||
subheaderprint "Indexes Metrics";
|
subheaderprint "Indexes Metrics";
|
||||||
unless ( mysql_version_ge( 5, 5 ) ) {
|
unless ( mysql_version_ge( 5, 5 ) ) {
|
||||||
infoprint
|
infoprint
|
||||||
"Skip Index metrics from information schema are missing in this version";
|
"Skip Index metrics from information schema are missing in this version";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6684,7 +6693,7 @@ sub mysql_views() {
|
||||||
subheaderprint "Views Metrics";
|
subheaderprint "Views Metrics";
|
||||||
unless ( mysql_version_ge( 5, 5 ) ) {
|
unless ( mysql_version_ge( 5, 5 ) ) {
|
||||||
infoprint
|
infoprint
|
||||||
"Skip Index metrics from information schema are missing in this version";
|
"Skip Index metrics from information schema are missing in this version";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -6693,7 +6702,7 @@ sub mysql_routines() {
|
||||||
subheaderprint "Routines Metrics";
|
subheaderprint "Routines Metrics";
|
||||||
unless ( mysql_version_ge( 5, 5 ) ) {
|
unless ( mysql_version_ge( 5, 5 ) ) {
|
||||||
infoprint
|
infoprint
|
||||||
"Skip Index metrics from information schema are missing in this version";
|
"Skip Index metrics from information schema are missing in this version";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -6702,7 +6711,7 @@ sub mysql_triggers() {
|
||||||
subheaderprint "Triggers Metrics";
|
subheaderprint "Triggers Metrics";
|
||||||
unless ( mysql_version_ge( 5, 5 ) ) {
|
unless ( mysql_version_ge( 5, 5 ) ) {
|
||||||
infoprint
|
infoprint
|
||||||
"Skip Index metrics from information schema are missing in this version";
|
"Skip Index metrics from information schema are missing in this version";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue