2

If I create a snapshot with: 'vim-cmd vmsvc/snapshot.create' I can then transfer the file that creates to another system, or even to another vmware ESXi system.

Setting aside the fact that snapshots are not the best backup practice, how viable is this snapshot ? Is it, indeed, a snapshot of the entire system that I can then run on a different ESXi system (or on the same one, if I pull it from backup storage) ?

Let's assume that my command has a "1" at the end, which tells vim-cmd to quiesce the VM first before snapshotting...

2 Answers 2

3

It will be pretty useless and you won't be able to transport a snapshot to another system for use. They depend entirely on the original VMDK's.

Again, this isn't the purpose of VMware snapshots. They're really meant to be temporary and have major implications for storage performance and disk space.

2
  • Thank you. So if I take the VMDK by itself, that's a functional backup (regardless of how good or bad that practice may be) ?
    – user227963
    Jul 2, 2014 at 0:30
  • I probably wouldn't do that... but yeah, a VMDK is 98% of the virtual machine. There is also the virtual machine's configuration file... (.vmx)
    – ewwhite
    Jul 2, 2014 at 1:01
1

Snapshotting a VM means that the original VMDKs are fixed, all changes will go to a diff file. So you would have to copy the VMDK files themselves. (As far as I know there are two: A vmdk file describing the virtual disk and a "flat" file containing the data.)

However, I would consider this a pretty crude and unprofessional way to do backups of VMs. It might be OK for test or development VMs, but not for VMs that host production workloads.

Did you have a look at VDP? I think it comes with vSphere... it's a bit limited but maybe it's good enough for you.

edit: Similar question: Why don't people just use rsync to back up vmware guests?

7
  • VDP is included with the vSphere Essentials Plus suite. It's actually EMC Avamar, integrated into the vSphere Web Client interface.
    – ewwhite
    Jul 2, 2014 at 21:22
  • If you properly back up both the VMDK and the .vmx config file ... and later, possibly back up one or more snapshots you create with vim-cmd ... what else is there ? What would make it more professional ?
    – user227963
    Jul 3, 2014 at 15:20
  • @user227963 I don't think you should back up the diff as it "lives" and changes. So you would take a snapshot and back up the whole VMDK, not just the changes. Try to do this on a daily basis (not uncommon) with hundreds of VMs. It just doesn't scale. From a professional solution I expect support for searchvmware.techtarget.com/definition/… Integration into vCenter and the ability to recover single files easily would help, too. More answers: serverfault.com/questions/607962/…
    – Mario Lenz
    Jul 3, 2014 at 19:11
  • Is the CBT an actual file that you can see in the service console environment ? Or is it something you can only query via the API ?
    – user227963
    Jul 3, 2014 at 22:30
  • I don't know how or where the information which blocks changed is stored. But it's available via the API: "The CBT feature can be accessed by third-party applications as part of the vSphere APIs for Data Protection (VADP). Applications call VADP to request that the VMkernel return blocks of data that have changed on a virtual disk since the last backup snapshot." kb.vmware.com/kb/1020128
    – Mario Lenz
    Jul 4, 2014 at 17:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .