Subject Re: Firebird 2.1.1 Gbak Issues
Author Matt Nielsen
This is what I'm doing in the batch scheduler that I wrote.

"C:\Program Files\Firebird\Firebird_2_1\bin\gbak.exe" -user SYSDBA -pass masterkey -b -t -se LOCALHOST:service_mgr "C:\Database\DATABASE.DB" "C:\Database\Backup\DATABASE.DBK"

I use the service manager so this same scheduler can backup the sercurity database.

I promise no one is messing with metadata but even if they were the backup is supposed to use a transaction so that shouldn't matter.

--- In, Helen Borrie <helebor@...> wrote:
> At 10:44 AM 13/03/2009, you wrote:
> >here is another error that I get sometimes on a restore of the noon backup. Again, I have never had this problem with the backup when there is noone on the system.
> >
> >gbak: ERROR:attempt to store duplicate value (visible to active transactions) in unique index "RDB$INDEX_11"
> >gbak:Exiting before completion due to errors
> This during a **backup** ?? gbak -b ??? That smells like a batch script or scheduler entry that has the wrong switch. Eeeew! Check 'im!
> RDB$INDEX_11 is the unique index on the generator name in RDB$GENERATORS. Now, a *restore* would be pumping data into that table so it's slightly feasible that this error could occur during a *restore*...though it would suggest that someone has been meddling with that system table unless at some point a partially restored database was put into production use.
> gbak -b doesn't write to the database at all. However (unless flagged otherwise with the -g switch) its select * queries on all tables triggers garbage collection, which writes to disk at a much lower level than DDL and certainly doesn't create, alter or drop records in the system tables.
> ./heLen