Skip to content

How to manage snapshots of the VMs? #144

Open
@andrewscott0

Description

@andrewscott0

How do I do snapshot related operations on a VM? Say I want to capture snapshots or revert back to a snapshot, how can I do that? I've tried searching this on the
vsphere automation sdk for python docs but it doesn't seem to have any information related to this.

Thanks.

Activity

abessifi

abessifi commented on Sep 29, 2019

@abessifi

@tianhao64 any feedback on this please ?

rfalias

rfalias commented on Oct 23, 2019

@rfalias

Curious about this as well...
Surprising the automation sdk doesn't have snapshot capabilities. Is this a feature request or already in progress?

anusha94

anusha94 commented on Mar 16, 2021

@anusha94
Contributor

Can anybody confirm if this feature is still not available with the latest SDK? I can forward the request in that case.

KnutssonDevelopment

KnutssonDevelopment commented on Apr 22, 2021

@KnutssonDevelopment

I looks like it is a VM property, which makes sense. I am able to list them by the vm object anyway.

KnutssonDevelopment

KnutssonDevelopment commented on Apr 22, 2021

@KnutssonDevelopment
luponata

luponata commented on May 4, 2021

@luponata

I have posted some example code here: https://vm.knutsson.it/2021/04/get-snapshot-informatin-using-python/

Good to know!, unfortunately this is working only on a separate API implementation: "Pyvmomi"

I keep wondering why they haven't implemented the same snapshot concept with the newer REST API

Anyway it's however possible to know the presence of snapshots with the following code:

vsphere_client.vcenter.VM.get('vm-208100').to_dict()['disks'][0]['value']['backing']['vmdk_file']
--> '[Datastore-A] vm_name/vm_name_disk-000001.vmdk'

Unfortunately we cannot know the date and any descriptions of the snapshot, but it is a start

avesst

avesst commented on May 2, 2024

@avesst

This is still not implemented?

P-T-I

P-T-I commented on Apr 10, 2025

@P-T-I

Would like to know if this is getting implemented? @aagrawal3 any insights?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      How to manage snapshots of the VMs? · Issue #144 · vmware/vsphere-automation-sdk-python