5
(1)

Suppose you have replication setup between ASE1.DB — > ASE2.DB(MSA & table level both) and you would like to refresh these 2 databases from PROD database and re-setup the replication. Below would be the high level steps to follow.

High Level steps

Step 1: Collect below information from source(ASE1.DB) before database refresh.

1.sp_config_rep_agent ASE1.DB
2.dbcc gettrunc — capture genid value that will be needed in step#5

Step 2: Stop replication from source(ASE1.DB)

sp_stop_rep_agent ASE1.DB

Step 3: Check replication queue using admin disk space

login to replication server and run below command.
1.admin disk_space — to check for any pending data in replication queue
2.admin quiesce_check — to check if replication server is quiesced or not

Once replication queue is clear and replication server is quiesced, proceed next.

Step 4: Perform database refresh.

Step 5: Re-configure replication agent on ASE1.DB

sp_config_rep_agent DB,disable
go
use DB
go
dbcc settrunc(ltm,gen_id,1)
— genid value captured in step #1 + 1(genid value to be incremented by 1). in our case captured value was 0, so 0+1=1
go
sp_config_rep_agent DB,enable,REP_SERVER_NAME,REP_SERVER_NAME_ra,REP_SERVER_NAME_ra_ps
go

Also, match sp_config_rep_agent ASE1.DB value with value captured in step #1

Step 6: Set zeroltm on RSSD server

Run below command on RSSD database server
rs_zeroltm ASE1,DB
go

Step 7: Start replication agent

Run below command on primary database server ASE1
sp_start_rep_agent DB
go

Step 8: Perform replication test

Perform replication test to ensure it is working as expected before handing over to DEV team.

How useful was this post?

Click on a star to rate it!

Average rating 5 / 5. Vote count: 1

No votes so far! Be the first to rate this post.