There is a lot of confusion out there concerning VMware Snapshots. We would like to take few minutes to discuss some features and best practices for VMware Snapshots.
A snapshot is a record of all of the changes made to a virtual machine since the Snapshot was taken. Upon taking a snapshot, VMware / vSphere creates a new secondary virtual disk file which is subsequently dependent on the first primary virtual disk. Because in turn, the snapshot shows changes in relation relative to that the first virtual disk. In the absence of the initial virtual disk, the snapshot is rendered useless as it shows that changes were made, but not what was actually changed. Additional snapshots taken after the first snapshot work the same way. The first (or previous) snapshot stops recording changes, and the new snapshot begins recording changes.
Please keep in mind that “Snapshots are not backups” and should not be treated as such. Rather, snapshots should be used as a moment in time recovery point. A good example of practical times to create a Snapshot would be prior to installing updates, service packs or new software. Once you have tested and are satisfied with any new updates or software installations, it is recommended to remove the snapshot at that time.
Only keep snapshots for the shortest amount of time possible. As a rule of thumb ensure your snapshots are deleted at latest within 24 hours, if you have a requirement to keep them longer consider taking a backup instead.
If you have a very old snapshot consider either cloning the VM to a new VM (This will consolidate the snapshots and keep the original for fail back) or turning off the VM and removing the snapshot, this will mean there is no change happening to the delta while it is being consolidated. Larger (or older) snapshots will take longer to delete so don’t remove old snapshots during your servers busiest times.
If you need to recover individual files you need to run a file level backup product on the server (inside the OS). If you need to recover the full VM you need to run a backup solution that takes advantage of VMware Consolidated Backup.
Reverting to a snapshot incurs a loss of data. Any data that was written since the snapshot has occurred will no longer be available, along with any applications that were installed since the snapshot was taken. Therefore, revert to snapshots only if you have determined that the loss of data is acceptable or if the data is backed up elsewhere.
As you can see, snapshots are a great way to protect yourself against unwanted changes to the data stored in a VM. Snapshots aren’t backups and should not be used in place of backups. However, they can protect you against misbehaving application installations or other processes that might result in data loss or corruption.
Eddie Jones | Senior Systems Engineer | VCP 4.1 – MCSE – MCITP