On 05-08-2022 12:12, Winfried Bernartz wrote:
> So just thanks a lot for many of you trying to help me!
>
> I just try to detail it:
>
> First problem:
>
> nbackup.exe -L test.fdb -user Testuser -pass Testpass
> Problem on "begin backup".
> unsuccessful metadata update
> -Alter database failed
> *-Database already in the physical backup mode*
> SQLCDE: -607
>
> So that looks like fdb wasnt unlocked before
>
> Now i think my frist try shoulb be to unlock the fdb:
>
> nbackup.exe -UN test.fdb
> Problem on "attach database".
> I/O Error during "createfile (open)" operation for file "test.fdb
> -Error while trying to open file
> *-The process cannot access the file because it is being used by another
> process.*
> SQLCode: -902
>
> But now i cant understand this, because just before firebird says fdb
> is already in backup mode?
> But if it is in the backup mode, how can it be used by another process?
> In this case firebird uses the test.fdb.delta and not the fdb and waits
> for the unlock to join the delta and the fdb or am i completely wrong?
>
> Would be really great if somebody has an additional hint for me
Have you tried connecting to the database with ISQL and executing ALTER
DATABASE END BACKUP, as I suggested in one of my earlier replies?
Also, I'm not sure why you locked the database, but if you did it so
some external program could backup the database, it is possible it still
has a file handle open to the database.
Otherwise, you need to use a tool suitable for your OS to find out which
process has a file handle open.
E.g. for Linux:
https://superuser.com/questions/97844/how-can-i-determine-what-process-has-a-file-open-in-linux
For Windows:
https://serverfault.com/questions/1966/how-do-you-find-what-process-is-holding-a-file-open-in-windows
Mark
--
Mark Rotteveel