ONTAP Discussions

SnapShot reserve Issue

NARESH_MARVELL
9,842 Views

We are facing issue with Snapshot reserve.. Situation is: We created volume with snap reserve of 5 %. But the snap shot is taking 40% of the volume space.

Can any one tell what is the purpose of 5% reserve which are assigining?

Thank you in advance

Naresh

8 REPLIES 8

shaunjurr
9,842 Views

Hi,

Could you just post the output from 'df -h' from the filer cli?  (or some equivalent operation).  I am still not exactly sure what you are asking.

You might also find the answer to your question (and many others) here:

http://now.netapp.com/NOW/knowledge/docs/ontap/rel7351/html/ontap/onlinebk/frameset.html

NARESH_MARVELL
9,842 Views

df -h

Filesystem               total       used      avail capacity  Mounted on
/vol/projects21/         142GB       71GB       71GB      50%  /vol/projects21/
/vol/projects21/.snapshot     7680MB       40GB        0MB     543%  /vol/projects21/.snapshot

NARESH_MARVELL
9,842 Views

You can see the output, the snapshot is taking about 523% of the volume.

Here is the scneario...

Created volume of 100GB with Snapshot reserve of  5%. That means the snapshot should not take more than 5 GB.

In the Output you can see the snapshot is of 40 GB.

Regards

Naresh

shaunjurr
9,842 Views

Hi,

As others have tried to explain, snap reserve actually does "reserve" space for snapshots from the total size of the volume.  Snapshot usage can grow out of the reserve limits, but the active filesystem can't "grow" into the space reserved for snapshots.

You either have a lot of file turnover or you have inadvertently added and deleted a lot of file during your migration or whatever you have been doing on that filesystem of late.

'snap list -V <volname>' (on the cli or however you prefer) will show you a bit more about which snapshot is using the space.  'snap delete -V <volname> <snapshotname>' will remove a snapshot if you need to get rid of an "unneeded" snapshot.

As others have pointed out, you can setup some triggers to do some of this "automagically", but you may have the negative side-effects that the system chooses to either delete or grow when you really didn't want that.  The system can't really guess what you want, just do what you tell it, of course.

Good luck.

billshaffer
9,842 Views

Snapshot reserve only tells you what percentage of the volume size you are reserving strictly for snapshots; the filesystem data cannot write to this space.  Snapshot data, however, can and will by design write into the filesystem space if the reserve is exceeded.  This is how it is supposed to work - there is probably a document out there that details it (http://now.netapp.com/NOW/knowledge/docs/ontap/rel713/html/ontap/onlinebk/snap9.htm touches on it, but doesn't really explain it).

The only "workaround" that I've found is to reduce the number of snaps kept, turn off snaps, or find the high-change-rate data and move it to a volume with snaps disabled.

Bill

radek_kubka
9,842 Views

Snapshots may be also automatically deleted if the amount of free space goes below certain threshold (which is tunable though).

Regards,

Radek

aborzenkov
9,842 Views

Current Data ONTAP versions offer both snapshot autodelete and volume autogrow features. Both help to mitigate this issue – either filer will remove excessive snapshots, or will increase volume size (assuming containing aggregate has free space).

ivissupport
9,842 Views

Hi,

The snapshot reserve specifies a set percentage of disk space for snapshots.
By default, the snapshot reserve is 20% of disk space. The snapshot reserve can be used only by snapshots,
not by the active file system.

This means that if the active file system runs out of disk space,
any disk space still remaining in the snapshot reserve is not available for active file system use.

Snapshot reserve management involves the following tasks:

Ensuring that enough disk space is set aside for snapshots so that they do not consume active file system space
Keeping disk space consumed by snapshots below the snapshot reserve

Ensuring that the snapshot reserve is not so large that it wastes space that could be used by the active file system

When enough disk space is available for snapshots in the snapshot reserve,
deleting files in the active file system frees disk space for new files,
while the snapshots that reference those files consume only the space in the snapshot reserve.

If Data ONTAP created a snapshot when the disks were full,
deleting files from the active file system would not create any free space because everything
in the active file system would also be referenced by the newly created snapshot.

Data ONTAP would have to delete the snapshot before it could create any new files

Also use snap autodelete

You can define which Snapshot copies you delete by entering the following options and their values:

Use trigger option to define when to begin automatically deleting snapshots copies

here is the description:

trigger

Defines when to begin automatically deleting Snapshot copies.

volume--begin deleting Snapshot copies when the volume reaches 98% capacity and the volume snap reserve has been exceeded.
snap_reserve--begin deleting Snapshot copies when the Snapshot reserve reaches 98% capacity.
space_reserve--begin deleting Snapshot copies when the space reserved in the volume reaches 98% capacity and the volume snap reserve has been exceeded.


Check whether the Snap autodelete policy is setup correctly.


On ascertaining that the policy has not been removing the snapshots despite being setup correctly,
check the volume option try_first.

Type the following command from the filer command line interface: filer_cli> vol options

Output similar to the following is displayed:

test_lab_filer> vol options voltest
nosnap=off, nosnapdir=off, minra=off, no_atime_update=off, nvfail=off,
ignore_inconsistent=off, snapmirrored=off, create_ucode=on,
convert_ucode=on, maxdirsize=83886, schedsnapname=ordinal,
fs_size_fixed=off, compression=off, guarantee=volume, svo_enable=off,
svo_checksum=off, svo_allow_rman=off, svo_reject_errors=off,
no_i2p=off, fractional_reserve=0, extent=off, try_first=volume_grow,
read_realloc=off, snapshot_clone_dependency=off


By default, the volume option try_first is set to volume_grow.
However, this setting conflicts with the Snap autodelete policy and effectively results in no snapshots getting deleted.


Modify the option volume_grow to snap_delete using the following command from the filer command line:

filer_cli> vol options try_first snap_delete

From experience,

always monitor your system for functions like autodelete and autogrow when you deploy for first time

greetings

Public