FlexCache Technical FAQ

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

Technical FAQ

FlexCache in ONTAP
ONTAP 9.13.1
Elliott Ecton, NetApp
May 2023

Abstract
This technical FAQ is meant to assist NetApp systems engineers, professional services,
support and partners by providing answers to frequently asked questions about the use and
implementation of the NetApp® FlexCache® feature.
TABLE OF CONTENTS

Purpose ........................................................................................................................................................ 4

Frequently asked questions ...................................................................................................................... 4


Requirements ..........................................................................................................................................................4
What is NetApp FlexCache?...................................................................................................................... 4
What versions of ONTAP do I need to run? .............................................................................................. 4
What platforms support FlexCache volumes? ........................................................................................... 4
Do I need a license? .................................................................................................................................. 4
How is the storage counted against the license?....................................................................................... 4
General ....................................................................................................................................................................4
Can I write to a FlexCache volume? .......................................................................................................... 4
How do the FlexCache and origin clusters talk to each other? .................................................................. 4
Will the FlexCache volume still work when the origin and FlexCache volume can’t communicate? .......... 4
What protocols can I use to access the FlexCache volume? .................................................................... 4
What protocols can I use to access the origin volume? ............................................................................. 5
Can I use FlexCache technology for SAN/volumes with LUNs? ................................................................ 5
Can I grow or shrink the FlexCache volume? ............................................................................................ 5
Will writes and reads to the FlexCache volume use locks? ....................................................................... 5
Do export policies or rules get copied over to the FlexCache volume? ..................................................... 5
Does the origin need to be online, mounted, and/or shared/exported? ..................................................... 5
What security styles can I use for the origin volume? ................................................................................ 5
Can I use NTFS or NFSv4 ACLs? ............................................................................................................. 5
Can I use system access control lists (SACLs) for auditing? ..................................................................... 5
Does the FlexCache technology use storage efficiencies? ....................................................................... 5
Can I create a FlexCache volume and then sever the relationship to make it an independent volume? ... 5
Can I create a FlexCache volume from a FlexGroup origin volume? ........................................................ 6
Can the FlexCache volume be a FlexVol volume? .................................................................................... 6
Can I prepopulate FlexCache data? .......................................................................................................... 6
How large does a FlexCache volume need to be? .................................................................................... 6
Can a FlexCache volume be a 100% replica? ........................................................................................... 6
Can changes at the origin be pushed to a FlexCache volume? ................................................................ 6
How long does it take for changes at the origin to reflect to the FlexCache volume? ................................ 6
Is the FlexCache volume persistent (Does a reboot, failover or other event clear the cache)? ................. 6
Can I use NetApp Snapshot™ copies at the FlexCache volume? .............................................................. 6
Is the FlexCache volume traffic encrypted over the wire? ......................................................................... 7
Do export policies also get cached at the FlexCache volume?.................................................................. 7
Is the entire file evicted from the cache if a change is made at the origin? ................................................ 7
Can a SnapMirror secondary volume be the origin of a FlexCache relationship? ..................................... 7
How many caches can be associated with a single FlexCache origin volume?......................................... 7
If the atime is updated on a file after a read at the origin, does that evict the file at the cache? ................ 7

2 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
How do I configure the atime-update-period? ............................................................................................ 7
Does FlexCache support nested volumes? ............................................................................................... 7
Does FlexCache support FlexClones as an origin? ................................................................................... 7
Does FlexCache support mixed-security style? ......................................................................................... 8
Are SMB Change Notifies supported at the cache? .................................................................................. 8
Can I change the name of the FlexCache origin without breaking the FlexCache relationship? ............... 8
I would like to join the public preview for FlexCache Write Performance (Writeback) available in ONTAP
9.12.1. How do I go about this? ................................................................................................................. 8
I need the FlexCache volume to always maintain a size relative to the origin. Can I do that? ................... 8
Can I enable ‘is-relative-size-enabled’ on an existing FlexCache volume? ............................................... 8
Can I modify the ‘relative-size-percentage’ after it has been set? ............................................................. 8
What happens to the size of the cache if I disable ‘is-relative-size-enabled?’ ........................................... 8
Why does a READ operation at the cache fail if the origin is full? ............................................................. 8

