Subject Re: Connection string to FilePath?
Author russellbelding
--- In, "russellbelding" <russell@b...>
> A bit off topic, but close enough.
> Is it possible on a Windows client, to take the tcp/ip IBO
> string <Server_Name>:<Path_On_Server> to the database file, use
> nice function and get <Network_Path_To_Database_Directory>?
> That would be nice.
> Thanks
> Russell

My reason for asking this is in the context of making a feature in my
application for sites to backup and restore their FB datafile in as
simple a manner as possible. I want a solution to be friendly to
users whose applications may be forced to close and to minimise the
time they cannot reconnect to the datafile.

So I thought a strategy to minimise the offline time would be to:
1. make a backup file (FileBK) of the datafile FileBD.
2. rename the datafile FileDB->FileOldDB_date
3. rename the backup FileBK->FileDB
4. do something with FileOldDB_data

Perhaps the IBOAdmin code does this, I don't know. It seemed to me
this would reduce the time the Datafile was unavailable to my
application. During the backup apps could request a login but would
be refused in a friendly manner as the datafile "knows" a backup is
underway and a restore is coming. Only when a restore was planned
would connections be refused.

To do the renaming I'd need access to the file in the FB DB folder.
Hence my question as my app knows only the connection string
<server>:<path_on_server>, which cannot be used to issue Win/Net
commands to rename and move files.

Since it is possible there is no share pointing to the DB folder and
also possible there is no alias pointing to the FB DB folder the
answer to my general question is "it won't always work". Unless there
are other tricks I am not aware of.

Not having a share to the DB folder will reduce file corruption
chances. The ability to remove IBOAdmin/gbak backup files from this
folder to another disk is also desired. This is workable without
having a share giving access the the DB folder. I can require at
installation time, a separate folder on the DB server be specified
for backup files and restore work, and require a share for this
backup folder. Then the IBOAdmin backup service places its backup
files in this folder. As I have a share for this folder I can copy
them, if required, to another disk after they are made.

So I am back to using the IBOAdmin component for one part of the
backup and restore requirement. When a new version of FB with a new
ODS is installed, the datafile requires a backup and restore, done
with the IBOAdmin Backup service.

Kind regards