cc/td/doc/product/access/acs_soft/cs_unx
hometocprevnextglossaryfeedbacksearchhelp
PDF

Table of Contents

Setting Up Database Replication among CiscoSecure ACSes

Setting Up Database Replication among CiscoSecure ACSes

CiscoSecure ACS 2.3 supports asynchronous database replication among multiple CiscoSecure ACS sites that use the Oracle 7.3.3 and later or Sybase 11.02 and later database engines to store their profile information. Two recommended database replication scenarios are:


Note CiscoSecure supports only asynchronous, not real-time, database replication.

This chapter provides example procedures for setting up Oracle and Sybase database systems to carry out replication of the CiscoSecure database among multiple CiscoSecure  ACS sites.


Note If you have multiple existing CiscoSecure database sites that currently contain disparate data, all of which you wish to preserve when implementing replication, request your database administrator to merge your existing databases at one Master definition site before carrying out the procedures in this chapter.

Examples

Figure 9-1 illustrates an example of Master-to-Snapshot or Primary-to-Replicate database replication as applied to multiple CiscoSecure sites. In this scenario all administrative changes to the user profile database are made through the web-based console to one CiscoSecure ACS site. Then, at specified time intervals, those changes are replicated to all other sites on the network, enabling the ACSes to provide their authentication, authorization, and accounting services based on a common set of user profile data.


Figure 9-1:
Master-to-Snapshot Replication

Figure 9-2 illustrates Master-to-Master or Peer-to-Peer database replication as applied to multiple CiscoSecure profile database sites. In this scenario local administrative changes to the user profile database can be made through the web-based consoles at two or more ACS peer sites. Then, at specified time intervals, each of these peer sites communicate their local changes to all other sites on the network. As with Master-to-Snapshot replication, the end result is that the ACSes are able to provide their authentication, authorization, and accounting services based on a common set of user profile data.


Figure 9-2:
Peer-to-Peer Replication

Integrating Oracle Database Replication with CiscoSecure

The following example procedure uses the Oracle Net8 Easy Config (or the Oracle 7 SQL Net Easy Config), Security Manager, Schema Manager, SQL*Plus, and Replication Manager programs run on a Windows 95 workstation console to integrate Oracle database replication with CiscoSecure.

Caution Implementing Oracle database replication requires an in-depth knowledge of Oracle tools and database structure. Integrating database replication with CiscoSecure based on the following example procedures should be carried out by experienced Oracle DBAs only.

For specific instructions on how to use the above Oracle programs, please refer to Oracle manuals and online help.


Note The following example procedures assume that multiple Oracle server and tablespace sites have already been installed to service each CiscoSecure ACS site and that all CiscoSecure ACS sites have been installed. Refer to the CiscoSecure ACS Installation Guide for details.

A. Plan Your Oracle Database Server Distribution System

If you are planning to implement Master-to-Snapshot Replication, decide which of your Oracle database servers will become the Master database site. The remainder of your Oracle servers will become Snapshot sites.
If you are planning to implement Master-to-Master Replication, decide which of your Oracle Database servers will become the Master Definition site. The remainder of your servers will become Master Destination sites.

B. Create Connection Services from the Console to all Database Sites

If you do not have connectivity, locate the tnsnames.ora file in the $ORACLE_HOME/network/admin directory and edit it, making sure that entries exist for all the other Oracle database sites involved in the replication.

C. Create a Special User as the Replication Database Controller

For each service that you created in step B, use the Oracle Security Administrator to create a special user with special privileges to control database replication.

Caution This user must not be the Oracle user that you specified as in charge of the DB account for CiscoSecure data during CiscoSecure install.

D. Create Links between Databases

Create two-way links between the databases. For each database instance, do as follows:

E. If You Are Configuring a Master-to-Snapshot Replication Scenario

If you are configuring Master-to-Snapshot replication, follow the steps in this section. If you are configuring Master-to-Master replication, skip this section and go to the "F. If You are Configuring a Master-to-Master Database Replication Scenario" section.

