Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 11 Oct 2024 00:06:31 -0400
From:      Juan Manuel Palacios <jmpalacios@gmail.com>
To:        Udo Pokojski <freebsd@upokojski.de>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Mysql-Server not starting
Message-ID:  <CBD261A5-6D51-47D0-9A89-CDA8205B62C1@gmail.com>
In-Reply-To: <2b663bca-5579-41c8-9db3-02bf87424d0f@upokojski.de>
References:  <2b663bca-5579-41c8-9db3-02bf87424d0f@upokojski.de>

next in thread | previous in thread | raw e-mail | index | archive | help

[-- Attachment #1 --]
Hi Udo,

What I’d do in this case would be to, first and foremost, back up your data directory (zfs snapshot of the host would suffice, if you’re on that filesystem, with the service stopped of course —but is a given in this case—), and then start the service with InnoDB in recovery mode:

https://dev.mysql.com/doc/refman/8.4/en/forcing-innodb-recovery.html
I've seen similar errors to yours, but involving the InnoDB log files, e.g. ib_logfile0, which could be safely moved to the side to have the MySQL recreate it/them upon restart. But in your case it appears that it’s the ibdata files what are corrupt, which are the "system’s tablespace” files, https://dba.stackexchange.com/a/27106, so I’d definitely be more careful with those.

HTH!

> On Oct 10, 2024, at 4:08 PM, Udo Pokojski <freebsd@upokojski.de> wrote:
> 
> Hallo,
> 
> 
> after doing an pkg update and pkg upgrade on FreeBSD 13.3, I cannot start the mysql-server.
> 
> The command service mysql-server start returns no error.
> 
> 
> In the mysql error log, I can find the following messages:
> 
> 2024-10-10T19:55:15.913147Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
> 2024-10-10T19:55:16.148244Z 1 [ERROR] [MY-012263] [InnoDB] The Auto-extending innodb_system data file '/var/db/mysql/ibdata1' is of a different size 768 pages (rounded down to MB) than specified in the .cnf file: initial 8192 pages, max 0 (relevant if non-zero) pages!
> 2024-10-10T19:55:16.148370Z 1 [ERROR] [MY-012930] [InnoDB] Plugin initialization aborted with error Generic error.
> 2024-10-10T19:55:16.149901Z 1 [ERROR] [MY-010334] [Server] Failed to initialize DD Storage Engine
> 2024-10-10T19:55:16.150187Z 0 [ERROR] [MY-010020] [Server] Data Dictionary initialization failed.
> 2024-10-10T19:55:16.150233Z 0 [ERROR] [MY-010119] [Server] Aborting
> 
> 
> Something seems to wrong with my my.cnf file. The only line which affects the innodb file size is:
> 
> innodb_data_file_path           = ibdata1:128M:autoextend
> 
> I never changed this line an In have no idea how to fix the error.
> 
> Any help is appreciated.
> 
> 
> Thanks in advance,
> 
> Udo
> 
> 
> 
> 
> 
> 
> 
> 
> 


[-- Attachment #2 --]


Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CBD261A5-6D51-47D0-9A89-CDA8205B62C1>