Active Standby Pair
with TimesTen Application-Tier Database Cache and Clusterware

An Active Standby Pair configuration includes an active database, a standby database, and optional read-only subscriber databases. The standby database uses Oracle TimesTen Replication to receive the changes from the active database and forwards the changes to optional read-only subscriber databases.

Oracle Clusterware is a general purpose cluster manager that manages and monitors the availability of software components that participate in a cluster. TimesTen Cache is integrated with Oracle Clusterware via the ttCWAdmin utility. When a customer chooses to use Oracle Clusterware with TimesTen Cache, the failover and restart of Active Standby Pairs of databases are handled automatically. In addition, Oracle Clusterware may be used to manage the actual applications that use TimesTen Cache.

Installing Oracle Clusterware and TimesTen Application-Tier Database Cache

1. Install Clusterware Oracle Clusterware 11.2.0.2 is required.
2. Install TimesTen Application-Tier Database Cache (TimesTen Cache) Oracle TimesTen In-Memory Database 11.2.2 is required.

Follow the example below to install Oracle Clusterware and TimesTen Cache as described in the tasks above:

Installing Oracle Clusterware and TimesTen example

 

Configuring an Active Standby Pair for Clusterware and TimesTen Cache

1. Create a cache database An initial cache database must be created before an active standby pair can be set up. This database should contain a user with CACHE_MANAGER or ADMIN privilege for managing a cache grid, with the required cache groups already defined.

If you have an existing cache database, this step can be skipped.
2. Create a database user to administer the active standby pair The cache database must include a user with the ADMIN privilege, if it does not yet exist. This user will be responsible for managing the active standby pair configuration.
3. Detach database from the cache grid If the database was previously attached to a cache grid, use the ttGridDetach built-in procedure to detach it from the grid.
4. Start the cache agent Use the built-in procedure ttCacheStart to start the cache agent process if not already started.
5. Define cache groups Create some cache groups for the Active Standby Pair.
If you have existing cache groups then this step can be skipped.
6. Register TimesTen instance information TimesTen instance information is stored in the Oracle Cluster Registry. Register the TimesTen instance information by executing the ttCWAdmin -ocrConfig command on any one of the hosts.
7. Start cluster agent Start the TimesTen cluster agent by executing the ttCWAdmin -init command on one of the hosts. This cluster agent will manage the TimesTen Main Daemon, which in turn manages the TimesTen cache agent, and replication agent on all hosts in the cluster.
8. Create cluster.oracle.ini file The cluster.oracle.ini config file uses attributes to declaratively define the configuration of an active standby pair that will be managed by Oracle Clusterware.
The entry name for the Active Standby Pair in the cluster.oracle.ini file must correspond to the system DSN created in step 1 above.
9. Create an Active Standby Pair Create an Active Standby Pair by executing the ttCWAdmin -create command on any host in the cluster.
10. Start the Active Standby Pair Start the Active Standby Pair by executing the ttCWAdmin -start command on any host in the cluster.
11. Preload data into cache groups Use the LOAD CACHE GROUP statement to preload the cache groups with data from the Oracle database.

Follow the example to configure an active standby pair with TimesTen Cache and Oracle Clusterware using the configuration
steps described above:

Configuring an Active Standby Pair with TimesTen Cache and Clusterware example

 

Managing the Active Standby Pair for Clusterware and TimesTen Cache

1. Get cluster agents' status Find the status of the active standby pair via the ttCWAdmin -status command on any host in the cluster.
2. Stop Active Standby Pair Stop the active standby pair via the ttCWAdmin -stop command on any host in the cluster.
3. Drop Active Standby Pair Drop the active standby pair via the ttCWAdmin -drop command on any host in the cluster.

Note: Remember to always stop and drop the Active Standby Pair before dropping their cache group(s).

Follow the example below to manage an active standby pair with TimesTen Cache and Oracle clusterware using the
configuration steps described above:

Managing an Active Standby Pair with TimesTen Cache and Clusterware example



The following documentation link covers more admin tasks.


Automatic failover and restart for Active Standby Pairs and user applications

The following links describe how Oracle Clusterware is used to failover and restart Active Standby Pairs and user applications.

The following viewlet shows failover and failback of a user application and its corresponding Active Standby Pair and with Oracle Clusterware.