Skip to content

Latest commit

 

History

History
187 lines (143 loc) · 4.67 KB

File metadata and controls

187 lines (143 loc) · 4.67 KB
external help file Module Name online version schema
Microsoft.Azure.Commands.RecoveryServices.SiteRecovery.dll-Help.xml
AzureRM.RecoveryServices.SiteRecovery
2.0.0

Get-AzureRmRecoveryServicesAsrJob

SYNOPSIS

Gets the details of the specified ASR job or the list of recent ASR jobs in the Recovery Services vault.

SYNTAX

ByParam (Default)

Get-AzureRmRecoveryServicesAsrJob [-StartTime <DateTime>] [-EndTime <DateTime>] [-TargetObjectId <String>]
 [-State <String>] [-DefaultProfile <IAzureContextContainer>] [<CommonParameters>]

ByName

Get-AzureRmRecoveryServicesAsrJob -Name <String> [-DefaultProfile <IAzureContextContainer>]
 [<CommonParameters>]

ByObject

Get-AzureRmRecoveryServicesAsrJob -Job <ASRJob> [-DefaultProfile <IAzureContextContainer>] [<CommonParameters>]

DESCRIPTION

The Get-AzureRmRecoveryServicesAsrJob cmdlet gets Azure Site Recovery jobs. You can use this cmdlet to view the ASR jobs in the Recovery Services vault.

EXAMPLES

Example 1

PS C:\> $jobs = Get-AzureRmRecoveryServicesAsrJob -TargetObjectId $ASRObjectId

Returns all the jobs on a particular ASR object(reference the ASR object such as replicated item or recovery plan by its ID.)

PARAMETERS

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with Azure.

Type: Microsoft.Azure.Commands.Common.Authentication.Abstractions.IAzureContextContainer
Parameter Sets: (All)
Aliases: AzureRmContext, AzureCredential

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-EndTime

Specifies the end time for the jobs. This cmdlet gets all jobs that started before the specified time. To obtain a DateTime object for this parameter, use the Get-Date cmdlet. For more information, type Get-Help Get-Date.

Type: System.Nullable`1[System.DateTime]
Parameter Sets: ByParam
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Job

Specifies the ASR job object to get updated details for.

Type: Microsoft.Azure.Commands.RecoveryServices.SiteRecovery.ASRJob
Parameter Sets: ByObject
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False

-Name

Specify the ASR job by name.

Type: System.String
Parameter Sets: ByName
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-StartTime

Specifies the start time for the jobs. This cmdlet gets all jobs that started after the specified time.

Type: System.Nullable`1[System.DateTime]
Parameter Sets: ByParam
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-State

Specifies the state for a ASR job. This cmdlet gets all jobs that match the specified state. The acceptable values for this parameter are:

  • NotStarted
  • InProgress
  • Succeeded
  • Other
  • Failed
  • Cancelled
  • Suspended
Type: System.String
Parameter Sets: ByParam
Aliases:
Accepted values: NotStarted, InProgress, Succeeded, Other, Failed, Cancelled, Suspended

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-TargetObjectId

Specifies the ID of the object. Used to search for jobs on the specified object.

Type: System.String
Parameter Sets: ByParam
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).

INPUTS

Microsoft.Azure.Commands.RecoveryServices.SiteRecovery.ASRJob

OUTPUTS

System.Collections.Generic.IEnumerable`1[[Microsoft.Azure.Commands.RecoveryServices.SiteRecovery.ASRJob, Microsoft.Azure.Commands.RecoveryServices.SiteRecovery, Version=4.0.0.0, Culture=neutral, PublicKeyToken=null]]

NOTES

RELATED LINKS

Restart-AzureRmRecoveryServicesAsrJob

Resume-AzureRmRecoveryServicesAsrJob

Stop-AzureRmRecoveryServicesAsrJob