For mission critical SAP workloads running on Azure, deployment across Availability Zones is one of the commonly used architectures to provide resiliency against datacenter failures within a region. When using Availability Zones for SAP deployments there are 2 types of architectures possible
Our documentation here provides clear guidance on choosing the best possible architecture based on the requirements and location.
The reference architecture for Active/Passive deployment is as per below.
In the above scenario, all Application servers are active in Zone 1 where database is active. Application servers in Zone 2 are in passive mode (shutdown). When the database fails over to the second Zone (either due to complete Zonal outage or VM failure or manual switchover) application servers need to be switched from Zone 1 to Zone 2 i.e. app servers on Zone 2 need to be started and app servers on Zone 1 need to be shutdown gracefully. In this blog we will look into how this can be done in an automated way in Azure, along with sample scripts/runbooks for database running on Linux pacemaker cluster.
In order to achieve the switch as described above, we need 2 things
Azure Automation Runbooks are a great way to create event-based automation to respond to issues. Automation runbook can be triggered directly from Alert action with Azure Monitor or using webhooks. When using webhook it is highly recommended to secure it using Private Endpoint and restrict public access . In our scenario the runbook will do the following
If you would like to run some checks before step4, you could add an approval workflow before Step 4 is carried out. This can be done by setting up a simple Logic app to display a Team's adaptive card or email workflow or raising incidents directly into a ticketing system of your choice.
For starting and stopping application servers you could leverage the wonderful Start-Stop Automation framework in github. The runbook sample provided below makes use of this framework for Start/Stop of SAP application servers.
Detailed implementation steps along with scripts are available here SAP-on-Azure-AppServers-Avzone-Failover
In this blog we saw one of the possible approaches for automated switching of SAP Application servers in an Active/Passive setup of SAP deployment across Zones. The approach and the runbooks can also be tweaked for Active/Active scenario to handle the case of complete Zone failure to ensure that minimum number of application servers are always active across the zones.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.