There are two types of lines in the configuration file: lines that define mirror relationships and lines that define connections to source filers to be used in the relationship definitions. Relationship definition lines are used to define the mirror relationships for destination volumes on this filer. Connection definition lines are optional and are used to specify specific network connections to the source volume and allow the specification of dual paths to the source volume.
Each relationship line of the file specifies the volume or qtree to be replicated, arguments for the replication, and the schedule for updating the mirror. You may only have one line for each destination volume or qtree.
Each relationship entry of the /etc/snapmirror.conf file is a single line containing space-separated fields. The entry has this format:
source destination arguments schedule
The following list describes the fields in each entry:
source This is the name of the source host, and the volume name, or the path of the qtree to be mirrored. The name is specified as two colon-separated fields, as follows:
host:volname
host:/vol/volume/qtree
Note that the host field is not necessarily the hostname of the filer (unlike the first field of the destination entry). You can specify a network resolvable name, IP address or connection name. The host field can be considered a definition of how to reach the source over the network.
destination
This is the hostname (must match the result of the
hostname command) of the destination filer and the
name of the destination volume or the path of the
destination qtree. The name is specified as two
colon-separated fields, as follows:
name:volume
name:/vol/volume/qtree
The name field must match the hostname of the destination filer (use the hostname(1) function to check this).
arguments
These are a comma-separated list of arguments for
the transfer. To specify no arguments, enter a
dash (``-'') in this field. Each argument is specified
as a key and a value pair, as follows:
key=value
Currently, there are the following argument keys:
cksum This controls which checksum algorithm is used to protect the data transmitted by SnapMirror. Currently supported values are "crc32c" and "none".
restart
This controls the behavior of the SnapMirror
scheduler with respect to restartability.
If value is set to always, then an interrupted
transfer will always restart, if it
has a restart checkpoint and the conditions
are the same as before the transfer was
interrupted. If value is set to never, then
an interrupted transfer will never restart,
even if it has a restart checkpoint. By
default, SnapMirror behaves like the always
case, unless it has passed the next scheduled
transfer time, in which case it will
begin that scheduled transfer instead of
restarting.
outstanding
This argument controls the performance versus
synchronicity trade-off for synchronous
mirrors. The value for this argument is a
number followed by the suffixes: ops (operations),
ms (milliseconds) or s (seconds).
This governs the number of outstanding operations
a synchronous mirror can have before
forcing the client to wait for acknowledgement.
The ops suffix allows the specified
number of write operations to be outstanding
while the ms and s suffixes allow operations
in the last period of time to be outstanding
before forcing client waits. If not specified,
the default value is zero. This argument
is ignored for asynchronous mirrors.
wsize This sets the TCP window size to use for the connection. Due to how TCP negotiates window sizes, the size of the receive window will initially be large and gradually work its way down to the size specified.
visibility_interval
The value for this argument is a number
optionally followed by the suffixes: s (seconds),
m (minutes) or h (hours). If a suffix
is not specified, value is interpreted
as seconds. This argument controls the
amount of time before an automatic snapshot
is created on the source volume that is synchronously
mirrored. The value is the number
of seconds between automatically created
snapshots. The default value is 3 minutes.
A small number here can negatively affect
the performance of the mirror. This argument
is ignored for asynchronous mirrors.
schedule
This is the schedule used by the destination filer
for updating the mirror. It informs the SnapMirror
scheduler when transfers will be initiated. The
schedule field can either contain the word sync to
specify synchronous mirroring or a cron-style specification
of when to update the mirror. The cronstyle
schedule contains four space-separated
fields:
minute hour day-of-month day-of-week
Each field consists of one or more numbers or ranges. If a field contains more than one value, the values are separated from each other by a comma. A field consisting solely of an asterisk (``*'') is the same as a field enumerating all possible legal values for that field. A field consisting solely of a dash (``-'') represents a null value; any schedule with a dash in one of its fields will never run any scheduled transfers. Values in a field can take any of the following forms:
number
first-last
first-last/step
A value with a dash in it specifies a range; it is treated as containing all the values between first and last, inclusive. A range value with a slash specifies skips of step size in the range. For example, the value of the entry ``0-23/4'' would be the same as that of the entry ``0,4,8,12,16,20''.
minute Which minutes in each hour to update on. Values are from 0 to 59.
hour Which hours in the day to update on. Values are from 0 to 23.
day-of-month
Which days in the month to update on. Values
are from 1 to 31.
day-of-week
Which days in the week to update on. Values
are from 0 (Sunday) to 6 (Saturday).
Whenever the current time matches all the specified schedule fields, a transfer from the source to the destination will be invoked.
The other type of line allowed in this file is a connec_tion definition line. These lines define an alternate name for the source filer that can be used as the source host in the relationship lines. They are used to describe more specifically the parameters for the connection(s) to the source filer. SnapMirror supports the multi path specification for both asynchronous and synchronous mirrors.
Each connection definition is a single line giving a name to one or two pairs of IP addresses along with a mode of operation for the connection. The lines are specified in the following format:
name = mode( source_ip_addr1 , dest_ip_addr1 ) ( source_ip_addr2 , dest_ip_addr2 )
name This is the name of the connection you would like to define. This name is to be used as the source filer in relationship definitions.
mode The mode is optional and specifies the mode in which two IP address pairs will be used. Two modes are allowed multiplexing and failover mode and are specified by using the multi and failover keywords. If not specified, multiplexing mode is used.
The multiplexing mode causes snapmirror to use both paths at the same time. If one should fail, it will switch to use the remaining path only and use both again should the failing path be repaired.
Failover mode causes snapmirror to use the first path as the desired path and only use the second path should problems arise with the first path.
source_ip_addr1 source_ip_addr2 dest_ip_addr1
dest_ip_addr2
These are resolvable network names or IP addresses
that define a path through the network between the
source and the destination. The source addresses
are the IP addresses of interfaces to use on the
source and respectively for the destination. The
pairing denotes a path from source to destination.
toaster:/vol/vol1/home fridge:/vol/vol2/home kbs=2000 * * * *
myfiler0-gig:home myfiler1:home_mirror - 30 9,13,19 * 1,2,3,4,5
filer1:build filer2:backup - 15,45 8,9,10,11,12,13,14,15,16,17,18 * *
dev:/vol/dept/docs icebox:/vol/backup/docs_bak - 0 0 * 0
icebox:home icebox:backup - 30 0,7-21 * *
fridge-gig:db icebox:db - 0-55/5 * * *
fridge-con = failover(fridge-gig,icebox-gig)(fridge-slow,icebox-slow) fridge-con:db icebox:db - sync
Copyright © 1994-2007 Network Appliance. Legal Information