MySQL server does not start because of a sequence number
MySQL uses InnoDB log files (ib_logfile0, ib_logfile1) to track changes to the database. These files contain a log sequence number (LSN) that must match the LSN stored in the InnoDB data file (ibdata1). If the numbers do not match — for example because the Mac went to sleep while MySQL was writing — MySQL refuses to start and logs an error like this:
10:12:32 1753 [Note] InnoDB: The log sequence numbers 609248312 and 609248312 in ibdata files do not match the log sequence number 609248322 in the ib_logfiles!Renaming the existing log files forces InnoDB to create new, consistent ones on the next startup.
-
Quit MAMP PRO.
-
In Finder, press ⌘ ⇧ G (or choose Go › Go to Folder) and navigate to the folder matching your active MySQL version:
MySQL 5.7:
/Library/Application Support/appsolute/MAMP PRO/db/mysql57MySQL 8.0:
/Library/Application Support/appsolute/MAMP PRO/db/mysql80 -
Rename
ib_logfile0toib_logfile0_bak. -
Rename
ib_logfile1toib_logfile1_bak. -
Start MAMP PRO. MySQL will automatically recreate both log files with a matching sequence number.
← MySQL