How can Blue-Green deployment involving VM & VMSS in Primary site work with ASR on DR site?

anshuman-nath 0 Reputation points
2024-04-08T15:30:04.4433333+00:00

Reposting my question from 6/April/2024 with some additional context, since I couldn't view the answer on QnA community for some strange reason and I had to flag it to the moderators.

At a high level, my solution includes

  • Primary site with Hub-&-Spoke architecture
  • Hub having Connectivity & Security Services and Spokes having workloads deployed on VM & VMSS
  • DR site for protection of VM & VMSS using Azure Site Recovery
  • The main workload subscription (a spoke) is provisioned to have Blue-Green Deployment, that's driven by Azure FrontDoor from Connectivity Hub.

Q1. I'm still unsure about VMSS replication & protection using ASR. Since there is only a single stateless workload in consideration, I believe I should be using "uniform orchestration", not "flexible orchestration" since the VM template is going to stay the same. In such a scenario, in each app release cycle, if I keep the VM template in Storage account, replicate it to my DR and use that to bring-up VMSS on Secondary site during planned/unplanned outage, could that work? If yes, how much RTO could be expected?

Q2. Has anyone worked with Blue-Green Deployment setup in Primary with Azure Site Recovery in DR? Does it mean that I've to constantly change the replication targets & policies in every app release cycle? Assuming Blue is the stable workload version serving production traffic while Green is the new build, released to a few test users for validation, what if I fixate the replication target only to Blue? Can this work in every subsequent app release cycles?

Azure Site Recovery
Azure Site Recovery
An Azure native disaster recovery service. Previously known as Microsoft Azure Hyper-V Recovery Manager.
636 questions
Azure Virtual Machine Scale Sets
Azure Virtual Machine Scale Sets
Azure compute resources that are used to create and manage groups of heterogeneous load-balanced virtual machines.
347 questions
{count} votes

2 answers

Sort by: Most helpful
  1. SadiqhAhmed-MSFT 37,846 Reputation points Microsoft Employee
    2024-04-22T15:24:50.62+00:00

    Hello @anshuman-nath Thank you for posting your question on Microsoft Q&A platform and I apologize for the delayed response!

    For your first question, As per support matrix - https://learn.microsoft.com/en-us/azure/site-recovery/azure-to-azure-support-matrix "Availability scenario - supported. Scalability scenario - not supported." meaning you can enable replication for VMSS VMs but cannot scale these VMs as per your requirement.

    As per this Microsoft official document - https://learn.microsoft.com/en-us/azure/virtual-machine-scale-sets/virtual-machine-scale-sets-orchestration-modes#backup-and-recovery ASR is supported by VMSS Flex, but only through PowerShell.

    For your second question, if you fixate the replication target only to Blue, it means that only the stable workload version serving production traffic will be replicated to the DR site. In case of a failover, the VMSS will be brought up using the replicated Blue version. However, this approach may not work in every subsequent app release cycle if there are significant changes to the VM template or the workload. In such cases, you may need to update the replication targets and policies in Azure Site Recovery. It is recommended to test the failover and failback scenarios after every app release cycle to ensure that the DR site is ready to handle any unplanned outages.

    Hope this helps. Let us know how it goes!


    If the response helped, do "Accept Answer" and up-vote it

    1 person found this answer helpful.
    0 comments No comments

  2. Pabitra Kumar Sikdar 0 Reputation points Microsoft Employee
    2024-04-29T11:28:55.5+00:00

    Hello @anshuman-nath!

    Based on the information you provided, here are my answers to your questions: Q1. For VMSS replication and protection using Azure Site Recovery (ASR), you can use either uniform or flexible orchestration. In your scenario, since you have a single stateless workload, uniform orchestration would be a good fit. You can keep the VM template in a storage account and replicate it to your DR site. During a planned or unplanned outage, you can use the replicated VM template to bring up the VMSS on the secondary site. The RTO (Recovery Time Objective) would depend on various factors such as the size of the VMSS, the amount of data to be replicated, and the network bandwidth between the primary and secondary sites. It's recommended to perform a DR drill to estimate the RTO. Q2. Yes, it's possible to use Blue-Green Deployment setup in the primary site with Azure Site Recovery in the DR site. You don't need to change the replication targets and policies in every app release cycle. You can fixate the replication target only to the Blue version, which is serving production traffic. When you release a new build (Green version), you can replicate it to the DR site and perform a DR drill to validate the failover process. Once you're confident that the Green version is stable, you can switch the traffic to it and make it the new Blue version. Then, you can replicate the new Blue version to the DR site and repeat the process. This way, you can ensure that the DR site is always in sync with the production site.

    0 comments No comments