Get-​Azure​Rm​Backup​Container

Gets Backup containers.

Syntax

Get-AzureRmBackupContainer
   [-Vault] <AzureRMBackupVault>
   [-ManagedResourceGroupName <String>]
   [-Name <String>]
   [-Status <AzureBackupContainerRegistrationStatus>]
   -Type <AzureBackupContainerType>
   [<CommonParameters>]

Description

The Get-AzureRmBackupContainer cmdlet gets Azure Backup containers.

An AzureBackupContainer encapsulates data sources, protected items, and recovery points. An AzureBackupContainer can be one of the following:

  • A Windows Server computer
  • A System Center Data Protection Manager (SCDPM) server
  • An Azure infrastructure as a service (IaaS) virtual machine

Before Backup can back up a data source or item, you must register the container that holds it with the Azure Backup service. The container must be authenticated to send backup data to the Backup vault. For Windows Server computers and SCDPM servers, the registration is held with the fully qualified domain name of the server.

Examples

Example 1: View all servers registered to a vault

PS C:\>$Vault = Get-AzureRmBackupVault -Name "Vault03"
PS C:\> Get-AzureRmBackupContainer -Vault $Vault -Type Windows
Name                         Type               Status
----                         ----               ------
SERVER01.CONTOSO.COM          Windows            Registered
SERVER02.CONTOSO.COM          Windows            Registered

The first command gets the vault named Vault03 by using the Get-AzureRmBackupVault cmdlet. The command stores that object in the $Vault variable.

The second command gets all containers of type Windows from the vault in $Vault.

Example 2: Get a specific container

PS C:\>Get-AzureRmBackupContainer -Vault $Vault -Type SCDPM -Name "DPMSERVER.CONTOSO.COM"
Name                         Type               Status
----                         ----               ------
DPMSERVER.CONTOSO.COM        SCDPM              Registered

This command gets the container named DPMSERVER.CONTOSO.COM. The command specifies the vault in $Vault and the type of container.

Example 3: View all registered Azure virtual machines

PS C:\>Get-AzureRmBackupContainer -Vault $Vault -Type AzureVM -Status Registered 
Name                         Type               Status
----                         ----               ------
co03-vm                      AzureVM            Registered

This command gets the registered virtual machines from the vault in $Vault.

Required Parameters

-Type

Specifies the type of containers that this cmdlet gets.

Type:AzureBackupContainerType
Parameter Sets:Windows, SCDPM, AzureVM, AzureBackupServer, Other
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Vault

Specifies a Backup vault from which this cmdlet gets containers. To obtain an AzureRmBackupVault, use the Get-AzureRmBackupVault cmdlet.

Type:AzureRMBackupVault
Position:0
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Optional Parameters

-ManagedResourceGroupName

Specifies the name of the resource group associated with the container. This name is the same value that you specified for the ServiceName or ResourceGroupName parameter of the Register-AzureRmBackupContainer cmdlet.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Name

Specifies the name of the container that this cmdlet gets.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Status

Specifies the current status of the containers that this cmdlet gets. The acceptable values for this parameter are:

  • NotRegistered
  • Registered
  • Registering
Type:AzureBackupContainerRegistrationStatus
Parameter Sets:Registered, Registering, NotRegistered
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Inputs

AzureBackupVault

Outputs

AzureBackupContainer

Notes

  • None