Managing ObjectStore

osreplic: Replicating Databases

The osreplic utility replicates and maintains multiple copies of a database.

Syntax

osreplic[-r] [-v] [-x] [-i interval] [-p] [-B size] [-I import_file] -a archive_
rec_file src_path1 dest_path1 [src_path2 dest_path2 ...]

Options
 -a archive_
record_file 
Archive. Required. Specifies the archive record file. If the file does not exist, it is created.

-B size 
Buffer. Controls the amount of transient workspace available to the source server.

size is a number optionally appended with k, m, or g to indicate kilobytes, megabytes, or gigabytes, respectively. If no unit is specified, m is presumed. For example, -B 1024k, -B 1m, and -B 1 each specify a maximum buffer size of 1 MB. The default value is 1 MB.

-i interval 
Interval. Sets the interval between snapshots. The default is 600 seconds. A copy is made immediately after osreplic is initiated, then every interval thereafter.


Intervals are specified with integer values. Append m, h, or d to a value to indicate minutes, hours, or days, respectively. By default, values are interpreted as seconds. For example, -i 60 and -i 1m both specify an interval of one minute.

-I import_file 
Import (uppercase I). Source and destination databases and directories can be specified with a separate input file as well as on the command line. Each line in the input file should consist of a source path followed by a target path. If a directory is specified, its contents are added to the source set.

-p 
Permissions. Sets permissions on the replica to match those of the master (rawfs only).

-r 
Recursive. Enables recursive processing of rawfs directories.

-v 
Verbose. Enables verbose output.

-x 
Exclude. Prohibits clients from using the replica until osreplic terminates.

-y 
Yes. Confirms the restart of the replicator for an existing master/replica pair and bypasses the usual prompt after osreplic starts. When using this option, be sure beforehand that the replica is unchanged since the last update.

Description

The ObjectStore replicator produces a continuously updated copy (or replica) of one or more user databases. The utility works by coordinating the actions of a source ObjectStore Server running an archive logger and of a target ObjectStore Server, providing a read-only (MVCC) copy of a database that is updated dynamically from the master database.

ObjectStore rawfs databases and rawfs directories can be replicated, as well as ObjectStore file databases. Native file system directories cannot be replicated.

When you start the replicator, you specify a set of sources and destinations for replicated databases on the command line or with a separate input file using the -I (I) option. The master/replica pair is specified by pathname with the src_path and dest_path arguments, including the target host, if needed. The list of databases cannot be changed after the replicator is started.

src_path and dest_path can be a directory path or a database name. You can also use UNC pathnames (on Windows platforms), Server relative pathnames, or local pathnames. However, you cannot use UNC pathnames as destinations.

You must also specify an archive_record_file with the -a option. The osreplic utility uses this information to determine those clusters within a database that have been modified since the last replication. This file is identical to the archive record file for osarchiv.

At specified intervals, the replicator takes a snapshot of the databases and sends the changed data to the target host so that the data is applied to the replica. All committed user data is replicated.

Permissions, including owner, group, and mode, can also be copied for rawfs databases. However, neither rawfs directory permissions nor segment-level permissions are copied. Additionally, no file database permissions are copied.

Operations such as osrm are not propagated to the replica.

API

None



[previous] [next]

Copyright © 1999 Object Design, Inc. All rights reserved.

Updated: 03/11/99 11:19:07