Where to find additional information ........................................................................................................ 8

Version history ............................................................................................................................................ 9

3 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
Purpose
The purpose of this technical FAQ is to answer questions surrounding the use and implementation of
FlexCache technology in NetApp ONTAP®.

Frequently asked questions


Requirements
What is NetApp FlexCache?
Answer: It is a sparsely populated cache of data from a particular volume called the origin. Data is only
cached when a client connected to the cache reads it.

What versions of ONTAP do I need to run?


Answer: The cluster that owns the origin and the cluster that owns the FlexCache volume must both be
running at least ONTAP 9.5.

What platforms support FlexCache volumes?


Answer: NetApp AFF, FAS, NetApp ONTAP Select, and NetApp Cloud Volumes ONTAP are currently
supported.

Do I need a license?
Answer: For ONTAP 9.5 and ONTAP 9.6, yes. FlexCache licenses are a subscription-based capacity
license. The license cost is $0, but it is still required to create FlexCache volumes. For ONTAP 9.7 and
later, no license is required.

How is the storage counted against the license?


Answer: The total of all the FlexCache volume sizes in a cluster are counted against the license. If
autogrow is used, it is the current size of the volume. When the volume grows, the additional capacity that
autogrow has applied to the FlexCache volume is then counted against the license.

General
Can I write to a FlexCache volume?
Answer: Yes. Writes do not write to the FlexCache volume but are forwarded to the origin volume by
ONTAP due to the write-around nature of the cache.

How do the FlexCache and origin clusters talk to each other?


Answer: They communicate through cluster and SVM peers and use the intercluster LIFs for this
communication.

Will the FlexCache volume still work when the origin and FlexCache volume can’t communicate?
Answer: There are some resrtrictions but FlexCache software has a disconnected mode that will allow
already cached data to be served.

What protocols can I use to access the FlexCache volume?


Answer: As of ONTAP 9.10.1, any NAS protocol ONTAP supports is supported at the cache.

4 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
What protocols can I use to access the origin volume?
Answer: Any NAS protocol ONTAP supports is supported at the origin.

Can I use FlexCache technology for SAN/volumes with LUNs?


Answer: No. FlexCache technology is designed for NAS only.

Can I grow or shrink the FlexCache volume?


Answer: You can grow FlexCache volumes manually or through autosize. Beginning in ONTAP 9.6, you
can shrink the FlexCache volume.

Will writes and reads to the FlexCache volume use locks?


Answer: Yes. Locks work across the origin and caches the same way as when accessing a single
volume. A lock on file ‘x’ will be honored at all caches and the origin.

Do export policies or rules get copied over to the FlexCache volume?


Answer: Export policies and rules are independent between the origin and FlexCache volume. No copy or
replication occurs.

Does the origin need to be online, mounted, and/or shared/exported?


Answer: The origin has to be online for a FlexCache volume to be created from it and serve data,
however, the origin volume does not need to be mounted to a junction path on the SVM. The only reason
an origin volume needs to be mounted and shared or exported is when NAS access is required at the
origin.

What security styles can I use for the origin volume?


Answer: Any security style is supported. (Mixed style is not recommended.)

Can I use NTFS or NFSv4 ACLs?


Answer: Access control lists (ACLs) can be used and will even be enforced at the the FlexCache volume.
For ACLs to be properly enforced at the FlexCache volume, the SVM owning the FlexCache volume must
have the CIFS server set up in the same Active Directory domain, or an LDAP client configured to the
same domain set up as the SVM owning the origin.

Can I use system access control lists (SACLs) for auditing?


Answer: Auditing is supported for origin volumes in ONTAP 9.7. You can configure auditing reads at the
cache volume or volumes, but they must be configured at each cache.

Does the FlexCache technology use storage efficiencies?


