2.4 MultiSite Use Model

The following sections describe the different aspects of your MultiSite use model.

Type of Administration

While you are planning your implementation, you need to decide how much control the individual sites will have over their replicas. Your choices are centralized administration, individual administration, or some combination of the two.

You can also have semi-centralized administration. For example, you may have MultiSite administrators at sites with major development efforts and give these administrators control over their MultiSite environment. The responsibility for administering smaller sites is distributed among the MultiSite administrators.

Mastership Strategy

The choices you make for your ClearCase use model and MultiSite administration model determine your mastership strategy. Your plan should state which replicas will master branch types, label types, elements, and other VOB objects. After you create the replicas in the VOB family, you can change mastership of objects. For more information, see Enabling Independent VOB Development: Mastership and Changing Mastership.

Replica Permission Strategy

When you import a replica-creation packet, you must specify whether the new replica is ownership-preserving or non-ownership-preserving. In most cases, your replicas must be non-ownership-preserving. For information about the requirements for creating ownership-preserving replicas, see Element Ownership and Ownership Preservation.

If you plan to create one or more ownership-preserving VOB replicas, follow these steps:

  1. At the exporting site, gather the current VOB ownership and group information and send it along with the packets created by mkreplica -export.

    1. Get the name of the VOB owner and VOB groups, using the cleartool describe command on the VOB object. For example:

    2. cleartool describe vob:/vobs/dev
      versioned object base "/vobs/dev"
      created 15-Aug-00.14:19:03 by CC Admin (ccadm.user@minuteman)
      VOB family feature level: 1
      VOB storage host:pathname "minuteman:/vobstg/dev.vbs"
      VOB storage global pathname "/net/minuteman/vobstg/dev.vbs"
      database schema version: 53
      VOB ownership:
      owner purpledoc.com/ccadm
      group purpledoc.com/user


    3. Translate the symbolic names to numbers. On UNIX, become the VOB owner and issue the id command. For example:

    4. su ccadm
      Password: xxxxxx
      id
      uid=1083(ccadm) gid=20(user)


  2. At each importing site, ensure that the user ID, primary group, and secondary groups match the information from the exporting site, in name and number.

  3. If they do not match, you must modify the user and group information to prevent import failures due to permissions problems, as described in Ownership Preservation.

    If the names are the same and the numbers are different, you must create non-ownership-preserving replicas.

Synchronization Method

There are multiple methods you can use to transport MultiSite packets. The method you choose depends on how your sites are connected, how quickly you must transfer packets, and how important security is. Table 4 lists the recommended methods for various situations.

Table 4 Choosing a Packet Transfer Method


Your situation

Recommended methods

Source of more information

Sites are connected with high-speed lines


shipping_server


Transferring Packets with Store-and-Forward
shipping_server reference page


One or more sites have firewalls


Tape, diskette, CD-ROM, e-mail, ftp, shipping_server


Using MultiSite through a Firewall
syncreplica reference page


Must transfer packets quickly


E-mail, ftp, shipping_server


shipping_server reference page, syncreplica reference page


No electronic connection between sites


Tape, diskette, CD-ROM


syncreplica reference page


Synchronization Pattern

The synchronization pattern for a VOB family defines which replicas exchange update packets and the direction of exchange. Your choice of pattern depends on the following factors:

The following sections describe unidirectional and bidirectional exchanges and the most common synchronization patterns.

Directions of Exchange

Synchronization can be unidirectional or bidirectional, as shown in Figure 10.

Figure 10 Unidirectional and Bidirectional Updating

In most cases, you will use bidirectional updating. Unidirectional updates are suitable in situations like these:

However, unidirectional updates carry some risk. For example, an accidental change of mastership cannot be fixed, and restoring from a replica that does not exchange updates directly with the broken replica involves extra work. Also, you must ensure that no work is done accidentally in a read-only replica; do this by creating triggers or locking the VOB to prevent checkouts and creation of metadata.

One-to-One and Ring Synchronization

Figure 11 One-to-One Synchronization Pattern

