Creating Snapshot on virtual machine fails with error “A specified parameter was not correct: spec.deviceChange.device”
search cancel

Creating Snapshot on virtual machine fails with error “A specified parameter was not correct: spec.deviceChange.device”

book

Article ID: 385684

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

This article speaks about the error “spec.deviceChange.device” received when attempting to create snapshot on a virtual machine with “monolithicFlat” disk type.

  • The vmware.log for the virtual machine calls out the following error message:

/vmfs/volumes/<datastore_id>/<vm_name>/vmware.log

YYYY-MM-DDThh:mm:ss.718Z In(05) vcpu-0 lzh5v6zv-1649763-auto-zcys-h5:70402445-62-f1-50c5 DiskLib_IsVMFSSparseSupported: vmfssparse is not supported on /vmfs/volumes/datastore/vm_name: f532.
YYYY-MM-DDThh:mm:ss.718Z In(05) vcpu-0 lzh5v6zv-1649763-auto-zcys-h5:70402445-62-f1-50c5 DISKLIB-LIB_CREATE : DiskLibAdjustDataDiskCreateType: Overriding create type of child disk "vmfsSparse" from /vmfs/volumes/datastore/vm_name/vm_diskName-00000X.vmdk to SESPARSE because the filesystem does not support VMFSSPARSE.
YYYY-MM-DDThh:mm:ss.718Z In(05) vcpu-0 lzh5v6zv-1649763-auto-zcys-h5:70402445-62-f1-50c5 DISKLIB-LIB_CREATE : seSparse cannot be a child of monolithicFlat
YYYY-MM-DDThh:mm:ss.718Z In(05) vcpu-0 lzh5v6zv-1649763-auto-zcys-h5:70402445-62-f1-50c5 DISKLIB-LIB_CREATE : Failed to create link: One of the parameters supplied is invalid (1)
YYYY-MM-DDThh:mm:ss.718Z Er(02) vcpu-0 lzh5v6zv-1649763-auto-zcys-h5:70402445-62-f1-50c5 DISKLIB-LIB_CREATE : DiskLib_CreateChild: failed to create child disk: One of the parameters supplied is invalid (1)

  • The vmdk disks present inside the vm directory would contain “monolithicFlat” entry as shown below:

/vmfs/volumes/<datastore_id>/<vm_name>/

Environment

VMware ESXi 6.x, 7.x and 8.x

Cause

As stated on the aforementioned log snippet, snapshots on monolithicFlat disk are not permitted, they are only permitted for VMFS datatype disk.

Resolution

To resolve this issue, convert the VMDK disk from a monolithic type to a VMFS type. This can be done by cloning the disk using the vmkfstools by following below steps:

  • Power down the vm
  • Use the below command to clone the disk for concerned vm:

vmkfstools -i /vmfs/volumes/<Datastore>/<VM_name>/<VM_diskname>.vmdk /vmfs/volumes/<Datastore>/<VM_name>/<VM_newdiskname>.vmdk

  • Go to the location for the newly cloned vmdk and verify that no longer has “monolithicFlat” entry.
  • Unmount the old hard disk from the "Edit Settings" of the vm:
    • Right-click the virtual machine and click Edit Settings.
    • Select the Hard disk you wish to remove.
    • An X icon will appear on the right side of the selected line (DO NOT select Remove files option).
    • Click on the X icon to remove the disk and Press OK.
  • Mount the newly cloned vmdk:
    • Right-click the virtual machine and click Edit Settings.
    • On the Virtual Hardware tab, click the Add New Device button and select Existing Hard disk.
    • In the Select File, goto the desired location for the cloned vmdk, select the disk to add and click OK.
    • Click OK to save.
  • Power on the vm and proceed to take snapshot

If there are multiple monolithic disks, repeat the same steps for all of them.