Hello,
I am using the VSphere CLI to create a snapshot of the guest OS, and then using vmware-mount to mount the associated VMDK file. However the VSphere CLI asks me for a "Snapshot Name" to create the snapshot, while vmware-mount asks me for the VMDK path of the associated snapshot to identify it. If I am not using the WebServices API, how can I get the mapping between these two ? Is there a command that I can use here ?
I am aware the .vmsd file on the ESX server (after snapshot creation) contains this information. If there is no concrete solution to do this using CLI, is there a way I can read this file directly from the client ?
Thanks in advance,
Regards,
Gokul.
This information is easily available using the vSphere API to extract the snapshot delta file paths. You other option is build the path by logging into your ESX(i) host and searching for the delta files and plug it into the scripts you need to.
=========================================================================
William Lam
VMware vExpert 2009
VMware ESX/ESXi scripts and resources at:
VMware Code Central - Scripts/Sample code for Developers and Administrators
![]()
If you find this information useful, please award points for "correct" or "helpful".
Hello William,
I am not planning to use the WebServices API to get this information, as stated above. Is there any other way to get this information from a command or a perl-script embedded within any CLI.
Regards,
Gokul.
As mentioned, you either use the API or you manually login to the host and figure out the mapping by doing a search for the *-delta.vmdk files and you can do a mapping by looking at the .vmsn contents and map the VMDK disk. There's nothing out of the box that does this mapping for you, it'll be a custom script. Though I'm not sure why you would go down this route if it's easily accessible via the API in a much cleaner fashion and easier to automate.
=========================================================================
William Lam
VMware vExpert 2009
VMware ESX/ESXi scripts and resources at:
VMware Code Central - Scripts/Sample code for Developers and Administrators
![]()
If you find this information useful, please award points for "correct" or "helpful".
