Collect and consolidating VM name from Azure Site Recovery Plans RRS feed

  • General discussion

  • Hi,

    I would like to develop a PowerShell script to collect VM names from each recovery plan and consolidate, which are all added into Azure Site Recovery Plan.

    I tried available commands(Get-AzRecoveryServicesAsrFabric, Get-AzRecoveryServicesAsrProtectableItem, Get-AzRecoveryServicesAsrProtectionContainer, Get-AzRecoveryServicesAsrRecoveryPlan, Get-AzRecoveryServicesAsrReplicationProtectedItem, Get-AzRecoveryServicesAsrServicesProvider) in Azure Az module which are all related one each another to get details.

    But I am not able to get correct details, and as it seems not straight forward method like Get-AzVM like.


    Could you please any one share the step by step procedure or suggestion to get the Protected VM’s in each Recovery plan and consolidate?


    Attached sample screenshot. ASR-Plan1 & ASR-Plan1 are recovery plan names and inside you can able to see VM names which are all protected(enabled).



    Appreciating in advance who are all helping on this.



    • Edited by d.jagadish Tuesday, January 21, 2020 3:41 PM Content line alignment
    Tuesday, January 21, 2020 3:40 PM