PowerShell Script to Take Snapshot on Multiple VM Machines
In my previous Blog, I introduced some basics about VMWare Infrastructure Toolkit. Now let's put it into action!
Let's say you have a test MOSS or SMS virtual environment, you have a couple of servers and you configured everything and test everything. Before you make the next big change, you may want to take a snapshot of your machines so you can have some to fall back on if something goes bad!
It couldn't easier with VI Toolkit!
$Now = Get-Date
#get all your moss servers
$VMs = get-vm |where{$_.name -like "xyzmoss*"}
foreach ($vm in $VMs)
#Take snapshots for each VM Box
{new-snapshot -vm $vm -name $Now -confirm}