Subject | RE: [firebird-support] How to create a database over a UNC path? |
---|---|
Author | Nigel Weeks |
Post date | 2004-10-20T01:36:11Z |
>It is a popular question, but it's not a good idea.
> Sorry if this post is naive or redundant. I am new
> to Firebird.
>
>
> Summary
> -------
> We are having trouble creating a database on a drive
> described by a UNC path. Firebird is not installed
> over a UNC path, but we would like to keep the database
> itself on a Network Appliance box for ease of backup, etc.
>
> I have searched the newsgroups, etc. a bit, and it sounds
> like this is unsupported. The most relevant posts I found
> reference
> http://www.volny.cz/iprenosil/interbase/connect_string.htm
> http://groups.yahoo.com/group/firebird-support/message/48495
>
> However, what we want to do seems like a fairly normal
> thing for a database to support, so I wanted to make sure
> whether this is supported or not.
If you seperate a database engine from it's database file, and put a network
in the middle, you're guaranteed the following:
speed and latency issues due to network congestion and protocol stacks
The possibility of a switch/hub jamming - DOS your database
exclusive access to your database file could be obtained by software other
than the database engine.
In short, keep the database file, and the database engine on the same
machine.
While it is possible to trick Firebird to store it's databases on drive
mappings, effectively storing the data elsewhere, it's a shocker of an idea.
The Firebird engine NEEDS exclusive low-level access to the database file.
Bad things will happen if you try to insert layers here.
Keep it local, and either shadow, replicate, or do regular backups and store
elsewhere if you need to.
> I have also tried via isql, as follows:This'll never work(Stepping through it's connect process):
>
> SQL> CREATE DATABASE "gradgrind:\\mthood\data\test.fdb"
> user 'sysdba' password 'masterkey';
> Commit current transaction (y/n)?y
> Committing.
> Statement failed, SQLCODE = -902
>
> Unable to complete network request to host "mthood".
> -Failed to establish a connection.
> -The system cannot find the path specified.
> SQL>
>
Connect to machine 'gradgrind'
Somehow switch to a drive called \\mthood (Firebird is expecting drives and
filesystem path info here, not machine names)
traverse the path to the database "\data\test.fdb"
> I have tried a few different variants of this incantation,Correct!
> and I have tried their equivalents using isql as well,
> but no luck.
>
> I know Firebird is basically working fine because
> this works correctly (using isql and the C API):
>
> SQL> CREATE DATABASE "gradgrind:c:\tmp\test.fdb"
> user 'sysdba' password 'masterkey';
> SQL>
>
Machine:drive:path\to\database
I hope this has answered your question...
Nige.
Nigel Weeks
Tech Support & Systems Developer
nweeks@...
www.examiner.com.au
71 - 75 Paterson Street
Launceston
Tasmania 7250
Australia
Phone: 03 6336 7234