Hello!
How can i get "snapshotid" parameter of an snapshot, to use it in “remove-snapshot” cmdlet?
The Latest Gartner® Magic Quadrant™Hyperconverged Infrastructure Software
Moderators: anton (staff), art (staff), Max (staff), Anatoly (staff)
Code: Select all
foreach($device in $server.Devices)
{
if ( $device.name -eq $deviceName)
{
if ( $device.IsSnapshotsSupported )
{
foreach($snapshot in $device.Snapshots)
{
Write-Host "Snapshot Id: $($snapshot.Id) Name: $($snapshot.name) Date: $($snapshot.Date)"
}
}
break;
}
}