Cannot use Engine12.dll with Firebird 5.0

364 views
Skip to first unread message

Pierre Y.

unread,
Jan 12, 2024, 6:19:14 AM1/12/24
to firebird...@googlegroups.com
Hello,

I plan to migrate my customers from Firebird 3.0.11 to Firebird 5.0 by deploying Firebird 5.0 with the Engine12.dll from Firebird 3.0.11

I changed firebird.conf to :

# ----------------------------
# This parameter determines what providers will be used by Firebird.
# Format is the same as for the list of plugins (see above). Internally,
# a provider is just a kind of plugin.
#
# Type: string
#
# Per-database & per-connection configurable.
#
Providers = Remote,Engine12,Engine13,Loopback

(not sure in which order I should set this option, BTW, any hints ?)

When I try to connect to the database using Firebird 3.0.11 fbclient.dll using inet:// connection string, I get this error :

PRYBOOK Fri Jan 12 10:05:17 2024
Authentication error
Error loading plugin Engine12
Module C:\Program Files\Firebird\5.0\plugins\Engine12 exists but can not be loaded
Le module spécifié est introuvable. # The specified module cannot be found

Is it supposed to work ? Should I do something different ?

Many thanks,

--
Pierre Y.

Dimitry Sibiryakov

unread,
Jan 12, 2024, 6:23:12 AM1/12/24
to firebird...@googlegroups.com
Pierre Y. wrote 12.01.2024 12:19:
> Is it supposed to work ?

Yes, it is supposed to work but you must know that 32 bits application cannot
load 64 bits libraries and vice versa.
Besides, engine12.dll has dependencies which must be copied as well.

--
WBR, SD.

Mark Rotteveel

unread,
Jan 12, 2024, 6:43:09 AM1/12/24
to firebird...@googlegroups.com
On 12/01/2024 12:19, Pierre Y. wrote:
> I plan to migrate my customers from Firebird 3.0.11 to Firebird 5.0 by
> deploying Firebird 5.0 with the Engine12.dll from Firebird 3.0.11
>
> I changed firebird.conf to :
>
> # ----------------------------
> # This parameter determines what providers will be used by Firebird.
> # Format is the same as for the list of plugins (see above). Internally,
> # a provider is just a kind of plugin.
> #
> # Type: string
> #
> # Per-database & per-connection configurable.
> #
> Providers = Remote,Engine12,Engine13,Loopback
>
> /(not sure in which order I should set this option, BTW, any hints ?)/

Generally, you should put it *after* Engine13 (if only so Firebird 5
databases like the security database don't take a (minor) performance
hit). Or better yet, only set it for specific databases in databases.conf.

> When I try to connect to the database using Firebird 3.0.11 fbclient.dll
> using inet:// connection string, I get this error :
>
> PRYBOOK Fri Jan 12 10:05:17 2024
> Authentication error
> Error loading plugin Engine12
> Module C:\Program Files\Firebird\5.0\plugins\Engine12 exists but can not
> be loaded
> Le module spécifié est introuvable. # The specified module cannot be found
>
> Is it supposed to work ? Should I do something different ?

Did you copy engine12.dll to the plugins folder? Is it the same bitness?

For me it works. I copied engine12.dll (64-bit) to Firebird 5 (64-bit),
though I only tested it with Engine12 after Engine13 in the Providers
setting.

Looking at it with procmon, I guess the problem is that you don't have
msvcr100.dll installed (i.e. in Windows System32). This means you'll
need to copy msvcr100.dll (from the Firebird 3.0 installation) into the
plugins directory of Firebird 5.0 (maybe also msvcp100.dll, not sure, I
don't see it loaded, but maybe it gets loaded later), or you need to
install the relevant Visual C runtime so these files end up in System32.

Mark
--
Mark Rotteveel

Pierre Y.

unread,
Jan 12, 2024, 7:49:27 AM1/12/24
to firebird...@googlegroups.com
Thank you, Mark, it worked. I copied to msvcr100.dll and msvcp100.dll to the Firebird "bin" directory instead of "plugins".

I reordered the Providers to put Engine12 after Engine13 and it worked too.

I'm wondering, now, if doing a backup of the database and a restore right after will "upgrade" it to Firebird 5.0 automatically.... Let's test :)


--
You received this message because you are subscribed to the Google Groups "firebird-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/firebird-support/6bc0e667-7421-4ed1-b210-1b0e4793fca7%40lawinegevaar.nl.

Pierre Y.

unread,
Jan 12, 2024, 7:52:37 AM1/12/24
to firebird...@googlegroups.com
Than you Dimitry. It works now. I confirm I copied the Engine12.dll from Firebird 3.0.11 "64 bits" into the Firebird 5.0 plugins directory. I just missed the msvc{r,p}100.dll files.

I confirm that the fbclient.dll from Firebird 3.0.11 "32 bits" can connect to the Firebird 5.0 "64 bits" instance using a remote (inet://) connection.



--
You received this message because you are subscribed to the Google Groups "firebird-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.

Mark Rotteveel

unread,
Jan 12, 2024, 8:20:29 AM1/12/24
to firebird...@googlegroups.com
On 12/01/2024 13:49, Pierre Y. wrote:
> Thank you, Mark, it worked. I copied to msvcr100.dll and msvcp100.dll to
> the Firebird "bin" directory instead of "plugins".
>
> I reordered the Providers to put Engine12 after Engine13 and it worked too.
>
> I'm wondering, now, if doing a backup of the database and a restore
> right after will "upgrade" it to Firebird 5.0 automatically.... Let's
> test :)

