Deleting a virtual machine snapshot times out. How do I resolve this?

ZSvirt was open-sourced from the ZStack ZSphere commercial project and has since developed independently. Some code, configuration, and documentation still retain historical ZStack/ZSphere names (such as environment variables, configuration items, dependencies, paths, and commands). These names are for compatibility only and do not affect the normal use of ZSvirt.

Cause

The default timeout for deleting a Snapshot is three hours. A large snapshot size causes the operation to time out.

Solution

  1. Connect to the Management Node via SSH.

  2. Run the following commands to extend the timeout to 24 hours:

    [root@localhost ~]# zstack-cli
    admin >>> LogInByAccount accountName=admin password=$password  //platform admin user password
    admin >>> UpdateGlobalConfig name=org.zstack.header.storage.snapshot.APIBatchDeleteVolumeSnapshotMsg category=apiTimeout value=24h
    admin >>> UpdateGlobalConfig name=org.zstack.header.storage.snapshot.APIDeleteVolumeSnapshotMsg category=apiTimeout value=24h
  3. Retry the snapshot deletion.

On this page