Get-AzSnapshot
Obtém as propriedades de um instantâneo
Sintaxe
Get-AzSnapshot
[[-ResourceGroupName] <String>]
[[-SnapshotName] <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
O cmdlet Get-AzSnapshot obtém as propriedades de um instantâneo.
Exemplos
Exemplo 1
Get-AzSnapshot
ResourceGroupName : ResourceGroupName1
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName1/providers/Microsoft.Compu
te/snapshots/SnapshotName1
Name : SnapshotName1
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
ResourceGroupName : ResourceGroupName1
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName1/providers/Microsoft.Compu
te/snapshots/SnapshotName2
Name : SnapshotName2
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
ResourceGroupName : ResourceGroupName2
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName2/providers/Microsoft.Compu
te/snapshots/SnapshotName3
Name : SnapshotName3
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
Esse comando obtém as propriedades de todos os instantâneos da assinatura.
Exemplo 2
Get-AzSnapshot -ResourceGroupName "ResourceGroupName1"
ResourceGroupName : ResourceGroupName1
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName1/providers/Microsoft.Compu
te/snapshots/SnapshotName1
Name : SnapshotName1
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
ResourceGroupName : ResourceGroupName1
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName1/providers/Microsoft.Compu
te/snapshots/SnapshotName2
Name : SnapshotName2
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
Esse comando obtém as propriedades de todos os instantâneos no grupo de recursos chamado "ResourceGroupName1"
Exemplo 3
Get-AzSnapshot -ResourceGroupName "ResourceGroupName1" -SnapshotName "SnapshotName1"
ResourceGroupName : ResourceGroupName1
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName1/providers/Microsoft.Compu
te/snapshots/SnapshotName1
Name : SnapshotName1
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
Esse comando obtém as propriedades do instantâneo chamado "SnapshotName1" no grupo de recursos chamado "ResourceGroupName1"
Exemplo 4
Get-AzSnapshot -SnapshotName "SnapshotName*"
ResourceGroupName : ResourceGroupName1
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName1/providers/Microsoft.Compu
te/snapshots/SnapshotName1
Name : SnapshotName1
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
ResourceGroupName : ResourceGroupName1
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName1/providers/Microsoft.Compu
te/snapshots/SnapshotName2
Name : SnapshotName2
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
ResourceGroupName : ResourceGroupName2
ManagedBy :
Sku : Microsoft.Azure.Management.Compute.Models.SnapshotSku
TimeCreated : 4/10/2018 7:05:42 PM
OsType : Windows
CreationData : Microsoft.Azure.Management.Compute.Models.CreationData
DiskSizeGB : 127
EncryptionSettings :
ProvisioningState : Succeeded
Id : /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/ResourceGroupName2/providers/Microsoft.Compu
te/snapshots/SnapshotName3
Name : SnapshotName3
Type : Microsoft.Compute/snapshots
Location : westus2
Tags : {}
Este comando obtém todos os instantâneos que começam com "SnapshotName"
Parâmetros
-DefaultProfile
As credenciais, a conta, o locatário e a assinatura usados para comunicação com o Azure.
Tipo: | IAzureContextContainer |
Aliases: | AzContext, AzureRmContext, AzureCredential |
Cargo: | Named |
Valor padrão: | None |
Obrigatório: | False |
Aceitar a entrada de pipeline: | False |
Aceitar caracteres curinga: | False |
-ResourceGroupName
Especifica o nome de um grupo de recursos.
Tipo: | String |
Cargo: | 0 |
Valor padrão: | None |
Obrigatório: | False |
Aceitar a entrada de pipeline: | True |
Aceitar caracteres curinga: | True |
-SnapshotName
Especifica o nome de um instantâneo.
Tipo: | String |
Aliases: | Name |
Cargo: | 1 |
Valor padrão: | None |
Obrigatório: | False |
Aceitar a entrada de pipeline: | True |
Aceitar caracteres curinga: | True |
Entradas
Saídas
Azure PowerShell