It should, because engine13 will be used for the restore if it is before
Engine12.

Note that if you configure Providers in databases.conf specifically for
a database (e.g. Providers = Engine12), restoring to the same name
should use Engine12.

Mark
--
Mark Rotteveel

Pierre Y.

unread,
Jan 12, 2024, 8:53:24 AM1/12/24
to firebird...@googlegroups.com
Right now, I get this message :

C:\Users\pierr>set PATH="C:\Program Files\Firebird\5.0";%PATH%

C:\Users\pierr>instsvc q
Firebird Server - My.Firebird.5 IS installed.
  Status  : running
  Path    : "C:\Program Files\Firebird\5.0\firebird.exe" -s My.Firebird.5
  Startup : automatic
  Run as  : LocalSystem

Firebird Server - DefaultInstance IS installed.
  Status  : stopped
  Path    : "C:\Program Files (x86)\Firebird\3.0.11\firebird.exe" -s DefaultInstance
  Startup : automatic
  Run as  : LocalSystem

C:\Users\pierr>gbak -b config config.fbk
gbak: ERROR:table id 51 is not defined
gbak:Exiting before completion due to errors

In database.conf :

config = C:\ProgramData\MyApp\config.fdb
{
  SecurityDatabase = config
}

# Using gbak from Firebird 3.0.11

C:\ Users\pierr>set PATH="C:\Program Files (x86)\Firebird\3.0.11":%PATH%

C:\Users\pierr>gbak -b -se localhost/3055:service_mgr inet4://localhost:3055/config config.fbk -user MYUSER -password MyUserPassword
gbak: ERROR:Error occurred during login, please check server firebird.log for details
gbak:Exiting before completion due to errors

In firebird.log :

PRYBOOK Fri Jan 12 14:40:29 2024
Authentication error
I/O error during "CreateFile (open)" operation for file "C:\PROGRAM FILES\FIREBIRD\5.0\SECURITY5.FDB"
Error while trying to open file
Le fichier spécifié est introuvable # Specified file cannot be found

I effectively disabled (deleted) security5.fdb because all my databases are their own SecurityDatabase and I don't want global users on the systems : the file on disk has been renamed and, in firebird.conf the section related to security.db is commented out :

# Master security database specific setup.
# Do not remove it until you understand well what are you doing!
#
# security.db = $(dir_secDb)/security5.fdb
# {
# RemoteAccess = false
# DefaultDbCachePages = 256
# }

Should Firebird 5.0 "gbak" be able to backup a Firebird 3.0 database if engine12.dll is present ?

Thank you,

--
Pierre Y.

--
You received this message because you are subscribed to the Google Groups "firebird-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.

Dimitry Sibiryakov

unread,
Jan 12, 2024, 8:58:32 AM1/12/24
to firebird...@googlegroups.com
Pierre Y. wrote 12.01.2024 14:53:
> Should Firebird 5.0 "gbak" be able to backup a Firebird 3.0 database if
> engine12.dll is present ?

No. gbak is tied to ODS of source database. It can ignore non-existing fields
to some extend but it is not granted.

--
WBR, SD.

Mark Rotteveel

unread,
Jan 12, 2024, 9:00:12 AM1/12/24
to firebird...@googlegroups.com
That is unfortunate IMHO.

Mark
--
Mark Rotteveel

Pierre Y.

unread,
Jan 12, 2024, 9:40:31 AM1/12/24
to firebird...@googlegroups.com
Do you think the backup-restore process using the Services API (isc_service_attach(), isc_service_start(), ...) could work in this case ?

--
You received this message because you are subscribed to the Google Groups "firebird-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.

Karol Bieniaszewski

unread,
Jan 12, 2024, 12:02:14 PM1/12/24
to firebird...@googlegroups.com

Beside your question, but what is the purpose of testing Firebird 3 (engine12 is Firebird 3 itself) under some Firebird 5 services?

What benefit from such action? You do not test FB5 itself (still FB3) and you only make more problems and cause more risks.

 

Regards,

Karol Bieniaszewski

--

You received this message because you are subscribed to the Google Groups "firebird-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.

Pierre Y.

unread,
Jan 12, 2024, 12:24:37 PM1/12/24
to firebird...@googlegroups.com
I'm looking for a way to provide an upgrade path for my users (Firebird is deployed locally on Windows machines), for now I'm stuck with Firebird 3.0

The idea was :
* Deploy Firebird 5.0 with Engine12.dll, so the app continues to work seamlessly
* Add a "Migration tool" that would do the backup/restore trick to upgrade the databases to Firebird 5.0 when the customer has enough time to do it (the migration tool would also delete Engine12.dll after migration has completed to avoid problems)


Karol Bieniaszewski

unread,
Jan 12, 2024, 12:43:56 PM1/12/24
to firebird...@googlegroups.com

So you do backup and restore under FB5 continously to check if it is working and wayt for custorer for decision when to switch?

Reply all
Reply to author
Forward
0 new messages