You can create
and mount shadow sets using the $MOUNT system service in a user-written
program. Program calls to $MOUNT that create, mount, or add devices
to shadow sets use the same syntax. To direct the system to perform
any mount operation, you construct a $MOUNT item list. The item list
specifies the virtual unit that represents the shadow set and the
members (physical devices) that the shadow set contains.
The call to the $MOUNT system service has the
Example 5-1 illustrates MACRO-32 statements that produce
a $MOUNT system service item list to create and mount a shadow set.
Example 5-1 Item List to Create and Mount a Shadow Set
The following list describes the elements in Example 5-1:
Notice that the virtual unit item descriptor occurs
first. This item descriptor specifies DSA23 as the name of the virtual
unit. See “Creating a Shadow Set ” for the proper naming syntax for the virtual unit and shadow set
The virtual unit item descriptor is followed by two
member-unit item descriptors. Because Volume Shadowing for OpenVMS
automatically determines the type of operation (copy or merge) necessary
before disks can join a shadow set, all of the devices are mounted
with MNT$_SHAMEM item descriptors. These item descriptors specify
that the physical devices, $4$DUA9 and $4$DUA5, are to join the shadow
set represented by DSA23.
The member item descriptors are followed by an item
descriptor that specifies MYVOLUME as the volume label for the shadow
The last item descriptor specifies DISK$MYVOLUME as
the logical name for the shadow set.
Later, if you want to add another device to the
shadow set, you make another call to $MOUNT that specifies an item
list that contains the name of the virtual unit and the name of the
device you want to add to the shadow set. Example 5-2 shows how
to add the physical device $4$DUA10: to the shadow set created in Example 5-1.
Example 5-2 Item List to Add a Member to a Shadow Set
“$MOUNT Shadow Set Item Codes” briefly describes the $MOUNT shadow
set item codes and discusses how to construct a valid $MOUNT item
list. For a complete description of the $MOUNT service and all its
item codes, see the HP OpenVMS System Services Reference