Creating Alternate Replication Paths for the Primary Database

Use the add parameter with sp_replication_path to create alternate physical paths between the primary database and a Replication Server by associating a RepAgent replication path with a primary connection from the Replication Server.

Prerequisites
Create the default replication path between the primary database and Replication Server with rs_init.
Task

Using the example replication system consisting of the PDS primary data server, pdb database, and RS1 and RS2 Replication Servers, create two alternate replication paths on the primary database to make a total of three primary replication paths including the default primary replication path.

  1. Create an alternate primary replication path between pdb and RS2 named pdb_1:
    1. Create an alternate physical replication path named pdb_1 between pdb and RS2.
      At PDS, enter:
      sp_replication_path "pdb", 'add', "pdb_1", "RS2", "RS2_user", "RS2_password"
    2. Create the corresponding alternate primary connection named pdb_1 from RS2 to pdb
      At RS2, enter:
      create alternate connection to PDS.pdb
      named PDS.pdb_1
      set error class to rs_sqlserver_error_class
      set function string class to rs_sqlserver_function_class
      set username to pdb1_maint
      set password to pdb1_maint_ps
      with primary only
  2. Create another primary replication path between pdb and RS1 named pdb_2:
    1. Create an alternate physical replication path named pdb_2 between pdb and RS1.
      At PDS, enter:
      sp_replication_path "pdb", 'add', "pdb_2", "RS1", "RS1_user", "RS1_password"
    2. Create the corresponding alternate primary connection named pdb_2 from RS1 to pdb
      At RS1, enter:
      create alternate connection to PDS.pdb
      named PDS.pdb_2
      with primary only