Sunday, June 24, 2012

Netapp volume Snapshot: Complete Reference

A Snapshot is a locally retained point-in-time image of data. NetApp Snapshot technology is a feature of the WAFL (Write Anywhere File Layout) storage virtualization technology that is a part of Data ONTAP, the microkernel that ships with every NetApp storage system.

The high performance of the NetApp Snapshot makes it highly scalable. A NetApp Snapshot takes only a few seconds to create—typically less than one second, regardless of the size of the volume or the level of activity on the NetApp storage system. After a Snapshot copy has been created, changes to data objects are reflected in updates to the current version of the objects, as if Snapshot copies did not exist. Meanwhile, the Snapshot version of the data remains completely stable. A NetApp Snapshot incurs no performance overhead; users can comfortably store up to 255 Snapshot copies per WAFL volume, all of which are accessible as read-only and online versions of the data.

NetApp Snapshot does not require any additional license to create, but for restore its require to add the license
Snaprestore XXXXXX   <License you can see in NetApp console>
filer> license add XXXXXXX

To Create Snapshot for particular volume

filer> snap create –V bali snap2

To check list of snapshots on a particular volume

filer> snap list bali
Volume bali
working...

  %/used       %/total  date          name
----------  ----------  ------------  --------
  0% ( 0%)    0% ( 0%)  Jun 24 22:16  snap2
  1% ( 0%)    0% ( 0%)  Jun 24 21:37  test

To restore data from a particular volume, make sure that you have valid snaprestore license added
Example 1:

I have a file good.txt in bali volume, so we need to give the command as mentioned below, make sure that you should not give the same name of file which you would like to restore in the same dir/path otherwise it will be overwritten

filer> snap restore -s snap2 -r /vol/bali/good-restore.txt '/vol/bali/good.txt'
WARNING! This will restore a file from a snapshot into the active filesystem.  If the file already exists in the active filesystem, it will be overwritten with the contents from the snapshot.

Are you sure you want to do this? y

You have selected file /vol/bali/good.txt, snapshot test
It will be restored as /vol/bali/good-restore.txt
Proceed with restore? y
filer>

Example 2

If you know the filename which you would like to restore you can use below commands. For example if you have a file in qtree called good.txt, you need to fire the command like below

filer> snap restore -t file '/vol/bali/qtree/good.txt'

WARNING! This will restore a file from a snapshot into the active filesystem.  If the file already exists in the active filesystem, it will be overwritten with the contents from the snapshot.

Are you sure you want to do this? y

The following snapshots are available for volume bali:

date            name
------------    ---------
Jun 24 22:16    snap2
Jun 24 21:37    test
Which snapshot in volume bali would you like to revert the file from? snap2
You have selected file /vol/bala_test/qtree/good.txt, snapshot snap2
Proceed with restore? y
 Filer>

There are 2 commands which are in association with Snapshots, those are.

By default the snap reserve for a volume is 20%, but always you have options to change the value depends on your requirement

filer> snap reserve bali
Volume bali: current snapshot reserve is 20% or 2097152 k-bytes.
filer> snap reserve bali 10
Volume bali: current snapshot reserve is 10% or 1048576 k-bytes.

Note: - Reserving space depends on volume size, if you don't have enough space reserved for creating snapshots it will take space from volumes but if you don't have enough space to dump data on a volume it will not take space from snapshot (Concept).

Snapshot Schedule

filer> snap sched bali
Volume bali: 0 2 6@8,12,16,20
filer>
snap sched [-A | -V] [<vol-name> [weeks [days [hours[@<list>]]]]]

To be Continued...

No comments:

Post a Comment

Hello

Hello