Upgrading RepAgent threads in Adaptive Server databases

If the primary databases managed by the upgraded Replication Server are Adaptive Server 11.5 or later, you must upgrade to RepAgent threads before you can use the new features.

NoteIf you are upgrading to RepAgent directly from a pre-11.0 version of Replication Server to version 11.5 or later, make sure that mixed-mode transactions are not active during the upgrade. Mixed-mode transactions contain both applied commands (insert, delete, update, and applied functions) and request functions.

StepsUpgrading RepAgent threads

  1. Make sure the Replication Server and Adaptive Server versions are both 11.5.

  2. Stop the LTM.

  3. Convert the LTM configuration file to SQL commands.

  4. Set up the RepAgent. See “Setting Up RepAgent” in Chapter 3 in the Replication Server Administration Guide for details.

  5. If RepAgent threads are not enabled in the Adaptive Server, enable the RepAgent threads feature:

    sp_addserver servername, local 
    go 
    sp_configure "enable rep agent threads", 1 
    go
    
  6. Enable the RepAgent for the database:

    sp_config_rep_agent db_name, enable, 
       "rs_servername", "rs_username", "rs_password"
    

    where:

  7. Configure the RepAgent, if the default configuration is not appropriate. Consult the LTM configuration file and LTM run files, to determine what needs to be changed. For each configuration option that needs to be changed, use the following command:

    sp_config_rep_agent db_name, "option", "value"
    

    For instance, to set retry timeout to 30, enter:

    sp_config_rep_agent db_name, "retry timeout","30"
    

    The RepAgent configuration options and their equivalent LTM configuration options are in Table 3-2. Also see Chapter 3 of the Replication Server Administration Guide for details on the new options.

    Table 3-2: Mapping old configuration file parameters/options to 12.6

    Old LTM configuration file

    New RepAgent parameter/option

    RS_source_db

    connect_database (recovery mode only)

    RS_source_ds

    connect dataserver (recovery mode only)

    SQL_user

    SQL_pw

    SQ_pw_enc

    Obsolete

    RS

    rs servername

    RS_user

    rs username

    RS_pw

    rs password

    RS_pw_enc

    Obsolete

    SQL_database

    connect database

    SQL_server

    connect dataserver

    LTM_admin_user

    LTM_admin_pw_enc

    LTM_admin_pw

    Obsolete

    LTM_language

    LTM sortorder

    Obsolete

    retry

    retry timeout

    scan_retry

    batch_sz

    Obsolete

    skip_ltl_cmd_err

    skip_ltl_errors

    maint_cmds_to_skip

    print_sproc_warning

    Obsolete

    New RepAgent-specific options

    fade timeout

    scan batch size

    scan timeout

    Old command line option

    New RepAgent option

    -A

    send maint xacts to replicate

    -W

    send warm standby xacts

    For the rs_name, rs_username, and rs_password parameters, the options can be directly modified using the following command, where option is rs servername, rs username, and rs password, respectively:

    sp_config_repagent db_name, "option", value
    

    Source data server database defaults to connect database can be overridden by setting connect dataserver.

  8. Start the RepAgent using sp_start_rep_agent. After starting the RepAgent for a database once with sp_start_rep_agent, it starts automatically every time the data server is rebooted. The command to start the RepAgent is:

    sp_start_rep_agent db_name