Answer: Background dedupe and compression are supported as of ONTAP 9.6. Thin provisioning,
compaction and cross-volume deduplication is available as of ONTAP 9.7.

Can I create a FlexCache volume and then sever the relationship to make it an independent
volume?
Answer: You can only create and delete a FlexCache volume. There is no provision to break the
relationship and make it an independent volume.

5 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
Can I create a FlexCache volume from a FlexGroup origin volume?
Answer: ONTAP 9.7 and later supports a FlexGroup volume as an origin volume. Both the cluster hosting
the cache and the origin need to run ONTAP 9.7 or later.

Can the FlexCache volume be a FlexVol volume?


Answer: No. The FlexCache volume can only be a FlexGroup volume by design.

Can I prepopulate FlexCache data?


Answer: There are a few ways you can prepopulate FlexCache data. One way is to use a Linux client to
prepopulate data. The easiest way is to run the command “find . -type f -exec sh -c "cat {}
> /dev/null" \;” from the directory that needs prepopulated. If speed of prepopulation is important,
consider using XCP to prepopulate by using the command “xcp scan -md5 -q server:/path”.
Beginning with ONTAP 9.8, you can prepopulate the cache using the ONTAP CLI by running the
following command in advanced mode: “flexcache prepopulate start -cache-vserver svm -
cache-volume volume_name -path-list /path”.

How large does a FlexCache volume need to be?


Answer: As large as it needs to be. The size of the FlexCache volume only needs to be the size of the
data you want cached. There are detailed caveats outlined in TR-4347: FlexCache in ONTAP. If the
FlexCache volume is not large enough to cache certain file sizes, then those files are served but never
cached, so the penalty of the network between the cache and the origin always applies. If the FlexCache
volume is not large enough to hold the working dataset, then the least recently used files are evicted in
favor of the new files. This causes a re-caching of those evicted files when they are read again, thus
incurring the penalty of the network between the cache and the origin again.

Can a FlexCache volume be a 100% replica?


Answer: Yes. If the FlexCache is at least the size of the used space of the origin, it has the ability to
cache 100% of the data. By default, a FlexCache volume is sparse (empty at creation) and if 100% of the
data is read and there is space, then it will be cached.

Can changes at the origin be pushed to a FlexCache volume?


Answer: Changes of the origin data only mark the files invalid at the caches. This does not push the
changes to the caches. The caches read and re-cache the data from the origin when a client connected
to the cache requests that data.

How long does it take for changes at the origin to reflect to the FlexCache volume?
Answer: Unless the FlexCache volume is disconnected, meaning the cluster owning the FlexCache
volume cannot communicate with the cluster owning the origin, changes at the origin immediately
invalidate the cached files. Therefore, the next read of those cached files result in fetching it from the
origin. This means that changes at the origin are virtually immediate.

Is the FlexCache volume persistent (Does a reboot, failover or other event clear the cache)?
Answer: FlexCache technology is a persistent cache. No node event (HA failover, reboot, and so on)
evicts cached files.

Can I use NetApp Snapshot™ copies at the FlexCache volume?


Answer: Snapshot copies are only supported at the origin. If clients need access to the Snapshot copies,
the Snapshot copies must be mounted at the origin volume. Snapshot copies are not replicated to the
FlexCache volume.

6 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
Is the FlexCache volume traffic encrypted over the wire?
Answer: Beginning with ONTAP 9.6, you can encrypt cluster peer traffic if both clusters are running
ONTAP 9.6. If the cluster peer relationship was created before either cluster ran ONTAP 9.6, then after
both clusters are upgraded, the peer relationship settings must be modified to begin in-flight encryption.
Any new peers that are created when both clusters run ONTAP 9.6, in-flight encryption is enabled by
default.

Do export policies also get cached at the FlexCache volume?


Answer: No. Export policies are not cached or copied. The FlexCache volume’s export policies are
independent of the origin export policies.

