次の方法で共有


Get-AzDataProtectionBackupVault

サブスクリプションに属するリソース コレクションを返します。

構文

Get-AzDataProtectionBackupVault
   [-SubscriptionId <String[]>]
   [-DefaultProfile <PSObject>]
   [<CommonParameters>]
Get-AzDataProtectionBackupVault
   [-SubscriptionId <String[]>]
   -ResourceGroupName <String>
   -VaultName <String>
   [-DefaultProfile <PSObject>]
   [<CommonParameters>]
Get-AzDataProtectionBackupVault
   [-SubscriptionId <String[]>]
   -ResourceGroupName <String>
   [-DefaultProfile <PSObject>]
   [<CommonParameters>]
Get-AzDataProtectionBackupVault
   -InputObject <IDataProtectionIdentity>
   [-DefaultProfile <PSObject>]
   [<CommonParameters>]

説明

サブスクリプションに属するリソース コレクションを返します。

例 1: 特定のサブスクリプション内のすべてのバックアップ コンテナーを取得する

Get-AzDataProtectionBackupVault

ETag IdentityPrincipalId                  IdentityTenantId                     IdentityType   Location      Name                          Type
---- -------------------                  ----------------                     ------------   --------      ----                          ----
     xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx SystemAssigned westus        adigupt-backupcenter-ga-Vault Microsoft.DataProtection/backupVault
     xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx SystemAssigned westcentralus BC-Usability-Vault-WCUS       Microsoft.DataProtection/backupVault
     xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx SystemAssigned centraluseuap NilayBackupVault              Microsoft.DataProtection/backupVault
     xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx SystemAssigned centraluseuap dpprunnervaultus              Microsoft.DataProtection/backupVault

このコマンドは、現在のサブスクリプション コンテキスト内のすべてのバックアップ コンテナーを取得します。 別のサブスクリプションのバックアップ コンテナーを取得する SubscriptionId パラメーターを指定します。

例 2: 特定のリソース グループ内のすべてのバックアップ コンテナーを取得します。

Get-AzDataProtectionBackupVault -SubscriptionId "xxxx-xxx-xxxx" -ResourceGroupName sarath-rg

ETag IdentityPrincipalId                  IdentityTenantId                     IdentityType   Location      Name            Type
---- -------------------                  ----------------                     ------------   --------      ----            ----
     xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx SystemAssigned centraluseuap sarath-dppvault Microsoft.DataProtection/backupVaults
     xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx SystemAssigned centraluseuap sarath-vault    Microsoft.DataProtection/backupVaults

このコマンドは、特定のリソース グループ内のすべてのバックアップ コンテナーを取得します。

例 3: 特定のコンテナーを取得します。

Get-AzDataProtectionBackupVault -SubscriptionId "xxxx-xxx-xxxx" -ResourceGroupName sarath-rg -VaultName sarath-vault

ETag IdentityPrincipalId                  IdentityTenantId                     IdentityType   Location      Name            Type
---- -------------------                  ----------------                     ------------   --------      ----            ----
     xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx SystemAssigned centraluseuap sarath-vault    Microsoft.DataProtection/backupVaults

このコマンドは、指定されたコンテナー名で特定のコンテナーを取得します。

例 4: バックアップ コンテナーのセキュリティ スコアを取得する。

$vault = Get-AzDataProtectionBackupVault -SubscriptionId "xxxx-xxx-xxxx" -ResourceGroupName hiaga-rg -VaultName hiaga-vault
$vault.SecureScore

Adequate

最初のコマンドは、指定されたコンテナー名で特定のコンテナーを取得し、次に、適切と表示されるコンテナーのセキュリティ スコアをフェッチします。

例 4: バックアップ コンテナーの暗号化設定を取得します。

$vault = Get-AzDataProtectionBackupVault -SubscriptionId "xxxx-xxx-xxxx" -ResourceGroupName "resourceGroupName" -VaultName "vaultName"
$vault.EncryptionSetting |fl
$vault.EncryptionSetting.CmkIdentity |fl
$vault.EncryptionSetting.CmkKeyVaultProperty |fl

CmkIdentity                 : Microsoft.Azure.PowerShell.Cmdlets.DataProtection.Models.Api20240401.CmkKekIdentity
CmkInfrastructureEncryption : Enabled
CmkKeyVaultProperty         : Microsoft.Azure.PowerShell.Cmdlets.DataProtection.Models.Api20240401.CmkKeyVaultProperties
State                       : Enabled

IdentityId   : /subscriptions/191973cd-9c54-41e0-ac19-25dd9a92d5a8/resourcegroups/jeevan-wrk-vms/providers/Microsoft.ManagedIdentity/userAssignedIdentities
               /userMSIpstest
IdentityType : UserAssigned

KeyUri : https://jeevantestkeyvaultcmk.vault.azure.net/keys/pstest/3cd5235ad6ac4c11b40a6f35444bcbe1

最初のコマンドは、指定されたコンテナー名で特定のコンテナーを取得し、その後の 3 つのコマンドで暗号化設定の仕様をフェッチします。

パラメーター

-DefaultProfile

DefaultProfile パラメーターは機能しません。 別のサブスクリプションに対してコマンドレットを実行する場合は、使用可能な場合は SubscriptionId パラメーターを使用します。

型:PSObject
Aliases:AzureRMContext, AzureCredential
配置:Named
規定値:None
必須:False
パイプライン入力を受け取る:False
ワイルドカード文字を受け取る:False

-InputObject

ID パラメーターを構築するには、INPUTOBJECT プロパティの NOTES セクションを参照し、ハッシュ テーブルを作成します。

型:IDataProtectionIdentity
配置:Named
規定値:None
必須:True
パイプライン入力を受け取る:True
ワイルドカード文字を受け取る:False

-ResourceGroupName

リソース グループの名前。 名前では大文字と小文字が区別されません。

型:String
配置:Named
規定値:None
必須:True
パイプライン入力を受け取る:False
ワイルドカード文字を受け取る:False

-SubscriptionId

ターゲット サブスクリプションの ID。 値は UUID である必要があります。

型:String[]
配置:Named
規定値:(Get-AzContext).Subscription.Id
必須:False
パイプライン入力を受け取る:False
ワイルドカード文字を受け取る:False

-VaultName

バックアップ コンテナーの名前。

型:String
配置:Named
規定値:None
必須:True
パイプライン入力を受け取る:False
ワイルドカード文字を受け取る:False

入力

IDataProtectionIdentity

出力

IBackupVaultResource