Subject | Re: Backing up when Embeded Server Used? |
---|---|
Author | inoffensive_2009 |
Post date | 2008-11-18T12:36:15Z |
--- In firebird-support@yahoogroups.com, "Adam" <s3057043@...> wrote:
I changed the embedded DLL's name to fbclient.dll.
Because I hadn't been aware of the service API, I was pleased to
see that IBPP supports them.
I added the call to IBPP's Service::StartBackup and that worked
perfectly the first timme. Then I made a call to IBPP's
Service::Shutdown, and Shutdown fails with:
Engine Code : 335544835
Engine Message :
Target shutdown mode is invalid for database "C:\PROGRAM
FILES\TFA\TFA_PRIVATE\DATABASE\TFA.FDB"
I'm passing Shutdown the name and path of the database, the
shutdown mode is IBPP::dsForce and the time is 10, for 10 seconds.
I ran the IBPP sample code that backed up it's sample database,
dropped the database, wiping it out, and restored it without
complaint. This was with the embedded server.dll in the directory
with the sample's executable.
But in my code the statement:
service->Shutdown(db_path_and_name, IBPP::dsForce, 10);
causes an exception.
The status.mMessage contains the following text:
Engine Code : 335544835
Engine Message :
Target shutdown mode is invalid for database "C:\<Path>\xxx.FDB"
The message is the same for any of the three shut down modes.
I then replaced the successful call to Service::StartBackup with a
call to Service::Shutdown. I figured if the function would support a
backup, it would probably work for Service::Shutdown. Same error.
I can feel Helen becoming irritated by this discussion of IBPP in
the Firebird support forum from the other side of the world, and I'm
sorry. But I'm desperate to get this going.
Thanks again for all the assistance.
Larry
>I was
> --- In firebird-support@yahoogroups.com, "inoffensive_2009"
> <larryl_hoo@> wrote:
> >
> > --- In firebird-support@yahoogroups.com, "Adam" <s3057043@> wrote:
> > >
> > > >
> > > > I wasn't using the services API, I'm not sure what it is.
> > > > running gbak with calls to CreateProcess, and identifying the gbak< Snip >
> > > > executable.
> > >
> > > Well this is your problem.
> > What am I missing?Thanks Adam, Alan, Helen and Fulvio:
>
> The README_embedded.txt in the embedded docs?
>
> gds32.dll is the client library used by Interbase. At some time in
> Firebird's history, it was renamed to fbclient.dll. If you are using
> components designed specifically for Interbase, you will need to
> either define the name of the client library (if possible), or rename
> the client library to gds32.dll.
I changed the embedded DLL's name to fbclient.dll.
Because I hadn't been aware of the service API, I was pleased to
see that IBPP supports them.
I added the call to IBPP's Service::StartBackup and that worked
perfectly the first timme. Then I made a call to IBPP's
Service::Shutdown, and Shutdown fails with:
Engine Code : 335544835
Engine Message :
Target shutdown mode is invalid for database "C:\PROGRAM
FILES\TFA\TFA_PRIVATE\DATABASE\TFA.FDB"
I'm passing Shutdown the name and path of the database, the
shutdown mode is IBPP::dsForce and the time is 10, for 10 seconds.
I ran the IBPP sample code that backed up it's sample database,
dropped the database, wiping it out, and restored it without
complaint. This was with the embedded server.dll in the directory
with the sample's executable.
But in my code the statement:
service->Shutdown(db_path_and_name, IBPP::dsForce, 10);
causes an exception.
The status.mMessage contains the following text:
Engine Code : 335544835
Engine Message :
Target shutdown mode is invalid for database "C:\<Path>\xxx.FDB"
The message is the same for any of the three shut down modes.
I then replaced the successful call to Service::StartBackup with a
call to Service::Shutdown. I figured if the function would support a
backup, it would probably work for Service::Shutdown. Same error.
I can feel Helen becoming irritated by this discussion of IBPP in
the Firebird support forum from the other side of the world, and I'm
sorry. But I'm desperate to get this going.
Thanks again for all the assistance.
Larry