

def snapshot(self, conf, no_metadata=False, disk_only=False, reuse_ext=False, quiesce=False):
    'Creates a guest snapshot.\n\n        :param conf: libvirt.LibvirtConfigGuestSnapshotDisk\n        :param no_metadata: Make snapshot without remembering it\n        :param disk_only: Disk snapshot, no system checkpoint\n        :param reuse_ext: Reuse any existing external files\n        :param quiesce: Use QGA to quiece all mounted file systems\n        '
    flags = (no_metadata and (libvirt.VIR_DOMAIN_SNAPSHOT_CREATE_NO_METADATA or 0))
    flags |= (disk_only and (libvirt.VIR_DOMAIN_SNAPSHOT_CREATE_DISK_ONLY or 0))
    flags |= (reuse_ext and (libvirt.VIR_DOMAIN_SNAPSHOT_CREATE_REUSE_EXT or 0))
    flags |= ((quiesce and libvirt.VIR_DOMAIN_SNAPSHOT_CREATE_QUIESCE) or 0)
    self._domain.snapshotCreateXML(conf.to_xml(), flags=flags)

dataset/ETHPy150Open BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/virt/libvirt/guest.py Guest.snapshot/original