< Previous | Next > | |
Product: Storage Foundation Guides | |
Manual: Storage Foundation 4.1 Intelligent Storage Provisioning Administrator's Guide |
Creating a Shared Cache Volume and Preparing Space-Optimized SnapshotsIf you need to create several space-optimized instant snapshots for the volumes in a disk group, you may find it more convenient to create a single shared cache volume in the disk group rather than a separate cache volume for each snapshot. To create a shared cache volume and prepare any space-optimized snapshots:
Alternatively, you can use the following command to create a cache volume and prepare the space-optimized snapshot volumes in a single operation: # vxvoladm -M make <<!! volumegroup { diskgroup "diskgroup" volume "cachevol" cache_size { type cachevolume [storage_specification] [regionsize size] } volume "sovol1" vol1_size { init active cachevolume "cachevol" } volume "sovol2" vol2_size { init active cachevolume "cachevol" } . . . }; !! Note Because of its complexity, it is recommended that you run this command as a script. For the examples given earlier in this section, the combined form of the command would be: # vxvoladm -M make <<!! volumegroup { diskgroup "mydg" volume "mycache" 1g { type cachevolume capability 'DataMirroring(nmirs=2)' } volume "mysovol" 10g { init active cachevolume "cachevol" } }; !! Tuning the autogrow AttributesThe highwatermark, autogrowby and maxautogrow attributes determine how the VxVM cache daemon (vxcached) maintains the cache if the autogrow feature has been enabled and vxcached is running:
If the autogrow feature has been disabled:
Note The vxcached daemon does not remove snapshots that are currently open, and it does not remove the last or only snapshot in the cache. If the cache space becomes exhausted, the snapshot is detached and marked as invalid. If this happens, the snapshot is unrecoverable and must be removed. Enabling the autogrow feature on the cache helps to avoid this situation occurring. However, for very small caches (of the order of a few megabytes), it is possible for the cache to become exhausted before the system has time to respond and grow the cache. In such cases, either increase the size of the cache manually as described in Growing and Shrinking a Cache, or use the vxcache set command to reduce the value of highwatermark for the cache object, as shown in this example: # vxcache -g mydg set highwatermark=60 cobjmydg You can use the maxautogrow attribute to limit the maximum size to which a cache can grow. To estimate this size, consider how much the contents of each source volume are likely to change between snapshot refreshes, and allow some additional space for contingency. If necessary, you can use the vxcache set command to change other autogrow attribute values for a cache. See the vxcache(1M) manual page for details. Caution Ensure that the cache is sufficiently large, and that the autogrow attributes are configured correctly for your needs. Growing and Shrinking a CacheYou can use the vxcache command to increase the size of the cache volume that is associated with a cache object: # vxcache [-g diskgroup] growcacheto cache_object size For example, to increase the size of the cache volume associated with the cache, mycache, to 2GB, use the following command: # vxcache -g mydg growcacheto mycache 2g To grow a cache by a specified amount, use the following form of the command: # vxcache [-g diskgroup] growcacheby cache_object size For example, to increase the size of the cache, mycache, by 1GB, you would use the following command: # vxcache -g mydg growcacheby mycache 1g You can similarly use the shrinkcacheby and shrinkcacheto operations to reduce the size of a cache. See the vxcache(1M) manual page for more information. Removing a CacheTo remove a cache completely, including the cache object, its cache volume and all space-optimized snapshots that use the cache:
|
^ Return to Top | < Previous | Next > |
Product: Storage Foundation Guides | |
Manual: Storage Foundation 4.1 Intelligent Storage Provisioning Administrator's Guide | |
VERITAS Software Corporation
www.veritas.com |