Microsoft Azure is one of the most trending architecture/solution for Cloud Computing. Due to ease of implementation, it is attracting a good number of Customers to migrate or implement their enterprise application. Maintenance is facilitated by many providers and unexpected downtime are very minimum.
High Availability Solutions: Although there are blogs and documents available on SCN & MSDN for achieving/implementing High Availability Systems on regular On-Premise infrastructure but I still want to provide clarity regarding, working of Fail-Over in Azure, SQL Server Always On, Disk Sharing restrictions, Resource Mappings etc because administration/configuration on Azure is bit different than On-Premise for HA solutions.
SQL Server Always On: Microsoft has introduced a novel feature “Always On” which replaces the regular clustering solution and instead after its configuration you will have one or more than one live copy of database which remains in sync with the original database node or Primary Node.
Hardware: To build High Availability Solution with Microsoft Azure Cloud & SQL Server Always On functionality you will require four (4) VMs.
This minimum (4 VM) requirement is due to the below restrictions:
- Microsoft Azure doesn’t support Shared Disk Methodology for SAP Application Installation Clustering and without share disk you can’t install HA SAP Application
There are 2 options available creating/configuring Shared Disk:
- Use third Party Solution (SIOS Datakeeper)
- Express Route for remote iSCSI Target shared block storage.
- Internal mechanism used in Microsoft Azure for failover which is ILB (Internal Load Balancer), it can support only one application at a time for failover in cluster and hence we cannot install SAP Application & Database both in same Cluster Group/Nodes/VMs.
- Along with above restrictions Azure doesn’t support Multiple Virtual IP Addresses.
With Microsoft Azure you can use two types of disks:
- Standard Storage/ Disks: These are regular disks as used in normal VMs. These can be used if we are going to install additional dialog instances on Azure because that will require very small size of disk.
- Premium Storage/Disks: These are high performance storage/disks and should be used for at least Central Application & Database. Below is table with detail of type/model of premium disks available in Microsoft Azure Cloud:
Type of Disk
Size of Disk
P10 disk provides good output/performance (better than regular SCSI) but for better or best performance we choose P20 or P30. Based on their IOPS and disk size these disks can be further sliced into smaller partitions but it is not recommended to perform too much slicing or partitions as it will impact their IOPS accordingly.
You can refer SAP Note 1928533 for further reference about the SAP Components compatibility on Azure and the type of hardware available.
Do’s & Don’t:
- Always check Microsoft Windows Image to be used if going for high availability solution. (DO)
- Configure Probe port with ILB IP Address for SAP Share prior to installing Additional Cluster Instance on Node B. (DO)
- Configure Probe port with ILB IP Address for Database Nodes only when starting Availability Group and Listener configuration for SQL Server Always On. (DO)
- Create entry for SAP ASCS (Cluster Name) and ILB IP Address in host file of all application and database hosts. (DO)
- Disable Windows Firewall & IE Enhanced Security Configuration. (DO)
- Ensure that <SIDADM> user is added to domain user group. (DO)
- Always use non sidadm Administrator user for installation. (DO)
Below are the steps which I followed for doing SAP Netweaver 7.4 installation as HA with MS SQL 2012 database and used third party SIOS Tool for share disk mechanism.
- Distributed or High Availability Solution always is domain installation so either use Administartor user which is part of Domain Administrator or get <domain>\<sidadm> & <domain>\<SAPServiceSID> created in advance.
- Install SIOS tool on both SAP Application Nodes and configure disks for synchronizing sync.
- Maintain Registry Entries (Timeout).
- Check if you are able to failover shared disk access between application nodes for SAP ASCS.
- Install SAP First Cluster Node on Node A.
- Install SAP Additional Cluster Node on Node B.
- Install SQL Server 2012 with latest service packs on both Database node.
- Ensure Collation is set to SQL_Latin1_General_CP850_BIN2.
- Create Data & Log directories prior to installation of SAP Database on Database Node A.
- Check if //<SAPASCS>/sapmnt path is accessible from database nodes.
- Start SAP Database installation on Database Node A.
- Initiate full database backup from Database Node A and transfer it to Database Node B.
- Restore database backup of Node A to Node B with option “Restore with NoRecovery”.
- Check Security Settings for SQL Server Always On Group.
- Enable AlwaysOn Availablity Group for SQL Server Service Properties in SQL Server Configuration Manager. (Perform this step on both database nodes.)
- Change Logon for SQL Server Service in SQL Server Configuration Manager to <Domain>\<SIDADM> user. (Perform this step on both database nodes.)
- Create & Configure New SQL Server Availability Group through SQL Server Management Studio and add both database nodes with “Join Only” synchronization preference.
- Create & Configure Listener (Client Access Point) Service.
- Assign ILB IP Address to Listener Entry.
- Set Dependency for SQL DB Availability Group to Listener.
- Download the scripts for setting up logon credentials/groups/permissions similar on both database nodes.
- Execute sp_help_revlogin2 script on database node A.
- Execute sap_help_revlogin script on database node A. Copy the result and create sql file and transfer the file to database node B.
- Execute the result sql file on database node B. (Ignore error regarding SAP_<SID>_LocalAdmin group).
- Compare Users/Permissions on both Database Nodes.
- Change “DEFAULT” profile parameters “SAPDBHOST” and “dbs/mss/server” to Listener Name.
- Stop & Start SAP ASCS Services.
- Install Primary Application Server on SAP Node A. (If you are using only 4 VMs then can install this in local drive)
- Install Additional Application Server Instance on SAP Node B. (If you are using only 4 VMs then can install this in local drive)
- Update <SIDADM> environment variables. (e.g. MSSQL_SERVER, MSSQL_CONNOPTS etc.)
- Stop SAP Application & Database and restart all nodes.
- Install SAP License for both SAP Nodes.
- Open Failover Cluster Manager on application nodes and move group/services from Node A to Node B and vice versa.
- Restart one node while logged on SAP application and vice versa.
- Open Failover Cluster Manager on database nodes and move group/services from Database Node A to Database Node B and vice versa
- Restart one DB Node while SAP application and database are running and check if everything is working fine in application and database.
SAP Notes Reference:
- 1928533 – SAP Applications on Azure: Supported Products and Azure VM types.
- 1612283 – Hardware Configuration Standards and Guidance
- 1772688 – SQL Server AlwaysOn and SAP applications
- 2015553 – SAP on Microsoft Azure Support prerequisites
- 2020535 – Profile parameter conn_opts
- 2137130 – SAP startup hangs with SQL Server
- 2303398 – SAP on SQL Server in Microsoft Azure Virtual Machines