September 16th, 2010, 03:38 AM
FB embed server and network drive
I'm using Firebird SQL embed database. On the local disk it works very well. I tried to copy the database file (something.fdb) to the network drive and the client shows the error message "Unable to complete network request to host fsgt. Failed to establish the connection." The connection string was: database=H:/my_projects/something.fdb.
I tried to change the connection string: database=\\192.168.0.2\user/my_projects/something.fdb. The IP adress 192.168.0.2 is the adress of the file server. But it was without any result.
The client runs on Windows XP SP3, in the Windows firewall I allowed the port 3050.
The server runs on Linux and the port 3050 is usually not used. Between the server and the client there is Samba.
What is wrong?
September 18th, 2010, 02:07 AM
Ive never been successful at connecting to a database file that is not on the same computer as the firebird server, so ive always assumed its not possible.
But I do know that if your on a different computer from the server, you still write your connection file path as if you are on the server not the path from the client to the file.
For example, trying to use database workbench to open a database on the server from a client, you state the server is 192.168.0.2 or whatever, and then you say the path is E:/db/file.fdb not \\sharepath\db\file.fdb (or whatever), even though that E:/db doesn't exist on the client , its still the path on the server to it.
Also i would imagine, that even if it is possible and i just havnet figured it out yet, having firebird trying read a db file over a network would be realllly slow, compared to reading it from a hard drive on the same machine.
Reading a db file on the same hard drive that firebird is running on isnt even the best way, having 3 separate hard drives (on the same computer) for the database, the temp files, and the system is the best.
September 18th, 2010, 04:36 AM
the connection string might be wrong:
check if you have connection from workstation to the server (at command prompt type: telnet <server_address_or_hostname> 3050
if it says there's no connection to host, they rule out network problems first.
i usually use aliases in the /etc/firebird/aliases.conf file, like:
mydb = /data/db/blabla.fdb
and i my connection string looks like: connstr='192.168.0.100:mydb' , where 192.168.0.100 is my server's address
there are no \\ because this is a firebird protocoll connection not an SMB.
not using aliases then the connection string will be:
Important to take care of that the firebird user on the server to have read/write access on the /data/db/blabla.fdb file.
Last edited by nagysz; September 18th, 2010 at 04:38 AM.
September 21st, 2010, 08:03 AM
Thank for the replies.
I connected two computers direct with a network cable. The OS of the computers was MS Windows, the antivirus and the firewall on the computers were disabled. I put the database.fdb into a shared folder and tried to connect from the other computer. But it didn't work.
So I will create an application, which will copy the DB file from the network drive to the HDD, run the DB client program and after closing the client program copy the DB file back to the network drive
September 27th, 2010, 07:56 AM
Originally Posted by SimyV
September 27th, 2010, 01:16 PM
Why are you using the embedded server when the file is on another computer?
IMO - a bad. idea.
Just use the regular FB server on the remote machine and move on.
September 27th, 2010, 03:38 PM
looooool you sounded like my little brother. He also has an idea for everything....now matter how inefficient it is )))
September 29th, 2010, 01:48 AM
Which post sounded like your little brother?
Originally Posted by nagysz
Which idea do you consider inefficient?
Without this information I am not sure what your post illuminates.
September 29th, 2010, 09:18 AM
scuzi! it was a reply to SimyV to this one:
Originally Posted by clivew
Comments on this post