Is the entire file evicted from the cache if a change is made at the origin?
Answer: In releases earlier than ONTAP 9.8, any modification to a file at the origin causes the entire file
to be evicted from the cache. Beginning with ONTAP 9.8, block level invalidation is introduced. Only the
modified blocks within a file are evicted from the cache when this option is enabled. This option is
disabled by default. To enable it, run the following command for the ONTAP CLI in advanced mode:
flexcache origin config modify -origin-vserver <svm> -origin-volume <volume> -is-bli-enabled true

Can a SnapMirror secondary volume be the origin of a FlexCache relationship?


Answer: ONTAP 9.8 and later supports SnapMirror secondary volumes as the origin of a FlexCache
relationship. This will be a read-only cache regardless of export-policy or CIFS share permissions.

How many caches can be associated with a single FlexCache origin volume?
Answer: In releases earlier than ONTAP 9.8, only ten caches are allowed per FlexCache origin. In
ONTAP 9.8 and later, the limit is increased to 100 caches per FlexCache origin.

If the atime is updated on a file after a read at the origin, does that evict the file at the cache?
Answer: In releases earlier than ONTAP 9.11.1, NetApp recommends that you disable atime update on
the origin volume to prevent cache evictions after a read operation. Beginning in ONTAP 9.11.1, there is
an option to set the -atime-update-period on the origin. When the atime-update-period value is set greater
than zero, no read operations invalidate the cache until the atime-update-period expires.

How do I configure the atime-update-period?


Answer: The atime-update-period parameter is configured through the ONTAP CLI on the origin only. The
value set is in seconds and is propogated to all caches associated with the origin. The maximum value is
4294967295 seconds. To enable and configure this option, run the following ONTAP CLI commands in
advanced mode.
volume modify -vserver <svm> -volume <origin_volume> -atime-update true -atime-update-period
<1…4294967295>
volume modify -vserver <svm> -volume <cache_volume> -atime-update true

Does FlexCache support nested volumes?


Answer: No. You can not cache an origin with nested volumes

Does FlexCache support FlexClones as an origin?


Answer: Yes. FlexClones can be the origin for a FlexCache cache volume

7 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
Does FlexCache support mixed-security style?
Answer: Yes. FlexCache supports mixed-security style

Are SMB Change Notifies supported at the cache?


Answer: No. SMB Change Notifies are not supported at the cache. Bug 1543131 is to address the error
returned by ONTAP when an SMB client attempts to set a Change Notify at the cache. Currently, no error
is returned, and the Change Notify is silently ignored.

Can I change the name of the FlexCache origin without breaking the FlexCache relationship?
Answer: Yes. You may rename the origin at will without any impact on the cache(s) associated with it

I would like to join the public preview for FlexCache Write Performance (Writeback) available in
ONTAP 9.12.1. How do I go about this?
Answer: Please go here for information on how to get involved in the public preview of FlexCache Write
Performance (writeback).

I need the FlexCache volume to always maintain a size relative to the origin. Can I do that?
Answer: ONTAP 9.13.1 introduces ‘Follow the Origin’ to FlexCache. To enable this feature, use the
following command in advanced privilege mode: flexcache config modify -volume flexcache
-vserver <svm> -is-relative-size-enabled true -relative-size-percentage
<1..100>

Can I enable ‘is-relative-size-enabled’ on an existing FlexCache volume?


Answer: Yes. You can enable relative sizing on existing FlexCache volumes.

Can I modify the ‘relative-size-percentage’ after it has been set?


Answer: Yes. However, if the percentage being set is smaller than the amount of data already present in
the cache, ONTAP will log an error and provide the minimum percentage you can set it to.

What happens to the size of the cache if I disable ‘is-relative-size-enabled?’


Answer: The cache will remain at the size it was before disabling relative size.

Why does a READ operation at the cache fail if the origin is full?
Answer: A read at the cache requires an entry be written to the remote entry metafile (REM) file at the
origin. If the origin is full, the REM entry can’t be created, and ONTAP has to fail the operation. Starting in
ONTAP 9.13.1, READ operations can be serviced directly by the origin, eliminating the need to log an
entry in the REM file. This results in NFSv3 successfully reading a file when the origin is full, and NFSv4.x
and SMB possibly being able to read a file when the origin is full.