Step 1 Using the SQL*Plus utility, log in to each database instance that you want to be a Snapshot site.

Step 2 Using the Oracle Replication Manager, create a database connection for each database connection service that you set up in step B.

Step 3 Using the Oracle Replication Manager, select the database connection that you want to be the Master Definition site and create and configure the master group on this site as follows:

Step 4 Using the Oracle Replication Manager, select and set up each database connection that you want to be a Snapshot site as follows:

Disabling the update option---causes the Snapshot site to be read-only. Configuring read-only Snapshot sites ensures that CiscoSecure administration can only be carried out at the Master site.
Enabling the update option---causes the Snapshot site to be updateable. Configuring updateable Snapshot sites allows CiscoSecure users with user-level web privilege to change their personal passwords and preserves the maximum failed login limitations.
From the refresh group properties menu, schedule the interval (for example, every 24 hours) when the update should occur.

Step 5 At the Master Definition database site, change to the CiscoSecure $BASEDIR/utils/bin directory and run the following CiscoSecure command line:

CSdbTool cache_trigger

Step 6 At each Snapshot database site, change to the CiscoSecure $BASEDIR/utils/bin directory and run the following CiscoSecure command line:

CSdbTool cache_trigger_snap

Step 7 Before you create any new users, configure the Snapshot sites to prevent duplicate user profile names. At each Snapshot site, enter the following command:

Step 8 Edit the initsid.ora configuration file. At each Oracle site, do as follows:

where sid is the system identification name of the Oracle server.
job_queue_interval = minutes
job_queue_processes = number
where:
minutes is the number of minutes between updates. This value must be equivalent to the update interval time that you set in the refresh group properties menu in the Oracle Replication Manager. (See step  4 in this section.)
number is the number of background processes allotted to the replication operations (must be at least 1).
compatible = 7.1.0.0
to:
compatible = 7.3.0.0

Step 9 At the CiscoSecure server for the Master site, restore the listings for the CiscoSecure servers installed at Snapshot sites.

Notice the that the IP listings for the CiscoSecure servers installed at Snapshot sites are not listed.

F. If You are Configuring a Master-to-Master Database Replication Scenario

If you are configuring Master-to-Master replication, follow the steps in this section. If you are configuring Master-to-Snapshot replication, ignore this section.

Step 1 Using the SQL*Plus utility, log in to each database instance that you want to be a Master Destination site.

Caution Remember, delete the above tables from Master Destination sites only.

Step 2 For each database connection service, create a surrogate replication administrator.

(a) Create a special user, a surrogate replication administrator, to control database replication.
Caution This user must not be the Oracle user that you specified as in charge of the DB account for CiscoSecure data during CiscoSecure install.
(b) For the user's Default table space, specify the Oracle tablespace that you set up for CiscoSecure before CiscoSecure installation.

Step 3 Using the SQL*Plus utility, assign the appropriate privileges to the database surrogate replication administrator at each Oracle site.

execute DBMS_REPCAT_AUTH.GRANT_SURROGATE_REPCAT(userid => 'surrogate_repadmn')
where surrogate_repadmn is the name of the surrogate replication administrator that you just created.

Step 4 Using the Oracle Replication Manager, create a database connection for each database connection service that you set up in step B.

Step 5 Using the Oracle Replication Manager, select the database connection that you want to be the Master Definition site and create and configure the master group on this site as follows:

Step 6 After creating the master group, set up conflict resolution for each table in the group. Add a column group, give it an arbitrary name, select the PROFILE_TS column to this group, and select the latest time stamp resolution method for this group.

Step 7 Using the Oracle Replication Manager, select and set up the database connection that you want to be a Master Definition site as follows:

Step 8 Using the Oracle Replication Manager, select and set up each database connection that you want to be a Master Destination site as follows:

Step 9 Using the Oracle Replication Manager, carry out the initial replication of the master group in each connection that you set up. For each master group configuration, go to Admin Requests and select the option, Apply all Administrative requests now.

