Get-NimSnapshot

The Get-NimSnapshot cmdlet enables you to perform an application object based query for snapshots based on the volume name or a snapshot collection name.

Syntax Variants

-NimbleVolumeName option. The name of the volume as shown on the array for which snapshots should be queried. The volume name is case sensitive. The returned sort order is descending by snapshot creation time.

Get-NimSnapshot -NimbleVolumeName <String> [-GroupMgmtIP <IPAddress>] [-From <DateTime>] [-To <DateTime>] [-MaxObjects <UInt32>] [-AppObject <String>] [-Compare <String>] [-Application <String>] [-AppConsistentOnly [<SwitchParameter>]] [<CommonParameters>]

-NimbleVolume
option. Get snapshots for the specified NimbleVolume object returned by the Get-NimVolume cmdlet. This is a pipeline parameter, and the returned sort order is descending by creation time.

Get-NimSnapshot -NimbleVolume <NimbleVolume> [-From <DateTime>] [-To <DateTime>] [-MaxObjects <UInt32>] [-AppObject <String>] [-Compare <String>] [-Application <String>] [-AppConsistentOnly [<SwitchParameter>]] [<CommonParameters>]

-SnapshotCollectionName option. Gets snapshots for the specified snapshot collection name. The name is case sensitive, and the returned sort order is ascending by volume name.

Get-NimSnapshot -SnapshotCollectionName <String> [-GroupMgmtIP <IPAddress>] [<CommonParameters>]

-NimbleVolumeAccessPath option. Name of the Windows mount point on a volume that is exposed to the host for which snapshots should be queried.

Get-NimSnapshot -NimbleVolumeAccessPath <String> [-GroupMgmtIP <IPAddress>] [-From <DateTime>] [-To <DateTime>] [-MaxObjects <UInt32>] [-AppObject <String>] [-Compare <String>] [-Application <String>] [-AppConsistentOnly [<SwitchParameter>]] [<CommonParameters>]

NOTE:

The -AppConsistentOnly option is a switch parameter used to specify whether to include only application consistent snapshots. The default is to include both application consistent and crash consistent snapshots.

The behavior of the cmdlet with the -AppConsistentOnly option depends on how the -AppObject is specified:
  • When the -AppObject option is specified and -AppConsistentOnly is false, the cmdlet includes VSS snapshots taken by VSS requestor that are either in 'ns_app_consistent_objects_*' or 'ns_crash_consistent_objects_*'.
  • When the -AppObject option is specified and -AppConsistentOnly is true, the cmdlet includes VSS snapshots taken by VSS requestor that are only in 'ns_app_consistent_objects_*'.
  • When the -AppObject option is not specified and the -AppConsistentOnly option is false, the cmdlet includes VSS or crash consistent snapshots.
  • When the -AppObject option is not specified and the -AppConsistentOnly option is true, the cmdlet includes any VSS snapshots taken by the VSS requestor or a third-party VSS aware backup that uses the VSS hardware provider.

Get the latest snapshot for the named volume.

Example

PS C:\Users\Administrator> Get-NimSnapshot -NimbleVolumeName TestVolume-EXCH -MaxObjects 1    
GroupMgmtIP            : 10.18.236.77
Name                   : TestVolume-EXCH-Snap1
CreationTime           : 5/3/2016 3:02:26 PM
NimbleVolumeName       : TestVolume-EXCH
SnapshotCollectionName : Weekly
VSS                    : True
VerifiyBackup          : True
SkipDatabaseVerification : False
Application            : exch
AppConsistentObjects   : {[First Storage Group,Microsoft Exchange Server\Microsoft Information Store\Replica\CCR1-CMS\{CCC2763C-EFF0-4914-9F11-A205DD285F1F}], [Mailbox Database,...]]}
CrashConsistentObjects : {}

Get all snapshots for the named volume and show the application consistent objects.

Example

PS C:\Users\Administrator> -NimbleVolumeName TestVolume | Select-Object -ExpandProperty AppConsistentObjects
Name                     Identifier
-----                     ------------

First Storage Group      Microsoft Exchange Server\Microsoft Information Store\Replica\CCR1-CMS\{CCC2763C-EFF0-4914-9F11-A205DD285F1F}
Mailbox Database         Microsoft Exchange Server\Microsoft Information Store\Replica\MYEXCHSRVR\{DDDC2763C-EFF0-4914-9F11-A205DD285F1F}

Get the latest snapshot collection for an application object that matches the -AppObject option.

Example

PS C:\Users\Administrator> Get-NimSnapshotCollection -MaxObjects 1 -AppObject 'SQL14W16C7A5'
GroupMgmtIP          : 10.18.136.42
Name                 : sql2014C7A5Win2K16DBLOG-Schedule-new-2016-10-04::09:01:00.640
VolumeCollectionName : sql2014C7A5Win2K16DBLOG
CreationTime         : 10/4/2016 9:01:06 AM
Snapshots            : {sql2014C7A5Win2K16DBLOG-Schedule-new-2016-10-04::09:01:00.640, sql2014C7A5Win2K16DBLOG-Schedule-new-2016-10-04::09:01:00.640}

Get all connected volumes on the machine and pipe it with the Get-NimSnapshot cmdlet to get the five most recent snapshots. Display verbose information about the progress of the cmdlet.

Example

PC C:\Users\Administrator> Get-NimVolume | Get-NimSnapshot -Verbose -MaxObjects 5

Get all snapshots for the volume "UnitTestSnapVolume" with application or crash-consistent snapshots of -AppObject "LabVM" with -Application type "hyperv".

Example

PC C:\Users\Administrator> Get-NimSnapshot -NimbleVolumeName UnitTestSnapVolume -AppObject 'LabVM' -Application hyperv

Get all VSS snapshots of volume "UnitTestSnapVolume" that were taken over the last 30 days.

Example

PC C:\Users\Administrator> $ToDate=Get-Date;$FromDate=$ToDate.AddDays(-30); Get-NimSnapshot -NimbleVolumeName UnitTestSnapVolume -From $FromDate -To $ToDate -AppConsistentOnly

Get VSS snapshots for Windows mounted volume F:\.

Example

PC C:\Users\Administrator> Get-NimSnapshot -NimbleVolumeAccessPath F:\ -AppConsistentOnly