ETERNUS SF AdvancedCopy Manager Operator's Guide 13.0 -Solaris-
Contents Index PreviousNext

Appendix C Preprocessing and Postprocessing of Replication

This chapter explains the shell scripts that perform the pre- and post-processing of replication in AdvancedCopy Manager.

C.1 Overview 

The shell scripts that perform the pre- and post-processing of replication start before and after replication (copy) processing.

These shell scripts contain processing code required by AdvancedCopy Manager for the copy source volume and copy destination volume.

This chapter describes the setup of preprocessing and postprocessing.

C.2 Preprocessing and Postprocessing of Replication 

The replication preprocessing and postprocessing in AdvancedCopy Manager needs to be performed for both the replication source volume and the replication destination volume. However, the purpose for each is different.

Specific processing performed in preprocessing and postprocessing varies according to the data on the volume. The next section describes the preprocessing and postprocessing of a file system and a database.

C.2.1 Preprocessing and postprocessing for a file system 

The preprocessing and postprocessing for a file system is the unmount processing and mount processing of the file system. (For Windows, the processing consists of allocating and canceling a drive letter.) The preprocessing and postprocessing for the replication source volume ensure the integrity of the replication source data. The preprocessing and postprocessing for the replication destination volume are performed to make access from other processes during synchronization processing and snapshot copying impossible. If no volume is mounted, the preprocessing and postprocessing are not performed.

The implementation status of the preprocessing and postprocessing for a file system is shown below. This table shows whether preprocessing and postprocessing are performed depending on the command type .It also shows the copy status upon execution of the command.

[Table C.1 Preprocessing and postprocessing for a file system]

Command

Copy status

Source/target

Preprocessing

Postprocessing

Replication start command

(swsrpstartsync)

uncopy or

replication establishment

Source

X

X

target

O--*1

X

Replication making command

(swsrpmake)

equivalence maintenance

Source

O

O

target

X

O--*2

Replication cancellation command

(swsrpcancel)

equivalence maintenance

Source

O

O

target

X

O--*2

Replication establishment

Source

X

X

target

X

X

copying

Source

X

X

target

X

X

Snap shot replication making command

(swsrpmake)

uncopy

Source

O

O

target

O

O


O : executed, X : not executed

The postprocessing for the preprocessing performed in (1) is performed in (2). In the postprocessing in (2), re-mount is performed for the mount point where unmount was performed in the preprocessing in (1).

The preprocessing and postprocessing for a file system can be customized. The processing is started in accordance with the table above when a replication management command is executed. For replication between servers, these scripts are executed by remote execution by TCP/IP in the preprocessing and postprocessing of a volume that is not connected.

The operation image before and after processing is shown in Figure C.1.

[Figure C.1 Synchronized replication processing]

If processing other than the standard preprocessing and postprocessing is required in the preprocessing and postprocessing, customize the scripts.

When customizing a script, strictly observe the following rules regarding error code:

Error code

Usage

0-99

Unusable (reserved for AdvancedCopy Manager)

100-255

Usable

AdvancedCopy Manager does not support any functions for the preprocessing and postprocessing of a database. You will need to perform your own preprocessing and postprocessing before and after the execution of a AdvancedCopy Manager command.

C.2.2 Preprocessing when replication is executed 

The replication source volume (RepSrcPre.js) and the replication destination volume (RepDstPre.js) are prepared for a pretreatment script, and it is stored in the following directory subordinates. Please customize a script according to the necessity for processing.

In the case of non-cluster operation

/etc/opt/FJSVswsrp/sh directory subordinate

In the case of cluster operation

/etc/opt/FJSVswsrp/<logic node name>/sh directory subordinate

+If you do not want to unmount the copy source volume

To reproducing agency volume not to unmount although mounted, please make the following examples of customize reference and customize a script.

This operation is possible only when the file system is one of the following two:

The preprocessing and postprocessing of the copy source volume in the customized script is described below.

Copy source volume status

Copy source preprocessing