Step 10 At each database site, run the following command line:

CSdbTool cache_trigger

Step 11 In order to prevent two different CiscoSecure servers from assigning the same internal profile ID number to different user profiles, assign non-overlapping ranges of internal profile ID numbers to each Master Destination site as follows:

update cs_id set id = 10000000 -1 where type = 'max_profile'
update cs_id set id = 10000000 where type = 'profile'
update cs_id set id = 10000000 where type = 'min_profile'
update cs_id set id = 20000000 -1 where type = 'max_profile'
update cs_id set id = 20000000 where type = 'profile'
update cs_id set id = 20000000 where type = 'min_profile'
update cs_id set id = 30000000 -1 where type = 'max_profile'

Step 12 After initial replication has occurred, and before you create any new users, configure the Master Destination sites to prevent duplicate user profile names. At each Master Destination site, enter the following command:

Step 13 Edit the initsid.ora configuration file. At each Oracle site, do as follows:

where sid is the system identification name of the Oracle server.
job_queue_interval = minutes
job_queue_processes = number
where:
minutes is the number of minutes between updates. This value must be equivalent to the intervals required when you created the scheduled links in Step 7 and Step 8 of step F.
number is the number of background processes allotted to the replication operations (must be at least one).
compatible = 7.1.0.0
to:
compatible = 7.3.0.0

Step 14 Restart the Oracle server to have the changes to the inisid.ora file take effect.

Step 15 At the CiscoSecure server for the Master Definition site, restore the listings for the CiscoSecure servers installed at the Master Destination sites.

Notice the that the IP listings for the CiscoSecure servers installed at Master Destination sites are not listed.

Precautions Running Oracle Database Replication and CiscoSecure

In cases where Oracle Master-to-Master (or Master-to-Updateable-Snapshot) database replication has been implemented, the CiscoSecure system administrators must avoid updating the same CiscoSecure user profile at two or more different CiscoSecure ACS profile database sites during the same interval between database replication processes.

If updating of the same user profile at two different sites within the same interval between replications occurs, the user profile edits at neither site will be replicated or reconciled. The user profile will remain with unreconciled settings at both sites, and the following Oracle error message will appear at both sites within the "Local Errors" section of the Oracle Replication Manager tree:

ORA-01403 no data found error

The above error should rarely occur, because, in practice, no more than one administrator, administering from one CiscoSecure ACS site should be authorized to administer any one user profile anyway.

However, if this error does occur, you must fix the unreconciled user profile at both sites as follows:

Step 1 Use the web-based CiscoSecure ACS Administrator web pages or the Java-based CiscoSecure Administrator program to do the following:

Step 2 Use the Oracle Replication Manager to force replication, or wait until the next scheduled replication.

The settings for the new user profile will replicate throughout the system.

Integrating Sybase Database Replication with CiscoSecure

The following example procedure uses the Sybase RS INIT, and rsmgen utilities run on the UNIX server, and Sybping, and Replication System Manager, running on a Windows 95 workstation console, to integrate Sybase database replication with CiscoSecure.

Caution Implementing Sybase database replication requires an in-depth knowledge of Sybase tools and database structure. Integrating database replication with CiscoSecure based on the following example procedures should be carried out by experienced Sybase DBAs only.

For specific instructions on how to use the above Sybase programs, please refer to Sybase manuals and online help.


Note The following example procedures assume that multiple Sybase servers and database sites have already been installed to service each CiscoSecure ACS site and that all CiscoSecure ACS sites have been installed. Refer to the CiscoSecure ACS Installation Guide for details.

A. Plan Your Sybase Replication System

Sybase supports two types of database replication, Primary-Server-to-Replicate-Server, and Peer-Server-to-Peer-Server.

If you are planning Primary-Server-to-Replicate-Server replication, decide which of your Sybase servers will become the Primary Server site. The remainder will become Replicate Server sites.
If you are planning Peer-to-Peer replication, you should still select a Primary server on which to install the replication server software.

