Rocky Castaneda
Rocky Castaneda

Reputation: 37

Firebird with 1 database file to use 2 servers

Is it possible for firebirdSQL to run 2 servers sharing 1 database file (FDB)/ repository?

Upvotes: 1

Views: 632

Answers (3)

cepukom
cepukom

Reputation: 56

Every SQL server will not allow such configuration. If you want to split load, maybe you need to look at Multi Tier architecture. Using this architecture, you can split your SQL query load to many computers.

Upvotes: 0

Mark Rotteveel
Mark Rotteveel

Reputation: 108941

If you mean if two servers on different host can share the same database, then no.

Firebird either requires exclusive access to a database (SuperServer), or coordinates access to the database by different processes on the same host through a lock file (SuperClassic and ClassicServer).

In both cases the server requires certain locking and write visibility guarantees, and most networked filesystems don't provide those (or don't provide the locking semantics Firebird needs it).

If you really, really want to, you can by changing a setting in firebird.conf, but that is a road to corrupt database or other consistency problems. And therefor not something you should want to do.

Upvotes: 1

Brent Rowland
Brent Rowland

Reputation: 121

No. The server needs exclusive access to the database files. In the case of the Classic architecture version, multiple fb_inet_server processes access the same files, but locks are managed through the fb_lock_mgr process.

Databases on NFS or SMB/CIFS shares are disallowed unless one explicitly disables this protection. firebird.conf includes strong warnings against doing this unless you really know what you are doing.

Upvotes: 3

Related Questions