Workaround: Embedded Connection Error mysql_server_init failed

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Gloegg
Posts: 6
Joined: Sun 15 Apr 2007 10:52
Location: Germany

Workaround: Embedded Connection Error mysql_server_init failed

Post by Gloegg » Sun 15 Apr 2007 11:23

Hi Folks,
I encountered a problem with the TMyEmbConnection.
I used MyDAC version 4.40 and 5.0 and MySQL version 4.1 and 5.0 and all possible combinations of it.
IDE is Borland Developer Studio 2006.

Some other guys encountered this problem too:
http://crlab.com/forums/viewtopic.php?t ... serverinit
http://crlab.com/forums/viewtopic.php?t ... serverinit

The Problem:
Before connecting, InnoDB creates some Files in the data-directory:
(Ibdata1, ib_logfile0, ib_logfile1)
If these files already exist (e.g. second time of executing your program) InnoDB crashes because these files cannot be created (since they're already there)

error-log:

Code: Select all

070415 13:12:10  InnoDB: Operating system error number 0 in a file operation.
InnoDB: Some operating system error numbers are described at
InnoDB: http://dev.mysql.com/doc/mysql/en/Operating_System_error_codes.html
InnoDB: File name K:\dev\projects\Rangliste\data\ibdata1
InnoDB: File operation call: 'create'.
InnoDB: Cannot continue operation.
Here comes the workaround:
Just disable InnoDB at the Params-Tab in the Connection-Editor (Rightclick on the TMyEmbConnection -> Connection-Editor)

Another advantage: You save 20 MB in the data-directory ;-)

Since I encountered this problem at developing, there's no guarantee for Embedded Databases in a productive environment.

I'd appreciate your comments.

Antaeus
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Post by Antaeus » Tue 17 Apr 2007 13:25

This can be a solution. But disabling InnoDB prevents you from using all the advantages of InnoDB like transaction-safe tables, row-level locking, etc.

Post Reply