B. Install the Replication Server Modules

To carry out database replication, Sybase requires that you install a Replication Server at one of your Sybase database sites and a Replication Server Manager client module at a PC console.

Step 1 At your Primary site, make sure that the Sybase SQL server or Adaptive server module is installed and running.

Step 2 Install the Replication Server and Replication Server Manager modules.

Step 3 Install the Sybase SQL Manager and Replication Manager Client tools on a PC console.

C. Configure the Sybase Replication Server

The Sybase Replication Server executes replication among the Sybase database sites. Set it up by using the Sybase RS INIT program following the procedures outlined in your Sybase documentation. RS INIT settings that require specific input in order to integrate Sybase replication of the CiscoSecure database are noted below:

Step 1 Specify the Replication Server Information settings. Except for the settings listed below, accept the default values.

Step 2 Specify the Replication Server Interfaces Information settings. Except for the settings listed below, accept the default values.

Step 3 Accept the default ID Server Information settings.

Step 4 Specify the Replication Server System Database Information settings. Except for the settings listed below, accept the default values.

Step 5 Specify the RSSD Device Information settings. Except for the settings listed below, accept the default values.

Step 6 Specify the Disk Partition Information settings. Except for the settings listed below, accept the default values.

If this file does not already exist, use the UNIX touch utility to create it. When creating this file, you must be logged in as the Sybase user, rather than as root.
The filename that you specify must not contain a period.

Step 7 Accept all default values for the Remote Site Connections Information settings.

D. Add the CiscoSecure Databases to the Replication

At each CiscoSecure database site run RS INIT to integrate the CiscoSecure database into the Sybase replication system. Set it up by using the Sybase RS INIT program following the procedures outlined in your Sybase documentation. RS INIT settings that require specific input in order to integrate Sybase Replication of the CiscoSecure database are noted below.

Step 1 Specify the Replication Server Information settings. Except for the bulleted settings listed below, accept the default values.

Step 2 Specify the Database Information settings. Except for the bulleted settings listed below, accept the default values.

Step 3 At Primary and Peer database sites only, accept all the default Database Log Transfer Manager settings.

Step 4 At Primary and Peer database sites only, configure the LTM Interfaces Information settings. Except for the bulleted settings listed below, accept the default values.

Step 5 Accept the settings. Note the logfile location on exit.

E. Set Up the Replication Services Manager Server

Set up one Replication Services Manager Server as follows:

Step 1 At the Primary server, use the Sybase DSEDIT utility to create an RSM server entry in the Sybase Interfaces file.

Step 2 In the $SYBASE/Install directory run the rsmgen utility.

Step 3 When prompted for the RSM Server name, specify the name you entered in the Interfaces file.

The rsmgen utility creates a file: RUN_rsmfilename

where rsmfilename is the name you specified while running rsmgen.

Step 4 Run the RUN_rsmfilename file in background mode. Enter:

./RUN_rsmfilename &

F. Start the PC Replication Services Management Program

Step 1 Move to the Windows 95 or Windows NT workstation on which you installed the Replication Services Manager client and ping the hosts running all the Sybase servers involved in database replication to test the console-to-Sybase server TCP/IP connections.

Step 2 If the pings are successful, use the Windows-based SQLEDIT program to generate an Interface file on the PC. Point to the IP addresses and TCP/IP ports of the SQL or Adaptive Server, Replication Server, LTM server and RSM server.

Step 3 Use the Sybping utility to ping the Adaptive Server, Replication Server, LTM server, and RSM server modules and confirm the console-to-server Sybase connections.

Step 4 Start the Windows-based RSM Manager.

Step 5 Select the File > New RSM Domain menu command.

Step 6 To create a RSM domain for your CiscoSecure profile databases, do the following:

Step 7 On each Primary server or Peer server in the RSM Domain, configure replication definitions for each of its tables as follows:

