You use FlexCache volumes to speed access to remote data, or to offload traffic from heavily accessed volumes.
Before you begin
- You must have configured and enabled the FlexCache feature correctly on the caching system.
- If the origin volume is a clustered Data ONTAP volume, the following items must be true:
- There is a data LIF configured for the origin volume's SVM enabled for the -fcache protocol.
For more information about creating and configuring LIFs, see the Clustered Data ONTAP Network Management Guide.
- An export policy exists for the origin volume's SVM that includes the flexcache protocol, and all systems hosting FlexCache volumes you want to access this origin volume are listed as clients for the export policy.
For more information about creating export policies, see the Clustered Data ONTAP File Access Management Guide for NFS.
Step
- Create the volume: vol create cache_vol aggr [size{k|m|g|t}] -S origin:source_vol
origin is the name or IP address of the origin system. If you are caching a clustered Data ONTAP volume, specify the data LIF with the fcache protocol enabled.
source_vol is the name of the volume you want to use as the origin volume on the origin system.
cache_vol is the name of the new FlexCache volume you want to create.
aggr is the name of the containing aggregate for the new FlexCache volume.
size{ k | m | g | t } specifies the FlexCache volume size in kilobytes, megabytes, gigabytes, or terabytes. If you do not specify a size, bytes is used and rounded up to the nearest multiple of 4 KB.
Note: For best performance, do not specify a size when you create a FlexCache volume. Specifying a size disables the FlexCache Autogrow capability.
Result
The new FlexCache volume is created and an entry is added to the
/etc/export file for the new volume.
Example
The following command creates a FlexCache volume called newcachevol, with the Autogrow capability enabled, in the aggregate called aggr1, with a source volume vol1 on storage system corp_storage: vol create newcachevol aggr1 -S corp_storage:vol1