Book Image

Learning PowerCLI for VMware VSphere

By : Robert van den Nieuwendijk
Book Image

Learning PowerCLI for VMware VSphere

By: Robert van den Nieuwendijk

Overview of this book

Table of Contents (17 chapters)
Learning PowerCLI
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Using snapshots


Snapshots are a point-in-time to which you can revert a virtual machine when changes made to the virtual machine after creating the snapshot should be discarded. For example, snapshots are useful when you are installing or upgrading software in a virtual machine. If the installation or upgrade goes wrong, you can easily restore to the time the last snapshot was taken, in order to get back to the state before you started the installation or upgrade. If you have verified that the installation or upgrade was successful, you should remove the snapshot, because snapshots use valuable space on your datastores and decrease the performance of your virtual machine.

Note

Snapshots are not backups!

In this section, we will discuss the PowerCLI commands to work with snapshots.

Creating snapshots

To create a new snapshot of a virtual machine, you have to use the New-Snapshot cmdlet. This cmdlet has the following syntax:

New-Snapshot [-VM] <VirtualMachine[]> [-Name] <String> [-Description...