Snapshot Consolidation Fails with "File too large" Error
search cancel

Snapshot Consolidation Fails with "File too large" Error

book

Article ID: 398339

calendar_today

Updated On:

Products

VMware vSphere ESXi VMware vCenter Server

Issue/Introduction

Symptoms:

  • When attempting to consolidate snapshots on a virtual machine, the following error is observed in the vSphere Client:
    "An error occurred while consolidating disks: File too large."

  • At times, the consolidation task may not give any errors in the vSphere Client, but on validating the VM's disk from Edit Settings - it can be seen that there are snapshots attached to the VM.

Environment

VMware vSphere 7.x

VMware vSphere 8.x

 

Cause

  • This issue occurs due to insufficient free space on the datastore hosting the virtual machine's disk files.

  • To successfully consolidate snapshots, the available free space must be at least 1.5 times the total size of all snapshot files (.vmdk) for the virtual machine. If this requirement is not met, consolidation will fail with errors such as “File too large.”

  • From the ESXi host on which the VM resides, it can be seen that the consolidation fails due to lack of space: From the /var/run/log/hostd.log:
    hostd.log: DiskLib_IsCombinePossible: Could not get free space on disk using /vmfs/volumes/...
    hostd.log: Consolidate Disks message: An error occurred while consolidating disks: File too large.
    hostd.log: Event 33746 : Virtual machine ##### disks consolidation failed on ##### in cluster ##### in ha-datacenter.

  • Similarly, from the VM's vmware.log it can be seen that the snapshot consolidation completes without consolidating due to insufficient space:
    YYYY-MM-DDThh:mm:ss In(05) vcpu-0 #######-#####-auto-####-h5:###########-a1-7c-cf91 ConsolidateEnd: Snapshot consolidate complete: There is not enough space on the file system for the selected operation (5).

Resolution

To resolve this issue, perform the following steps:

  1. Calculate the Required Free Space:

  2. Free Up Datastore Space:

    • Remove or relocate unused files.

    • Migrate other VMs to different datastores.

    • Extend the datastore, if possible.

  3. Retry Snapshot Consolidation:

    • Once sufficient space is available, right-click the virtual machine and select Snapshot > Consolidate.

  4. Monitor for Completion:

    • Monitor the task in vSphere Client to ensure successful completion.

 

If enough space is not available in the current datastore and the datastore free space cannot be increased:

  1. VM's vmdk can be migrated to consolidate.

    1. Power OFF the VM.

      (During powered ON snapshot consolidation, a temporary snapshot is created to hold the active changes. This can increase in size if the snapshot consolidation task takes long. So if the VM is powered OFF, this file will not grow in size to fill up the datastore.)

    2. Migrate the disk with snapshot to another datastore to consolidate.

  2. Clone the VM to another datastore:

    1. Power OFF the VM.

    2. Clone the VM to another datastore.

Additional Information

In order to avoid situations like this, it is crucial to monitor for snapshots in the environment and delete them as soon as possible. Best practices for using VMware snapshots in the vSphere environment.