Copy source postprocessing

Mounted

Suppresses updating of the copy source volume

Cancels the suppressed updating of the copy source volume

The preprocessing and postprocessing of the copy destination volume in the customized script is described below.

Copy destination postprocessing

Check of matching of the copy destination volume

In the employment which used the standard script, since the beginning of the cash of a file system and renewal of subsequent are deterred by unmounting a file system before an advanced copy (EC/OPC), the adjustment of the data of the whole file system is guaranteed.
Although the flash of the cash of a file system and renewal of subsequent are deterred using lockfs-w when customizing a script and not unmounting a file system, a guarantee of the contents of a file is not offered about the file in Write Open (the database space of Oracle which is supporting on-line backup removes).
Moreover, when there is a process under renewal of metadata, the data adjustment of the file system itself is not secured on the specification of lockfs, either.
Therefore, it is necessary to take into consideration and cope with it by employment about the data adjustment when not unmounting a file system.

C.2.3 Postprocessing when replication is executed 

The replication source volume (RepSrcPost.js) and the replication destination volume (RepDstPost.js) are prepared for a post-processing script, and it is stored in the following directory subordinates. Please customize a script according to the necessity for processing.

In the case of non-cluster operation

/etc/opt/FJSVswsrp/sh directory subordinate

In the case of cluster operation

/etc/opt/FJSVswsrp/<logic node name>/sh directory subordinate

+When cluster operation by VERITAS Cluster Server

Customize of a preprocessing and postprocessing script is needed, when performing cluster oprating by VERITAS Cluster Server, and when mount point of original/source volume is registered into cluster transaction.

Please change unmount/mount processing in preprocessing and postprocessing script into offline/online processing of mount point resource.

Moreover, the Volume is actually after doing offline/online of mount point resource and there will be a time difference by the time mount/unmount is done.

Therefore, please add the processing (The Result of sleep and the df Command is observed) meets until mount/unmount is actually done after the location where the success or failure of offline/online is judged.

The examples below show how the preprocessing and postprocessing scripts are modified.

[Example] unmount processing change of source volume preprocessing script (RepSrc.pre)

[lines 89,99th]

(Before change)

/usr/sbin/umount $mount_point

(after change)

/opt/VRTSvcs/bin/hares -offline resource-name -sys system-name

[Example] unmount wait processing addtion of source volume preprocessing script (RepSrc.pre)

[line 118th]

(addition)

while /usr/sbin/df -l "$device">/dev/null 2>&1; do :; done

[Example] unmount processing change of destination volume preprocessing script (RepDst.pre)

[lines 74,84th]

(Before change)

/usr/sbin/umount $mount_point

(after change)

/opt/VRTSvcs/bin/hares -offline resource-name -sys system-name

[Example] unmount wait processing addtion of destination volume preprocessing script (RepDst.pre)

[line 103rd]

(addition)

while /usr/sbin/df -l "$device">/dev/null 2>&1; do :; done

[Example] mount processing change of source volume postprocessing script (RepSrc.post)

[lines 99,103,105,118,122,124th]

(Before change)

/usr/sbin/mount $lvname $lv_mount_point

(after change)

/opt/VRTSvcs/bin/hares -online resource-name -sys system-name

[Example] mount wait processing addtion of source volume postprocessing script (RepSrc.post)

[line 144th]

(addition)

until /usr/sbin/df -l "$device">/dev/null 2>&1; do :; done

[Example] mount processing change of destination volume postprocessing script

[lines 153,160,172,179th]

(Before change)

/usr/sbin/mount $lvname $lv_mount_point

(after change)

/opt/VRTSvcs/bin/hares -online resource-name -sys system-name

[Example] mount wait processing addtion of destination volume postprocessing script

[line 197th]

(addition)

until /usr/sbin/df -l "$device">/dev/null 2>&1; do :; done


Contents Index PreviousNext

All Rights Reserved, Copyright(C) FUJITSU LIMITED 2002-2006