Virtual Machine hangs during vMotion task
search cancel

Virtual Machine hangs during vMotion task

book

Article ID: 447422

calendar_today

Updated On:

Products

VMware vCenter Server

Issue/Introduction

  • A Virtual Machine (VM) becomes unresponsive or "hangs" during the final cutover phase of a vMotion.
  • The VM process (VMX) stops logging after attempting to close a disk.
  • VM log files (vmware.log) show the following as the final entries:

    vcpu-0 - Closing disk 'scsi<X>:<Y>'
    vcpu-0 - DISKLIB-CTK : Auto blocksize for size <Size> is <Value>.
    vcpu-0 - DISKLIB-CBT : Initializing ESX kernel change tracking for fid <ID>.
    vcpu-0 - DISKLIB-CBT : Successfuly created cbt node <Node>-cbt.
    vcpu-0 - DISKLIB-CBT : Opening cbt node /vmfs/devices/cbt/<Node>-cbt

Environment

VCF 9.x
vSphere 8.x

Cause

  • This issue occurs because Changed Block Tracking (CBT) was enabled while the VM was powered on, but the required "stun-unstun" cycle (triggered by a power cycle or snapshot operation) was never performed.
  • When CBT is enabled on a live VM, it enters a "pending" initialization state. The initialization—which involves retrieving all allocated blocks and creating tracking files—is automatically triggered the next time the disk is opened or closed.
  • During a vMotion cutover, the source host closes the disks to hand them over to the destination. If this triggers a pending CBT initialization, the process can take a significant amount of time, causing the VM to exceed vMotion switchover timeouts and hang.

Resolution

If you must enable CBT on a live VM, you must perform a snapshot cycle immediately afterward to force initialization:

  • Enable CBT on the VM.
  • Create a virtual machine snapshot.
  • Delete (consolidate) the snapshot.

Please refer: Enabling or disabling Changed Block Tracking (CBT) on virtual machines