diff --git a/mysqltuner.pl b/mysqltuner.pl index cd860460..2f06e77c 100755 --- a/mysqltuner.pl +++ b/mysqltuner.pl @@ -1590,12 +1590,9 @@ sub log_file_recommendations { while ( my $logLi = <$fh> ) { chomp $logLi; $numLi++; - debugprint "$numLi: $logLi" - if $logLi =~ /warning|error/i and $logLi !~ /Logging to/; - $nbErrLog++ - if $logLi =~ /error/i - and $logLi !~ /(Logging to|\[Warning\].*ERROR_FOR_DIVISION_BY_ZERO)/; - $nbWarnLog++ if $logLi =~ /warning/i; + debugprint "$numLi: $logLi" if $logLi =~ /\[(warning|error)\]/i; + $nbErrLog++ if $logLi =~ /\[error\]/i; + $nbWarnLog++ if $logLi =~ /\[warning\]/i; push @lastShutdowns, $logLi if $logLi =~ /Shutdown complete/ and $logLi !~ /Innodb/i; push @lastStarts, $logLi if $logLi =~ /ready for connections/;