Bug #115886 Crash recovery logs after clean restart with log_error_verbosity = 3.
Submitted: 21 Aug 2024 19:15 Modified: 22 Aug 2024 7:06
Reporter: Jean-François Gagné Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: InnoDB storage engine Severity:S3 (Non-critical)
Version:8.0.39, 8.4.2, 9.0.1 OS:Any
Assigned to: CPU Architecture:Any

[21 Aug 2024 19:15] Jean-François Gagné
Description:
Hi,

when I cleanly restart MySQL with log_error_verbosity = 3, I have crash recovery messages in the error log.  But after a clean stop, I do not expect crash recovery messages in the logs.  See How to repeat for details.

How to repeat for 8.0.39, but I am also able to reproduce the same with 8.4.2 and 9.0.1.

Many thanks for looking into this,

Jean-François Gagné

How to repeat:
dbdeployer deploy single 8.0.39

function my_test() {
  local pid=$(cat data/mysql_sandbox*.pid)

  date
  ./use -N <<< "
    set persist log_error_verbosity = 3;
    set global innodb_fast_shutdown = 0;
    shutdown"

  while sleep 1; do ps -p $pid | grep -q $pid || break; done

  date
  ./start > /dev/null

  grep -i -e crash -e recovery data/msandbox.err 
}

my_test
Wed 21 Aug 2024 15:10:16 EDT
Wed 21 Aug 2024 15:10:17 EDT
2024-08-21T19:10:17.671148Z 1 [Note] [MY-011980] [InnoDB] GTID recovery trx_no: 1329
2024-08-21T19:10:17.715277Z 0 [Note] [MY-010856] [Server] Failed to open the crashed binlog file when source server is recovering it.
2024-08-21T19:10:17.717157Z 0 [Note] [MY-013911] [Server] Crash recovery finished in binlog engine. No attempts to commit, rollback or prepare any transactions.
2024-08-21T19:10:17.717165Z 0 [Note] [MY-013911] [Server] Crash recovery finished in InnoDB engine. No attempts to commit, rollback or prepare any transactions.
2024-08-21T19:10:17.717529Z 0 [Note] [MY-012487] [InnoDB] DDL log recovery : begin
2024-08-21T19:10:17.717544Z 0 [Note] [MY-012488] [InnoDB] DDL log recovery : end

Suggested fix:
Do not show crash recovery messages after a clean shutdown.

And if some of these messages are meaningful, avoid terminology that can confuse the operator, including recovery, crashed, and crash recovery.
[22 Aug 2024 7:06] MySQL Verification Team
Hello Jean-François,

Thank you for the report and feedback.
Verified as described.

regards,
Umesh