Skip to content

Firebird kits ​

FbExpert ships its own engine for the system database and opens each user database with the kit that matches its version. A kit is a complete Firebird tree (firebird.conf, plugins/, intl/, gbak, isql, gfix…), flattened at the root of its folder.

FbExpert and the Firebird kits
The application selects the kit according to the ODS of the open database.

Location ​

text
/var/lib/fbexpert/engines/<version>/

The root comes from Firebird:KitsRoot in /opt/fbexpert/appsettings.json, written by the installer:

json
"Firebird": {
  "KitsRoot": "/var/lib/fbexpert/engines"
}

Since 7.382, all kit resolution uses this key: embedded connections, services, imports, UDR, transformations, backups.

Versions ​

KitODSExtracted sizeNote
2.510.x / 11.x~10 MBend of life
3.012.0~24 MBend of life
4.013.0~48 MBuseful to demonstrate a migration
5.013.1~70 MBmandatory (system database and runtime)
6.014.0~111 MBpre-release, --allow-prerelease

A database can only be opened by the kit matching its ODS. "Firebird engine kit X not found" means the database is of that version and the kit is missing or cannot be read by fbexpert.

Installation ​

Always go through the wrapper, as root; it runs the download under the service account:

bash
sudo bash /opt/fbexpert/tools/install-kits-linux.sh -k 4.0
sudo bash /opt/fbexpert/tools/install-kits-linux.sh -k 2.5,3.0,4.0
sudo bash /opt/fbexpert/tools/install-kits-linux.sh -k 5.0 --force
sudo bash /opt/fbexpert/tools/install-kits-linux.sh -k 6.0 --allow-prerelease

--force replaces an existing kit, --no-udf skips FreeAdhocUDF. The main installer accepts the same list:

bash
sudo bash /opt/fbexpert/tools/install-fbexpert-linux.sh \
  --archive /root/FbExpert-<version>-linux-x64.7z \
  --kits 2.5,3.0,4.0,5.0 --upgrade

Never run fetch-kits.sh as root

The files would be owned by root and the service would no longer be able to replace them. The wrapper takes care of this.

The security database (security5.fdb, security6.fdb…) is initialized for all installed kits. Without it, a remote connection or a read of SEC$USERS returns Install incomplete. To complete security database initialization please CREATE USER.

Verification ​

bash
sudo -u fbexpert ls -1 /var/lib/fbexpert/engines
sudo -u fbexpert cat /var/lib/fbexpert/engines/4.0/kit.json
sudo -u fbexpert ls -l /var/lib/fbexpert/engines/4.0/libfbclient.so

Expected: one folder per version, libfbclient.so at the root (libfbembed.so for 2.5), plugins/libEngine12.so (3.0/4.0), libEngine13.so (5.0) or libEngine14.so (6.0), and a kit.json with version, tag, asset and checksum.

No restart is required: the kit is resolved when a database is opened or a service is started.

Troubleshooting ​

SymptomCauseFix
Permission non accordée on engines/<v>/…kit created by rootchown -R fbexpert:fbexpert /var/lib/fbexpert/engines, then run again with the wrapper
No space left / fallocate faileddisk or quota fulldf -h /var/lib/fbexpert
Aucun asset tar.gz Linux x64asset unavailable or API rate-limitedcheck the network, try again
database unreadable despite the kitwrong versiongstat -h db.fdb (ODS), then install the matching kit
gbak: libfbclient.so.2 not foundtool launched outside FbExpertFbExpert 7.403+ sets LD_LIBRARY_PATH; manually: LD_LIBRARY_PATH=<kit> <kit>/gbak …
Install incomplete…empty security databasefetch-kits.sh --force (7.408+) or CREATE USER SYSDBA PASSWORD 'masterkey' USING PLUGIN Srp;
Unable to complete network request to host "localhost" during analysis or in the workshopchild process without a kit (engine plugin not loaded)7.473+ passes KitsRoot, FIREBIRD and LD_LIBRARY_PATH; otherwise reinstall the kit (fetch-kits.sh --force -k <v>)
same errors for every toolpatchelf missing at build timednf install patchelf, then fetch-kits.sh --force

Replacing a kit: ICU collations ​

A database records its Unicode collations with the ICU of the engine that created it. After replacing a kit, restoring a database from another machine or moving from 5.0 to 6.0, the first write fails with COLLATION UNICODE …. Realign it with the service stopped:

bash
K=/var/lib/fbexpert/engines/5.0
DB=/var/lib/fbexpert/data/FBEXPERT.FB5

sudo systemctl stop fbexpert
sudo cp -a "$DB" /root/FBEXPERT.FB5.bak
sudo -u fbexpert env FIREBIRD="$K" LD_LIBRARY_PATH="$K" \
  "$K/gfix" -icu "$DB" -user SYSDBA -password masterkey
sudo systemctl start fbexpert

For the system database, use the runtime actually loaded (/var/lib/fbexpert/data/runtime/firebird/5.0); for a user database, the kit matching its ODS.

Since 7.472, FbExpert performs this check at startup: a probe write (a Unicode table created then dropped) detects the mismatch before the first application write, then runs gfix -icu automatically with the runtime, after copying the database to data/backups/system as FBEXPERT.collation-<date>.fdb. The log shows the ICU version recorded in the database. If the repair fails, the service starts in degraded mode with FBX-START-203 and the command to run. Can be disabled with Firebird:AutoRepairCollations=false.

Kits and demonstration ​

For a demo: keep 5.0 (mandatory) and optionally 4.0 to demonstrate a migration. Kits 2.5/3.0 are end-of-life engines; 6.0 is a pre-release. On a demonstration database, also lock the engine (gfix -mode read_only).