

Copy the virtual disk cp /vmfs/volumes/datastore/web01/web01-delta.vmdk /vmfs/volumes/nfs/web01-backup/web01-delta.vmdk.Vim-cmd vmsvc/snapshot.create 2 backup poor-mans-backup 0 0 Create a Snapshot with the vSphere Client or by command line (locate vmid with "vim-cmd vmsvc/getallvms" and make a snapshot with "vim-cmd vmsvc/snapshot.create ") vim-cmd vmsvc/getallvms.

cp /vmfs/volumes/datastore/web01/web01.vmx /vmfs/volumes/nfs/web01-backup/web01.vmxĬp /vmfs/volumes/datastore/web01/web01.nvram /vmfs/volumes/nfs/web01-backup/web01.nvramĬp /vmfs/volumes/datastore/web01/web01.vmsd /vmfs/volumes/nfs/web01-backup/web01.vmsdĬp /vmfs/volumes/datastore/web01/web01.vmdk /vmfs/volumes/nfs/web01-backup/web01.vmdk I'm copying all files to a nfs share mounted as datastore. The ".vmdk" is only the virtual disk descriptor file, so it's possible to make a copy. Here is the full process of making working backups of running Virtual Machines: The answer to the problem is: Create a snapshot, copy the virtual disk, delete the snapshot. To allow the virtual machine to work while the disk is in read only mode, all write IOs are stored in another file known as "Delta File". When you create a snapshot, the original virtual disk file is transformed into readonly mode. A common misinterpretation is that when you create a snapshot the system copies the defined state to another location. Here comes another technology in place: Snapshots. A snapshot is a preserved state of the virtual machine where you can return to later. The challenge is to make the disk readonly while the Virtual Machine is running, without affecting the operating system running in the Virtual Machine. "cp: can't open 'web01-flat.vmdk': Device or resource busy" But wait - Can you just copy a running Virtual Machine? No! You can't copy the Virtual Disk file while it is mapped to the Virtual Machine mode: This method works not only with the ESXi Hypervisor, but also with VMware Workstation or older products like GSX or VMware Server. Many years ago, this was my first method of creating backups of running Virtual Machines. The most unsophisticated backup method would be to simply make a copy of all files. The post explains the technique to create backups and takes a look at solution that use these techniques.Īll Virtual Machines are just files on datastores.

The API limitation makes it impossible to create incremental CBT aided backups, but it's not impossible to create full copies of virtual machines. VADP to make Backups.Ĭreating backups of Virtual Machines is also important on standalone ESXi hosts. Another limitation is that APIs are read-only, so it's not possible to use the Data Protection API aka. VMware offers a free version of their vSphere Hypervisor with some limitations like the lack of vCenter support.