G. If You Are Setting Up Primary-to-Replicate Server Replication

If you are configuring Primary-to-Replication server replication, follow the steps in this section. If you are configuring Peer-to-Peer replication, you can skip this section and go to the "H. If You Are Setting Up Peer-to-Peer Replication" section.

Step 1 For each Replicate server in the RSM domain, configure subscriptions to each of the six replication definitions configured in step F.

For the Replication definition, select the name of the replication definition that you want associated with this subscription. This will be one of the 6 replication definitions that you configured in step F.

Step 2 At each of the CiscoSecure database sites, enable profile caching. Change to the CiscoSecure $BASEDIR/utils/bin directory and run the following CiscoSecure command line:

Step 3 At the CiscoSecure server for the Primary site, restore the listings for the CiscoSecure servers installed at the Replicate sites.

Notice the that the IP listings for the CiscoSecure servers installed at Replicate sites are no longer listed.

H. If You Are Setting Up Peer-to-Peer Replication

If you are configuring Peer-to-Peer replication, follow the steps in this section. If you are configuring Primary-to-Replicate server replication, ignore this section.

Step 1 Decide which of your Sybase sites will be the initial source Peer site.

When the first replication is run the initial source Peer site will be the site containing the original profile data structures that will be replicated to all the other sites.

All the other sites will be secondary Peer sites.

Step 2 At each secondary peer site, delete the current CiscoSecure profile records.

Start the Sybase ISQL utility and use the delete command to empty the current CiscoSecure profile records. Enter:

Step 3 At each secondary peer site, configure subscriptions to each of the replication definitions configured in step F. Use the Replication Services Manager Configure > Subscription option and click the Create tab.

For Replicate Data Base, specify the CiscoSecure database set up prior to the CiscoSecure installation.

Step 4 At the initial source Peer site, configure subscriptions to each of the replication definitions configured in step F. Use the Replication Services Manager Configure > Subscription option and click the Define tab.

Step 5 At each CiscoSecure database site enable profile cache updating. Change to the CiscoSecure $BASEDIR/utils/bin directory and run the following CiscoSecure command line:

Step 6 In order to prevent two different CiscoSecure servers from assigning the same internal profile ID number to different user profiles, assign non-overlapping ranges of internal profile ID numbers to each Peer site as follows:

update cs_id set id = 10000000 -1 where type = 'max_profile'
update cs_id set id = 10000000 where type = 'profile'
update cs_id set id = 10000000 where type = 'min_profile'
update cs_id set id = 20000000 -1 where type = 'max_profile'
update cs_id set id = 20000000 where type = 'profile'
update cs_id set id = 20000000 where type = 'min_profile'
update cs_id set id = 30000000 -1 where type = 'max_profile'

Step 7 Restart the CiscoSecure ACS at each site if it is running.

Step 8 At the CiscoSecure server for either the initial or a secondary Peer site, restore the listings for the CiscoSecure servers installed at the secondary Peer sites.

Notice the that the IP listings for the CiscoSecure servers installed at secondary Peer sites are no longer listed.

Precautions Running Sybase Database Replication and CiscoSecure

In cases where Sybase Peer-to-Peer database replication has been implemented, the CiscoSecure system administrators must avoid updating the same CiscoSecure user profile at two or more different CiscoSecure ACS profile database sites during the same interval between database replication processes.

If updating of the same user profile at two different sites within the same interval between replications occurs, the user profile edits at neither site will be replicated or reconciled. The user profile will remain with unreconciled settings at both sites.

In practice, this error is unlikely to occur for two reasons:

However, if the above error does occur, fix the unreconciled user profile as follows:

Step 1 Use the web-based CiscoSecure ACS Administrator web pages or the Java-based CiscoSecure Administrator program to do the following:

Step 2 Wait until the next scheduled replication.

The settings for the new user profile will replicate throughout the system.


hometocprevnextglossaryfeedbacksearchhelp
Copyright 1989-1998 © Cisco Systems Inc.