Materializing the standby database in ASE 12.5.0.3

Materializing the standby database is one of the tasks required to set up the Mirror Activator system. Therefore, the following Mirror Activator system setup tasks (which are not strictly materialization tasks) must be performed during the standby database materialization procedure:

The snapshot materialization procedure mentions these setup tasks, but it does not describe them in detail. See “Setting up a new Mirror Activator system” for detailed information about Mirror Activator system setup tasks.

NoteBefore you materialize a standby database, you must create the Replication Server database objects in the primary database, and then initialize the primary database using the Mirror Replication Agent pdb_init command. See “Setting up a new Mirror Activator system” for more information.

Table A-1 provides a checklist of the snapshot materialization tasks for a standby database in Adaptive Server version 12.5.0.3.

The checklist in Table A-1 assumes that the standby Adaptive Server is already installed, and configured identically to the primary Adaptive Server.

Table A-1: Materializing a standby database in ASE 12.5.0.3

Task

Description

1

In the standby Adaptive Server, create the same server logins and roles that are defined in the primary Adaptive Server.

2

In the standby Adaptive Server, create an empty (or shell) database, with the same data and log devices, database name, and database options as the primary database.

3

Shut down the standby Adaptive Server.

4

Quiesce the primary database to suspend all update activity.

5

Use the disk replication system to copy a snapshot of all primary database data and log devices to the standby database devices.

While the primary database is suspended during Mirror Activator system setup, you must also:

  • Copy a snapshot of the primary database log devices to the mirror log devices, and configure synchronous replication from the primary log devices to the mirror log devices

  • Initialize the Mirror Replication Agent

6

Resume update activity in the primary database after all procedures in step 5 are complete.

7

Start the standby Adaptive Server to recover the standby database and bring it online.

Use the following procedure for snapshot materialization of a standby database in Adaptive Server version 12.5.0.3.

StepsTo materialize a standby database in ASE 12.5.0.3

  1. In the standby Adaptive Server, create all server logins and roles defined in the primary Adaptive Server.

  2. Create an empty (or shell) database in the standby Adaptive Server.

    1. Initialize the standby database data and log devices in the standby Adaptive Server, using the same disk init options as the primary database devices in the primary Adaptive Server. For example:

      disk init name = "pdb_data",
      physname = "data_dev",
      size = "dddM"
      

      where:

      • pdb_data is the device name used in the primary Adaptive Server.

      • data_dev is the path to the device in the standby Adaptive Server.

      • ddd is the size of the device, in megabytes, in the primary Adaptive Server.

      NoteThe only device options that can be different between the primary and standby servers are the paths to the physical devices. All other device options must be identical on the primary and standby servers.

    2. Create the standby database in the standby Adaptive Server, using the same create database options as the database in the primary Adaptive Server. For example:

      create database pdb
      on pdb_data = "dddM"
      log on pdb_log = "lllM"
      

      where:

      • pdb is the database name used in the primary Adaptive Server.

      • pdb_data is the database data device name used in the primary Adaptive Server.

      • ddd is the size of the database data device, in megabytes, in the primary Adaptive Server.

      • pdb_log is the database log device name used in the primary Adaptive Server.

      • lll is the size of the database log device, in megabytes, in the primary Adaptive Server.

  3. Shut down the standby Adaptive Server using the shutdown command.

  4. Quiesce the primary database to suspend all update activity.

    Log in to the primary Adaptive Server with a System Administrator user role, and execute the following command:

    quiesce database MA_setup hold pdb
    

    where:

  5. Using the disk replication system facilities:

    While the primary database is suspended during Mirror Activator system setup, you must also:

    Refer to the documentation provided by your disk replication system vendor for more information about the procedures in this step.

  6. Resume update activity in the primary database after all procedures in step 5 are complete.

    NoteYou must initialize the Mirror Replication Agent before you resume update activity in the primary database.

    Log in to the primary Adaptive Server with a System Administrator user role, and execute the following command:

    quiesce database MA_setup release
    

    where MA_setup is a user-defined tag that identifies the suspended primary database.

  7. Start the standby Adaptive Server to recover the standby database and bring it online.

    Open an operating system command prompt window on the standby Adaptive Server host, and use the RUN script to start the standby Adaptive Server:

    $SYBASE/ASE_12-5/install/RUN_sds
    

    where:

    The standby data server will start up in “recovery” mode, and it may take a while for the standby database to come online.