Figure 12 Ring Synchronization Pattern

The simple one-to-one and ring (or round-robin) patterns are simple patterns that are most suitable for small numbers of replicas. As the number of replicas grows larger, the amount of time increases for a change made at one replica to be received at a replica at the other side of the ring.

One-to-Many Synchronization

Figure 13 Single-Hub Synchronization Pattern

Figure 14 Multiple-Hub Synchronization Pattern

Figure 15 Tree Synchronization Pattern

Advantages:

Disadvantages:

Many-to-Many Synchronization

Figure 16 Many-to-Many Synchronization Pattern

Advantages:

Disadvantages:

Synchronization Schedule

The synchronization schedule for a VOB family defines when replicas in the family send and receive updates. The schedule is affected by many factors, including the rate of development at different sites, the connections among sites, and whether you use MultiSite as a backup strategy.

Consider the following issues when planning your synchronization strategy:

Use of MultiSite for Backups

You can use MultiSite as part of your VOB backup strategy. For more information, see Chapter 11, Backing Up VOBs with MultiSite.

Scrubbing Parameters for VOB Replicas

When a ClearCase or MultiSite command makes a change to a replica, an oplog entry is recorded in the replica's database. (See VOB Operations and the Oplog for more information on this mechanism.) Also, when you export an update packet, an export_sync record is created for each target replica. These records are stored in the VOB database and are used by the recoverpacket command to reset a replica's epoch number matrix.

You can scrub oplog entries and export_sync records to reclaim disk space and database records, but you must keep them long enough to ensure that you can recover from replica failures and packet losses. The following sections give guidelines for configuring scrubbing frequency.

For more information on VOB scrubbing, see the ClearCase vob_scrubber reference page.

Oplog Scrubbing

Oplog entries must be kept in the database for a significant period. In the near term, they are required when the replica generates update packets to be sent to all other replicas. Beyond that, entries may be required to help other replicas recover from catastrophic failures. If no replica can supply these entries, the replica being restored must be re-created. (See Restoring a Replica from Backup.) Because of the need to use oplog entries during synchronization, your synchronization strategy determines how often oplogs can be scrubbed.

By default, an oplog entry is never scrubbed. Do not change this setting until you establish the synchronization pattern in the VOB family and verify that packets are being exported and imported successfully.

When it is safe to delete oplog entries for a replica, follow these steps:

  1. Coordinate with administrators at other sites to decide how long each site must keep oplog entries.

  2. Each site must keep entries for as long as necessary to allow restorereplica operations to complete successfully. The frequency with which you scrub oplogs depends on the following factors:

  3. Change the oplog scrubbing parameter for your replica:

    1. Copy ccase-home-dir/config/vob/vob_scrubber_params (UNIX) or ccase-home-dir\config\vob\vob_scrubber_params (Windows) to the VOB storage directory of the replica. This creates a parameter file specific to the VOB.

    2. Make this new file writable.

    3. Edit the oplog line in this file. For example, to keep oplog entries for two months (62 days):

    4. oplog -keep 62

CAUTION: If a replica's oplog entries are scrubbed before they are included in an update packet, you cannot export update packets from the replica. This is a serious error and compromises the integrity of the entire VOB family.

export_sync Scrubbing

export_sync records are not necessary for normal synchronization operation. They are different from export event records, which also record synchronization exports and are included in output from the lshistory command and the History Browser.

export_sync records are date-based records used by the recoverpacket command to reset a replica's epoch number matrix. If you do not use this packet recovery method (because you use chepoch -actual or lsepoch/chepoch), you can scrub these records aggressively. If you use the recoverpacket command, you must keep export_sync records for the number of days that elapse between VOB backups. (See Recovering from Lost Packets.)

By default, the vob_scrubber_params file has no entry for export_sync records, and these records are scrubbed with the same frequency as oplog entries. If you want to scrub export_sync records at a different frequency than oplog entries, you can set the export_sync parameter in the vob_scrubber_params file. For more information, see the vob_scrubber reference page.