Kbase P159383: How to establish a new Target database over a pre-existing Target database?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  03/02/2010 |
|
Status: Unverified
GOAL:
How to establish a new Target database over a pre-existing Target database?
GOAL:
Is it possible to do a restore on top of a pre-existing Target database?
GOAL:
What needs to be done to establish a new copy of a Target database in place of an old one?
FACT(s) (Environment):
All Supported Operating Systems
OpenEdge Replication
FIX:
When replication is enabled and the target database is going to be stopped for an extended period of time, it may be beneficial to stop replication and re-establish the target database at a future time.
In this scenario deleting the database structure can extend the restore time quiet a bit, and it may be beneficial to restore over the existing structure. However, it is not possible to restore over a database that has replication enabled.
Instructions to accomplish this are listed below.
The following two items must be met in order for this process to work:
I. Once the online backup for Replication Creation has been done, ai files will be locked until the target database has sync'd with the source. It is imperative there are enough ai files to handle all ai switching and the number of ai notes that would be generated during this time frame.
II. After the backup to establish the target database is taken, no additional backups of the source database may be taken until the target database is started and has sync'd with the source database.
Steps establish a target database over an old one:
1. Target database is stopped for what ever reason.
2. Replication on source needs to be stopped. ( Otherwise there will not be a way to free up the ai files and to have a valid starting point for the new target database to sync with.)
dsrutil <source-dbname> -C disableSiteReplication source
At this point, all locked ai files become full. After imaging will still be running and enabled so if anything happens these ai files will be available for roll forward with a previous backup if needed.
3. Operation may continue this way or Replication may be re-initialized at anytime as long as there is enough ai file space to last until target is sync'd with the source database.
proutil <dbname> -C enableSiteReplication source
4. backup the production database with the following command when it is time to create the target database (This backup creates a sync point for replication) :
probkup online <dbname> <device-name> -REPLTargetCreation
5. Before a restore can be done over an old target database, sitereplication must be disabled:
(A prodel command would accomplish the same thing, however, the database structure format would have to be done at restore time, requiring additional time).
proutil <dbname> -C disablesitereplication target
6. Restore Target database
prorest <target-dbname> <device-file-name>
7. Enable replication for the target
proutil <dbname> -C enableSiteReplication target
8. Start the target database and agent
proserve <dbname> -DBService replagent -S 4501
9. Start Replication server on source database:
dsrutil <dbname> -C restart server
10. Re-start the ai file maintenance utility if it was stopped.