VMware Cloud Community
mightyvarun
Contributor
Contributor
Jump to solution

VM freezes as soon as datastore goes out of free disk space.

Hi All,

I`m looking for reason why VM goes in freeze state as soon as my datastore goes out of free disk space.

Any response would be appreciated.

Regards,

Varun Khatri

1 Solution

Accepted Solutions
grasshopper
Virtuoso
Virtuoso
Jump to solution

Hi ,

This is an amazing new feature that I really like.  Trust me it's good for you.  Historically, VMs that lived on datastores that ran out of space would simply BSoD in the case of Windows, and for Linux they would either kernel panic or the filesystem  would go read only.  This only happened to the VMs that tried to generate I/O (i.e. write to disk).  Previously, the time it took for them to crash was purely dependent on their tolerance for lack of Disk I/O (configurable in the Guest Operating System).  The problem is that the old method was very inconsistent and determining which VMs were actually affected was tough as not all VMs would crash hard.

This new enhancement is called "Thin Provision Stun" which is on by default when using VAAI with thin provisioned datastores (at least on NetApp and EMC gear).  It protects you from data corruption by suspending the VM.  Once you have cleared the free space or expanded the datastore, you simply answer the Guest Question with "Retry".  I typically set my datastores to autogrow to protect me from these situations, but sometimes it happens when a volume was not set properly to autogrow.

After the space has been cleared, to answer the question and get the VMs powered on quickly, PowerCLI does a great job.
Get-Datastore MyDatastore | Get-VM | Get-VMQuestion | Set-VMQuestion -Option "Retry"

EDIT:  Added the name of the VAAI primitive ("Thin Provision Stun") to encourage additional research

View solution in original post

8 Replies
schepp
Leadership
Leadership
Jump to solution

Hi welcome to the communities,

are you looking for a reason why the datastore runs out of space or why the VM freezes?

The VM is paused by the host to prevent it from crashing when the datastore is out of space.

Regards

Tim

0 Kudos
suresh1180
Enthusiast
Enthusiast
Jump to solution

Hello varun,

Vm freezes due to data store over provisioned.

Here is the scenario: Assume that you have a data store which is capacity of 1 TB and you have allocated 1.2 TB of thin provisioned space to a VM. In thin provisioning we can always provision more than what data store is having to save the storage cost. If the VM space utilization is below than what we have allocated it is well and good, if in case if the VM space\disk utilization reached to what we have allocated(1.2 TB in this scenario) it will freeze the VM due to less space in data store and required the additional space to perform its operations.

Recommendations: 1) Always provision the space with in the capacity, Do not over provision Data store...

                            2) Monitor over provisioned Datastores with Alarms by providing certain threshold values.

Hope i have answered your query..

0 Kudos
JarryG
Expert
Expert
Jump to solution

"...I`m looking for reason why VM goes in freeze state as soon as my datastore goes out of free disk space..."


I do not understand. You have the answer, so what more you want to hear? Where should your VM write if your datastore is full?

_____________________________________________ If you found my answer useful please do *not* mark it as "correct" or "helpful". It is hard to pretend being noob with all those points! 😉
0 Kudos
a_p_
Leadership
Leadership
Jump to solution

The main two reasons for such issues are:

  • you are using thin provisioned virtual disks
  • your VM has active snapshots

André

0 Kudos
grasshopper
Virtuoso
Virtuoso
Jump to solution

Hi ,

This is an amazing new feature that I really like.  Trust me it's good for you.  Historically, VMs that lived on datastores that ran out of space would simply BSoD in the case of Windows, and for Linux they would either kernel panic or the filesystem  would go read only.  This only happened to the VMs that tried to generate I/O (i.e. write to disk).  Previously, the time it took for them to crash was purely dependent on their tolerance for lack of Disk I/O (configurable in the Guest Operating System).  The problem is that the old method was very inconsistent and determining which VMs were actually affected was tough as not all VMs would crash hard.

This new enhancement is called "Thin Provision Stun" which is on by default when using VAAI with thin provisioned datastores (at least on NetApp and EMC gear).  It protects you from data corruption by suspending the VM.  Once you have cleared the free space or expanded the datastore, you simply answer the Guest Question with "Retry".  I typically set my datastores to autogrow to protect me from these situations, but sometimes it happens when a volume was not set properly to autogrow.

After the space has been cleared, to answer the question and get the VMs powered on quickly, PowerCLI does a great job.
Get-Datastore MyDatastore | Get-VM | Get-VMQuestion | Set-VMQuestion -Option "Retry"

EDIT:  Added the name of the VAAI primitive ("Thin Provision Stun") to encourage additional research

hsenzarzis
Contributor
Contributor
Jump to solution

check if the snapshot is active  if yes the vm need space to create snapshot file

try to merge snapshot to free the datastore

0 Kudos
mightyvarun
Contributor
Contributor
Jump to solution

Hi grasshopper

Thanks for your response...one more question to ask.

OS and DATA disks are allocated from separate datastores , If my DATA datastore goes out of space why VM goes in freeze state...Since I have no impact on my OS disk / datastore VM should not freeze.

Regards,

Varun Khatri

0 Kudos
JarryG
Expert
Expert
Jump to solution

If your VM have at least some vdisk on "DATA" datastore (need not be exactly system-disk, where OS is installed!), then they will freeze anyway...

_____________________________________________ If you found my answer useful please do *not* mark it as "correct" or "helpful". It is hard to pretend being noob with all those points! 😉
0 Kudos