After Graceful Switchover Dbvisit Replicate starts from new Primary
Problem Description
Dbvisit Standby and Dbvisit Replicate running together. The below steps are to be done when performing Graceful switchover on Dbvisit Standby and the replication now needs to be run from new Primary server.
Environment:
dbvlab04: Primary DB (TESTDB)/ Source DB/ MINE Server
dbvlab03: Standby DB (TESTDB)
dbvlab22: Target DB (DEVDB) / APPLY Server
Steps Performed
Step1. Stop the application to make sure no changes done on Source DB
Step2. Disable Dbvisit Standby schedule
Note: If you have scheduled Dbvisit via cron job, ensure these jobs are not running. If using dbvserver scheduling, ensure that schedule in GUI is disabled.
Step3. Run the default commands on Primary and Standby Server (i.e Sending/Applying of archive logs)
Step4. Run a log gap report on primary to ensure primary and standby are sync.
Step5. Shutdown MINE and APPLY process.
Note: Ensure no dbvrep processes are running on mine and apply server
MINE:
oracle@dbvlab04[/home/oracle/ZD8842]: ps -ef |grep dbvrep
oracle 27796 26950 0 18:58 pts/2 00:00:00 grep dbvrep
APPLY:
oracle@dbvlab22[/home/oracle]: ps -ef |grep dbvrep
oracle 21523 21116 0 18:59 pts/2 00:00:00 grep dbvrep
Step6. Start Graceful Switchover (GS) example: "./dbv_oraStartStop switchover testdb 9999"
Note: Please ensure GS is successful.
Step7. Change the "tnsnames.ora" on New Primary(i.e before GS was Standby) and Target Server.
Step8. Copy the DDC directory from Old Primary to New Primary server (i.e. DDC folder is ZD8842).
Step9. In MINE.ddc change the hostname:
memory_set MINE.MINE_REMOTE_INTERFACE = <new_hostname>:7901
Example:
oracle@dbvlab03[/home/oracle/ZD8842]: more ZD8842-MINE.ddc
.....
.....
########## Any manual settings should go below this line ##########
memory_set MINE.MINE_REMOTE_INTERFACE = dbvlab03.dbvisit.co.nz:7901
Step10. Run the console on new Primary and check variable "MINE_REMOTE_INTERFACE"
Note: Do not start MINE process yet.
Step11. Before starting MINE process, copy the archives from old Primary to New Primary Server(after GS).
Note: Make sure the Oracle archive location is the same and the last few archives before are copied.
Step12. Start MINE and APPLY processes now.
Step 13. Start the console and check the status. Make sure that MINE will process the archives that were copied at Step11 and get past the last sequence copied.
Step14. At this point since everything is running fine, Dbvisit standby schedules and other applications can be enabled on Source.
NOTE: Make sure you test the process before implementing to Production environment.