We have a .gbk file that we are trying to restore to a database, in order to convert it to Postgres, but we can’t figure out the ODS or even if it is actually an Interbase file, and not a Firebird file.
We ran downloaded gbak version UI-V3.0.10.33601 Firebird 3.0 and restored it. Running gstat on the resulting file gives us:
Database header page information:
Flags 0
Generation 1814
System Change Number 0
Page size 16384
ODS version 12.2
Oldest transaction 1803
Oldest active 1804
Oldest snapshot 1804
Next transaction 1804
Sequence number 0
Next attachment ID 9
Implementation HW=AMD/Intel/x64 little-endian OS=Darwin CC=gcc
Shadow count 0
Page buffers 0
Next header page 0
Database dialect 1
Creation date Jan 19, 2024 23:35:51
Attributes no reserve
Variable header data:
Sweep interval: 0
*END*
Trying to open it with DBeaver on a Mac (as Firebird):
I/O error during "open" operation for file “myfilename”; Error while trying to open file; Operation not permitted [SQLState:08001, ISC error code:335544344]
Trying to open it with DBeaver on a PC (as Firebird):
unsupported on-disk structure for file “myfilename”: found 32780.18, support (null) (null)
I presume this means it expected 18, and I read that 32779, that is 1 lower than ours, indicates that i is a Firebird 2.x file. Is it a Firebird file because we used gbak as supplied by Firebird? It is the only version we got to work.
Trying with Interbase 2020 togo installation (PC)
gstat on the gdb file:
Wrong ODS version, expected 18, encountered 32780
Also, running gbak on our gbk file that we started with gives:
gbak: ERROR: Expected backup version less than or equal to 7. Found 9
So in summary we can’t figure out what is going on at all, it’s not clear if the file is too new or too old, or even if it is Firebird or Interbase. What is the right approach?