Subject Re: Backup in a client PC
Author Adam
--- In firebird-support@yahoogroups.com, "Gustavo" <gusm@...> wrote:
>
> Adam:
>
> I can´t find the way to work with this!
>
> Now I have the following:
>
> In the server PC (PC1):
> C:\Program Files\Firebird\Firebird_2_0\... {FireBird superserver
> installation)
> C:\Program Files\MyApp\MyApp.exe (and other files not
related with
> FireBird)
> C:\Program Files\MyApp\DataBases\PC1DB1.FDB

Fine

>
> In the client PC (PC2):
> C:\Program Files\Firebird\Firebird_2_0\... {FireBird client
installation)

You don't want this. The embedded server gds32.dll is your client library.

> c:\PC2DataBases\PC2DB1.FDB

Probably fine (your logged in user will need read-write access to this
file.

>
> If I understand what you are saying, I have to put the following
files in
> the folder C:\Program Files\MyApp\ (the same where is MyApp.exe):
>
> fbembedd.dll (renamed to gds32.dll)
> icudt30.dll
> icuin30.dll
> icuuc30.dll
> firebird.conf
> firebird.msg

No, I mean the *whole* kit including sub folders (minus the doc folder
if you are desperate for disk space).

Have you read the Readme_Embedded.txt in the doc folder? Don't try and
be clever removing files you deem unnecessary until after you see it
working.

>
> I did that (and I deleted the file gds32.dll from
C:\Windows\System32 in
> PC2) and then, from PC2 (the client), I can run MyApp.exe (installed
in PC1,
> the server) and I can access both PC1DB1 (which is in PC1) and
PC2DB1 (which
> is in PC2) but... if I do this, a user in PC1 can´t access at the
same time
> PC1DB1 because the embedded server has exclusive access.

Not true.

You said in your first paragraph that PC1 (your server) has the full
Firebird 2 server installed. PC2 is *NOT* using the embedded database
engine to access PC1DB. It is using the embedded gds32.dll as standard
client.

From PC2 (or any other client for that matter), your connection string
would be of the form

PC1:c:\PC2DataBases\PC2DB1.FDB

When the embedded library sees this connection string, it pretends to
be a standard Firebird client library.

From PC2, when you need to access PC2DB, your connection string would
be of the form

c:\PC2DataBases\PC2DB1.FDB

Because you give a direct path without a host name, embedded acts as a
server. Now obviously other applications (including any other Firebird
or embedded installs on PC2) can't manipulate that database whilst
your application is connected, because under Superserver, only one
engine can control the database file at a time.

Adam