Veritas Volume Manager 5.0 Administrator's Guide (September 2006)

313Administering volume snapshots
Creating instant snapshots
If the cache volume is mirrored, space is required on at least as many disks as it
has mirrors. These disks should not be shared with the disks used for the parent
volumes. The disks should also be chosen to avoid impacting I/O performance
for critical volumes, or hindering disk group split and join operations.
2 Having decided on its characteristics, use the
vxassist command to create the
volume that is to be used for the cache volume. The following example creates a
mirrored cache volume, cachevol, with size 1GB in the disk group, mydg, on the
disks mydg16 and mydg17:
# vxassist -g mydg make cachevol 1g layout=mirror \
init=active mydg16 mydg17
The attribute init=active is specified to make the cache volume immediately
available for use.
3Use the vxmake cache command to create a cache object on top of the cache volume
that you created in the previous step:
# vxmake [-g diskgroup] cache cache_object \
cachevolname=volume [regionsize=size] [autogrow=on] \
[highwatermark=hwmk] [autogrowby=agbvalue] \
[maxautogrow=maxagbvalue]]
If the region size, regionsize, is specified, it must be a power of 2, and be greater
than or equal to 16KB (16k). If not specified, the region size of the cache is set to
64KB.
Note: All space-optimized snapshots that share the cache must have a region size that
is equal to or an integer multiple of the region size set on the cache. Snapshot creation
also fails if the original volume’s region size is smaller than the cache’s region size.
If the region size of a space-optimized snapshot differs from the region size of the
cache, this can degrade the system’s performance compared to the case where the
region sizes are the same.
If the cache is to be allowed to grow in size as required, specify autogrow=on. By
default, the ability to automatically grow the cache is turned off.
In the following example, the cache object, cobjmydg, is created over the cache
volume, cachevol, the region size of the cache is set to 32KB, and the autogrow
feature is enabled:
# vxmake -g mydg cache cobjmydg cachevolname=cachevol \
regionsize=32k autogrow=on
4 Having created the cache object, use the following command to enable it:
# vxcache [-g diskgroup] start cache_object
For example to start the cache object, cobjmydg:
# vxcache -g mydg start cobjmydg
For details of how to remove a cache, see “Removing a cache” on page 336.