Subject Re: [firebird-support] Error 'reached end of file' during restore
Author Helen Borrie
At 12:38 AM 17/02/2007, you wrote:
>During our nightly backup and restore, the restore failed with the
>following messages:
>
>gbak: cannot commit index FK_INV_TRUCK_TO_INV_TRUCK
>gbak: ERROR: I/O error for file "E:\DB\BACKUP\RESTORE_THU\ABC.FDB"
>gbak: ERROR: Error while trying to read from file
>gbak: ERROR: Reached the end of the file.
>gbak: ERROR: action cancelled by trigger (3) to preserve data
>integrity
>gbak: ERROR: Cannot deactivate primary index
>gbak: Exiting before completion due to errors
>
>
>This is FB 1.5 running on W2k3 server. I am doing the restore with
>the embedded version of FB into a compressed folder. The DB file
>(after the error) was 37.1GB (16.2GB size on disk). The day prior,
>the restore was successful. The resulting DB was 37.2GB (16.3GB size
>on disk), so it looks like the restore was very nearly finished when
>it came upon this error.
>
>I'm curious what could have caused this problem? It looks to me like
>an out of space error, but that wasn't the case.

It possibly was, though. If you don't have enough RAM available for
building the indexes, the engine will use temporary files on disk for
the sorting. Check your TempDirectories setting in firebird.conf and
make sure you configure plenty of space for this purpose. (If you
haven't configured any then Windows will just use any temp directory
it knows about....so e.g. your c:\temp directory might not have
enough space available to it to accommodate your biggest index...)

./heLen