O'Reilly logo

MySQL 8 Cookbook by Karthik Appigatla

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Changing the number or size of InnoDB redo log files

The ib_logfile0 file and ib_logfile1 are the default InnoDB redo log files created inside the data directory, with 48 MB each. If you wish to change the size of the redo log files, you can simply change it in the configuration file and restart MySQL. In previous versions, you had to do a slow shutdown of MySQL server, remove the redo log files, change the config file, and then start MySQL server.

As of MySQL 8, InnoDB detects that the innodb_log_file_size differs from the redo log file size. It writes a log checkpoint, closes and removes the old log files, creates new log files at the requested size, and opens the new log files.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required