Get-AzMigrateJob
Retrieves the status of an Azure Migrate job.
Syntax
ListByName (Default)
Get-AzMigrateJob
-ResourceGroupName <String>
-ProjectName <String>
[-SubscriptionId <String>]
[-Filter <String>]
[-DefaultProfile <PSObject>]
[<CommonParameters>]
GetByName
Get-AzMigrateJob
-ResourceGroupName <String>
-ProjectName <String>
-JobName <String>
[-SubscriptionId <String>]
[-DefaultProfile <PSObject>]
[<CommonParameters>]
GetById
Get-AzMigrateJob
-JobID <String>
[-SubscriptionId <String>]
[-DefaultProfile <PSObject>]
[<CommonParameters>]
Get-AzMigrateJob
-InputObject <IJob>
[-SubscriptionId <String>]
[-DefaultProfile <PSObject>]
[<CommonParameters>]
ListById
Get-AzMigrateJob
-ResourceGroupID <String>
-ProjectID <String>
[-SubscriptionId <String>]
[-Filter <String>]
[-DefaultProfile <PSObject>]
[<CommonParameters>]
Description
The Get-AzMigrateJob cmdlet retrieves the status of an Azure Migrate job.
Examples
Example 1: Get By Job Id
Get-AzMigrateJob -JobID "/Subscriptions/xxx-xxx-xxx/resourceGroups/azmigratepwshtestasr13072020/providers/Microsoft.RecoveryServices/vaults/AzMigrateTestProjectPWSH02aarsvault/replicationJobs/997e2a92-5afe-49c7-a81a-89660aec9b7b"
ActivityId : 68af14b4-46ae-48d1-b3e9-cdcffb9e8a93 ActivityId: 74d1a396-1d37-4264-8a5b-b727aaef0171
AllowedAction : {}
CustomDetailAffectedObjectDetail : Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.JobDetailsAffectedObjectDetails
CustomDetailInstanceType : AsrJobDetails
EndTime : 9/16/20 11:57:33 AM
Error : {}
FriendlyName : Associate replication policy
Id : /Subscriptions/xxx-xxx-xxx/resourceGroups/azmigratepwshtestasr13072020/providers/Microsoft.Recover
yServices/vaults/AzMigrateTestProjectPWSH02aarsvault/replicationJobs/997e2a92-5afe-49c7-a81a-89660aec9b7b
Location :
Name : 997e2a92-5afe-49c7-a81a-89660aec9b7b
ScenarioName : AssociateProtectionProfile
StartTime : 9/16/20 11:57:32 AM
State : Succeeded
StateDescription : Completed
TargetInstanceType : ProtectionProfile
TargetObjectId : 42752b89-5fad-52fd-bf93-679fbdb6fed9
TargetObjectName : migrateAzMigratePWSHTc8d1sitepolicy
Task : {CloudPairingPrerequisitesCheck, CloudPairingPrepareSite}
Type : Microsoft.RecoveryServices/vaults/replicationJobs
This retrieves a job by it's Id.
Example 2: List by resource group and project
Get-AzMigrateJob -ResourceGroupName 'azmigratepwshtestasr13072020' -ProjectName 'AzMigrateTestProjectPWSH'
ActivityId :
AllowedAction : {}
CustomDetailAffectedObjectDetail : Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.JobDetailsAffectedObjectDetails
CustomDetailInstanceType :
EndTime : 9/21/20 4:13:40 PM
Error : {}
FriendlyName : Update the virtual machine
Id : /Subscriptions/xxx-xxx-xxx/resourceGroups/azmigratepwshtestasr13072020/providers/Microsoft.Recover
yServices/vaults/AzMigrateTestProjectPWSH02aarsvault/replicationJobs/1c89e38e-34ec-4903-aa7c-115201bf2de1
Location :
Name : 1c89e38e-34ec-4903-aa7c-115201bf2de1
ScenarioName : UpdateVmProperties
StartTime : 9/21/20 4:13:34 PM
State : Succeeded
StateDescription : Completed
TargetInstanceType : ProtectionEntity
TargetObjectId : 593b735d-2a34-53b2-b8ed-e33da5650703
TargetObjectName : rb-w2k12r2-1
Task : {}
Type : Microsoft.RecoveryServices/vaults/replicationJobs
This gets all jobs in a project.
Example 3: Get by resource group, project and job name
Get-AzMigrateJob -ResourceGroupName 'azmigratepwshtestasr13072020' -ProjectName 'AzMigrateTestProjectPWSH' -JobName 7ae1ee7c-442c-499d-8b0e-81d52a42b71e
ActivityId : 6986b7e5-0f1f-49d8-8b4b-77e6f66bcb92 ActivityId: eb73c6a1-7c66-469f-a853-d896aa38cc0f
AllowedAction : {}
CustomDetailAffectedObjectDetail : Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.JobDetailsAffectedObjectDetails
CustomDetailInstanceType : AsrJobDetails
EndTime : 8/21/20 6:41:48 AM
Error : {}
FriendlyName : Create replication policy
Id : /Subscriptions/xxx-xxx-xxx/resourceGroups/azmigratepwshtestasr13072020/providers/Microsoft.Recover
yServices/vaults/AzMigrateTestProjectPWSH02aarsvault/replicationJobs/7ae1ee7c-442c-499d-8b0e-81d52a42b71e
Location :
Name : 7ae1ee7c-442c-499d-8b0e-81d52a42b71e
ScenarioName : AddProtectionProfile
StartTime : 8/21/20 6:41:48 AM
State : Succeeded
StateDescription : Completed
TargetInstanceType : ProtectionProfile
TargetObjectId : 18b2ccec-e39a-517b-ae5d-dd395e9f4f96
TargetObjectName : samplePolicy3
Task : {AddProtectionProfilePreflightsCheckTask, AddProtectionProfileTask}
Type : Microsoft.RecoveryServices/vaults/replicationJobs
This gets a specific job.
Parameters
-DefaultProfile
The credentials, account, tenant, and subscription used for communication with Azure.
Parameter properties
Type: PSObject
Default value: None
Supports wildcards: False
DontShow: False
Aliases: AzureRMContext, AzureCredential
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-Filter
OData filter options.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
ListByName
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
ListById
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
Specifies the job object of the replicating server.
To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
Type: Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20250801.IJob
Default value: None
Supports wildcards: False
DontShow: False
GetByInputObject
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-JobID
Specifies the job id for which the details needs to be retrieved.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
GetById
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-JobName
Job identifier
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
GetByName
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ProjectID
Specifies the Azure Migrate Project in which servers are replicating.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
ListById
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ProjectName
The name of the migrate project.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
ListByName
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
GetByName
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ResourceGroupID
Specifies the Resource Group of the Azure Migrate Project in the current subscription.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
ListById
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ResourceGroupName
The name of the resource group where the recovery services vault is present.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
ListByName
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
GetByName
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-SubscriptionId
Azure Subscription ID.
Parameter properties
Type: String
Default value: (Get-AzContext).Subscription.Id
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters .
Outputs
Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20250801.IJob