Where to find additional information


To learn more about the information described in this document, refer to the following documents and/or
websites:
• FlexCache Volumes for Faster Data Access Power Guide
http://docs.netapp.com/ontap-9/topic/com.netapp.doc.pow-fc-mgmt/home.html
• TR-4743: FlexCache in ONTAP
http://www.netapp.com/us/media/tr-4743.pdf

8 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
• TR-4571: NetApp FlexGroup Volume Best Practices and Implementation Guide
http://www.netapp.com/us/media/tr-4571.pdf
• TR-4557: NetApp FlexGroup Volumes A Technical Overview
http://www.netapp.com/us/media/tr-4557.pdf

Version history
Version Date Document version history
Version 1.0 November 2018 Initial release for ONTAP 9.5
Version 1.1 April 2019 Updates for ONTAP 9.6
Version 1.2 August 2019 FlexCache Licensing updates
Version 1.3 December 2019 Updates for ONTAP 9.7 – Chris Hurley
Version 2.0 June 2022 Updates for ONTAP 9.8, 9.9.1, 9.10.1, and 9.11.1 – Elliott Ecton
Version 2.1 April 2023 Updates for 9.12.1
Version 2.2 May 2023 Updates for 9.13.1

9 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL
Refer to the Interoperability Matrix Tool (IMT) on the NetApp Support site to validate that the exact
product and feature versions described in this document are supported for your specific environment. The
NetApp IMT defines the product components and versions that can be used to construct configurations
that are supported by NetApp. Specific results depend on each customer’s installation in accordance with
published specifications.
Copyright information
Copyright © 2023 NetApp, Inc. All rights reserved. Printed in the U.S. No part of this document covered
by copyright may be reproduced in any form or by any means—graphic, electronic, or mechanical,
including photocopying, recording, taping, or storage in an electronic retrieval system—without prior
written permission of the copyright owner.
Software derived from copyrighted NetApp material is subject to the following license and disclaimer:
THIS SOFTWARE IS PROVIDED BY NETAPP “AS IS” AND WITHOUT ANY EXPRESS OR IMPLIED
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, WHICH ARE HEREBY
DISCLAIMED. IN NO EVENT SHALL NETAPP BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
THE POSSIBILITY OF SUCH DAMAGE.
NetApp reserves the right to change any products described herein at any time, and without notice.
NetApp assumes no responsibility or liability arising from the use of products described herein, except as
expressly agreed to in writing by NetApp. The use or purchase of this product does not convey a license
under any patent rights, trademark rights, or any other intellectual property rights of NetApp.
The product described in this manual may be protected by one or more U.S. patents, foreign patents, or
pending applications.
LIMITED RIGHTS LEGEND: Use, duplication, or disclosure by the government is subject to restrictions
as set forth in subparagraph (b)(3) of the Rights in Technical Data—Noncommercial Items at DFARS
252.227-7013 (FEB 2014) and FAR 52.227-19 (DEC 2007).
Data contained herein pertains to a commercial product and/or commercial service (as defined in FAR
2.101) and is proprietary to NetApp, Inc. All NetApp technical data and computer software provided under
this Agreement is commercial in nature and developed solely at private expense. The U.S. Government
has a non-exclusive, non-transferrable, non-sublicensable, worldwide, limited irrevocable license to use
the Data only in connection with and in support of the U.S. Government contract under which the Data
was delivered. Except as provided herein, the Data may not be used, disclosed, reproduced, modified,
performed, or displayed without the prior written approval of NetApp, Inc. United States Government
license rights for the Department of Defense are limited to those rights identified in DFARS clause
252.227-7015(b) (FEB 2014).
Trademark information
NETAPP, the NETAPP logo, and the marks listed at http://www.netapp.com/TM are trademarks of
NetApp, Inc. Other company and product names may be trademarks of their respective owners.

10 FlexCache in ONTAP © 2023 NetApp, Inc. All rights reserved. NETAPP CONFIDENTIAL

You might also like