firebird
firebird copied to clipboard
Add replication journal cleanup when drop database
Problem: when deleting a DB, log segment files remain, which break replication in the future
First fix - when deleting a DB using DBMS query (drop database), add deleting segments
- There is a DB with replication, create a backup
- One of two options:
2.1. Execute the
drop databasecommand 2.2. Restore via gbak with the-recreate_database overwriteor-replace_databaseoption, without deleting the DB and without clearing the journal directory - Old segments will be deleted as unnecessary
Second fix - add a unique GUID of the DB to the segment filename pattern
- There is a DB with replication, create a backup
- Delete the DB file via the file system
- Restore via gbak, without clearing the journal directory
- Old segments will remain in the file system, but will not interfere with replication, since the names of the new ones will be different