VMware Solutions Discussions

VMWARE and Thin Provisioned LUNs

BSTEWARTDFS
8,878 Views

We are using VMWARE ESXi with a NetApp Filer. We have created Thin Provisioned LUNs on the NetApp and presented to VMWARE. I Storage vMotioned 10 Thick Provisioned VMs on the NetApp Storage and enabled DeDup. We decided we did not need the 10 VMs anymore and deleted from VMWARE and the Disk. In the NetApp Virtual Storage Console the LUN Usage is at 70%, but the Datastore Usage is 0%. Is there a way to reclaim the LUN space?

7 REPLIES 7

ROGERBERGLING
8,875 Views

http://partners.netapp.com/go/techontap/matl/space_reclamation.html

Or :

Space reclamation may be particularly useful in any environment that shows a large variance in the amount of data used. Systems used for queuing print jobs, e–mail, or standard file sharing are excellent candidates for space reclamation on a periodic schedule. Any system that has gone through a major change is also a good candidate for space reclamation. If you've performed  database reorganization or made significant changes to a database because of archiving, space reclamation will likely recover a significant amount of data.

Getting Started with Space Reclamation

NetApp space reclamation technology has been integrated into NetApp SnapDrive® for Windows 5.0 and comes at no additional cost. SnapDrive makes it easy for Windows server administrators to manage NetApp SAN storage using either a wizard–based approach or through a command–line interface (SDCLI) that can be used in conjunction with management scripts and scheduling programs.

Using the SnapDrive GUI or SDCLI, you can periodically initiate the space reclamation process on your LUNs. The GUI tool will first determine how much space can be reclaimed and ask if you wish to continue. You can limit the amount of time the process will use to ensure that it does not run during peak periods.

Here are a few things to keep in mind when you run space reclamation:

  • It's a good practice to run space reclamation before creating a Snapshot copy. Otherwise blocks that should be available for freeing will be locked in the Snapshot and not able to be freed.
  • Because space reclamation initially consumes cycles on the host, it should be run during periods of low activity.
  • Normal data traffic to the LUN can continue while the process runs. However, certain operations cannot be performed during the space reclamation process:
    • Creating or restoring a Snapshot copy stops space reclamation.
    • The LUN may not be deleted, disconnected, or expanded.
    • The mount point cannot be changed.
    • We don't recommend running Windows defragmentation.

BSTEWARTDFS
8,875 Views

I forgot to mention that these are not NFS LUNs they are FC LUNs. I see in the article it mentions NTFS, but is there a command to run on the Filer to reclaim the space?

mathieu_dewavrin
8,876 Views

Which version of ESXi and Ontap are you running ?

VAAI APIs are the way to go for space reclamation at the datatore level.

To be more there was the support for UNMAP in ESXi 5.0 but it has been dropped due to performances issues. You also

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2007427

It has been reintroduced in a patched version as a manuel process

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2014849

Given that you're datastore is empty you could remove the datastore from VMware then the LUN following this procedure

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2004605

Then you recreate a new LUN using the VSC

Of course everything is related to you having ESXi 5.0 with latest patchs and Ontap 8.0.1+

Or you could you NFS

BSTEWARTDFS
8,875 Views

We are running ESXi 4.1 and running ONTAP 8.0.2P6.

BSTEWARTDFS
8,875 Views

I know that I could completely delete the LUN and re-add, but I am concerned when we start deleting individual VMs and reclaiming the space.

keitha
8,875 Views

Unfortunately no, not until the VAAI for Space Reclamation is used and you are up to the required vSphere and DOT versions. However, all is not lost. Although the LUN usage in NetApp shows high (as far as we know the VMs are still there!) you will see the free space in the Datastore so you can place more VMs in the datastore.

With Dedupe, reclaiming the space should be less critical since each VM may not free up that much unique space but it will be nice when the VAAI option is available.

Keith

radek_kubka
8,875 Views

VAAI option depends on SCSI UNMAP function - VMware  disabled it by default in ESXi 5.0 Patch 2.

In ESXi 5.0 U1 VMware brings it back, but advises to run space reclamation as a manual process during maintenance window:

http://blogs.vmware.com/vsphere/2012/03/vaai-thin-provisioning-block-reclaimunmap-is-back-in-50u1.html

Regards,

Radek

Public