From Firebird 3 to Firebird 5

A Simple Method to Safely Migrate a Firebird Database
One straightforward and safe way to migrate a Firebird database is by performing a backup on the old system and restoring it on the new one. This allows the database engine to perform all necessary compatibility checks before the database is used in production.
Here are the general steps I follow to carry out this operation:
1 – Access the system running Firebird 3.0 and create a backup
cd /
gbak -b -v -user <dbusername> -password <dbpassword> ./.fdb ./.fbk
2 – Copy the backup to the system running Firebird 5.0, for example using scp
scp ./<dbfilename>.fbk syna@<serveraddress>:
3 – Restore the backup on the new system
sudo /opt/firebird/bin/gbak -c -v -user <dbusername> -password <dbpassword> ./<dbfilename>.fbk ./<dbfilename>.dat