0

I was upgrading Ubunto from 18 to 20, and lost SSH during mysql upgrade.

Mysql won't start now. It has the error:

ib_logfile0 size 44895232 is not a multiple of innodb_page_size after Ubuntu upgrade

InnoDB: Error: log file ./ib_logfile0 is of different size I tried the suggestion here to no avail.

2022-07-25T17:25:13.890483Z 1 [ERROR] [MY-012962] [InnoDB] Log file ./ib_logfile0 size 44895232 is not a multiple of innodb_page_size
2022-07-25T17:25:13.890544Z 1 [ERROR] [MY-012930] [InnoDB] Plugin initialization aborted with error Generic error.
2022-07-25T17:25:14.375381Z 1 [ERROR] [MY-010334] [Server] Failed to initialize DD Storage Engine
2022-07-25T17:25:14.375568Z 0 [ERROR] [MY-010020] [Server] Data Dictionary initialization failed.
2022-07-25T17:25:14.375652Z 0 [ERROR] [MY-010119] [Server] Aborting

Almost all posts I found have the same suggestion, so I am lost.

  1. deleted the 2 log files

  2. set my innodb settings as found in another post (see below)

     innodb_fast_shutdown =0
     innodb_buffer_pool_size = 2560M
     innodb_log_file_size    = 256M
     innodb_log_buffer_size  = 8M
     innodb_flush_log_at_trx_commit  = 2
     innodb_thread_concurrency   = 16
     innodb_flush_method = O_DIRECT
    
Rick James
  • 2,058
  • 5
  • 11
TDawg
  • 99
  • 2

1 Answers1

3

innodb_page_size is by default 16K which is 16384 and your innodb_log_file_size seems to be corrupted in half way during upgrade. When you say you lost ssh, does that mean server was rebooted? you might need to take a backup of ib_logfile0 and move out of data directory and try starting mysql with innodb_page_size as default. Your data dictionary is already created with 16k page size so it wont accept new value.

Remove innodb_page_size variable from conf and let it be default. Backup ib_logfile0 and move it out of data directory. When you will start mysql it will generate a new one. Post if any more errors.

  • I tried the responses. Removing the innodb_page_size brought back the Log file ./ib_logfile0 size 1024 is not a multiple of innodb_page_size error. (i removed the 2 log files from the directory also) – TDawg Jul 26 '22 at 08:01
  • 1
    before your error was Log file ./ib_logfile0 size 44895232 is not and now it is ib_logfile0 size 1024 so somewhere in my.cnf you have defined incorrect innodb_log_file_size. you might need to remove and let it be default if you dont want to extend it. What version of mysql you are using? Can you post the whole my.cnf? – yunus shaikh Jul 27 '22 at 03:10
  • Yunus, thank you so much for the feedback, I am sure with your help I would have got it. I had a month old backup, I restored it, because following too many tutorials I had no idea what I did and where. – TDawg Jul 27 '22 at 06:36
  • Good to know you were able to solve with your old backup – yunus shaikh Jul 28 '22 at 07:03