|
1 | 1 | --- |
2 | | -title: Tutorial - Create a distributed highly available SAP system with Azure Center for SAP solutions with Azure CLI |
3 | | -description: In this tutorial you learn to create a distributed highly available SAP system in Azure Center for SAP solutions through Azure CLI. |
| 2 | +title: Create infrastructure for a distributed highly available SAP system with customized resource names using Azure CLI |
| 3 | +description: Learn how to use Azure CLI to deploy infrastructure for a distributed highly available SAP system with customized resource names in Azure Center for SAP solutions. |
4 | 4 | ms.service: sap-on-azure |
5 | 5 | ms.subservice: center-sap-solutions |
6 | 6 | ms.custom: devx-track-azurecli |
7 | | -ms.topic: tutorial |
8 | | -ms.date: 05/04/2023 |
| 7 | +ms.topic: how-to |
| 8 | +ms.date: 04/06/2026 |
9 | 9 | ms.author: sagarkeswani |
10 | 10 | author: sagarkeswani |
11 | | -#Customer intent: As a developer, I want to create a distributed highly available SAP system so that I can use the system with Azure Center for SAP solutions. |
12 | 11 | # Customer intent: As a developer, I want to deploy a highly available distributed SAP system using Azure CLI, so that I can efficiently manage and utilize the SAP infrastructure within Azure Center for SAP solutions. |
13 | 12 | --- |
14 | | -# Tutorial: Use Azure CLI to create infrastructure for a distributed highly available (HA) SAP system with *Azure Center for SAP solutions* with customized resource names |
15 | 13 |
|
16 | | -[Azure Center for SAP solutions](overview.md) enables you to deploy and manage SAP systems on Azure. After you deploy infrastructure and [install SAP software](install-software.md) with *Azure Center for SAP solutions*, you can use its visualization, management and monitoring capabilities through the [Virtual Instance for SAP solutions](https://github.com/MicrosoftDocs/azure-docs/blob/main/articles/sap/center-sap-solutions/manage-virtual-instance.md) |
| 14 | +# Create infrastructure for a distributed highly available SAP system with customized resource names using Azure CLI |
17 | 15 |
|
18 | | -## Introduction |
19 | | -The [Azure CLI](/cli/azure/) is used to create and manage Azure resources from the command line or in scripts. |
20 | | - |
21 | | -This tutorial shows you how to use Azure CLI to deploy infrastructure for an SAP system with highly available (HA) Three-tier Distributed architecture. You also see how to customize resource names for the Azure infrastructure that gets deployed. See the following steps: |
22 | | -> [!div class="checklist"] |
23 | | -> * Complete the pre-requisites |
24 | | -> * Understand the SAP SKUs available for your deployment type |
25 | | -> * Check for recommended SKUs for SAPS and Memory requirements for your SAP system |
26 | | -> * Create json configuration file with custom resource names |
27 | | -> * Deploy infrastructure for your SAP system |
| 16 | +[Azure Center for SAP solutions](overview.md) is an Azure service that deploys and manages SAP systems on Azure. When Azure Center for SAP solutions creates infrastructure, it assigns default names to Azure resources, such as virtual machines (VMs), network interfaces, and load balancers. If your organization requires specific naming conventions for governance or easier resource identification, you can customize these names during deployment. |
28 | 17 |
|
| 18 | +In this article, you use Azure CLI to deploy infrastructure for a distributed, highly available (HA) SAP system and customize the resource names that Azure Center for SAP solutions assigns to the deployed infrastructure. |
29 | 19 |
|
30 | 20 | ## Prerequisites |
31 | 21 |
|
32 | | -- An Azure subscription. |
33 | | -- If you're using Azure Center for SAP solutions for the first time, Register the **Microsoft.Workloads** Resource Provider on the subscription in which you're deploying the SAP system: |
| 22 | +- An Azure subscription. If you don't have an Azure subscription, you can [create a free account](https://azure.microsoft.com/pricing/purchase-options/azure-account?cid=msft_learn). |
| 23 | + |
| 24 | +- The **Microsoft.Workloads** resource provider registered on the subscription where you're deploying the SAP system: |
34 | 25 |
|
35 | | - ```azurecli-interactive |
36 | | - az provider register --namespace 'Microsoft.Workloads' |
37 | | - ``` |
| 26 | + ```azurecli-interactive |
| 27 | + az provider register --namespace 'Microsoft.Workloads' |
| 28 | + ``` |
38 | 29 |
|
39 | 30 | - An Azure account with **Azure Center for SAP solutions administrator** and **Managed Identity Operator** role access to the subscriptions and resource groups in which you create the Virtual Instance for SAP solutions (VIS) resource. |
40 | | -- A **User-assigned managed identity** which has **Azure Center for SAP solutions service role** access on the Subscription or at least all resource groups (Compute, Network,Storage). If you wish to install SAP Software through the Azure Center for SAP solutions, also provide **Reader and Data Access** role to the identity on SAP bits storage account where you would store the SAP Media. |
41 | | -- A [network set up for your infrastructure deployment](prepare-network.md). |
42 | | -- Availability of minimum 4 cores of either Standard_D4ds_v4 or Standard_E4s_v3, SKUS which will be used during Infrastructure deployment and Software Installation |
43 | | -- [Review the quotas for your Azure subscription](/azure/quotas/view-quotas). If the quotas are low, you might need to create a support request before creating your infrastructure deployment. Otherwise, you might experience deployment failures or an **Insufficient quota** error. |
44 | | -- Note the SAP Application Performance Standard (SAPS) and database memory size that you need to allow Azure Center for SAP solutions to size your SAP system. If you're not sure, you can also select the VMs. There are: |
45 | | - - A single or cluster of ASCS VMs, which make up a single ASCS instance in the VIS. |
46 | | - - A single or cluster of Database VMs, which make up a single Database instance in the VIS. |
47 | | - - A single Application Server VM, which makes up a single Application instance in the VIS. Depending on the number of Application Servers being deployed or registered, there can be multiple application instances. |
| 31 | +- A **user-assigned managed identity** that has **Azure Center for SAP solutions service role** access on the subscription or at least all resource groups (Compute, Network, Storage). If you plan to install SAP software through Azure Center for SAP solutions, also assign the **Reader and Data Access** role to the identity on the storage account where you store the SAP media. |
| 32 | +- A [network configured for your infrastructure deployment](prepare-network.md). |
| 33 | +- A minimum of four cores of either `Standard_D4ds_v4` or `Standard_E4s_v3` SKUs available in your subscription. |
| 34 | +- [Sufficient quotas for your Azure subscription](/azure/quotas/view-quotas). If the quotas are low, you might need to create a support request before creating your infrastructure deployment. Otherwise, you might experience deployment failures or an **Insufficient quota** error. |
| 35 | +- The SAP Application Performance Standard (SAPS) and database memory size that you need so that Azure Center for SAP solutions can size your SAP system. If you're unsure, you can select the VMs directly, such as: |
| 36 | + - One or more ASCS VMs, which make up a single ASCS instance in the VIS. |
| 37 | + - One or more database VMs, which make up a single database instance in the VIS. |
| 38 | + - A single application server VM, which makes up a single application instance in the VIS. Depending on the number of application servers that you deploy or register, there can be multiple application instances. |
48 | 39 |
|
49 | 40 | [!INCLUDE [cloud-shell-try-it.md](~/reusable-content/ce-skilling/azure/includes/cloud-shell-try-it.md)] |
50 | 41 |
|
51 | | -## Understand the SAP certified Azure SKUs available for your deployment type |
| 42 | +## Review SAP-certified Azure SKUs for your deployment type |
52 | 43 |
|
53 | | -Use [az workloads sap-supported-sku](/cli/azure/workloads?view=azure-cli-latest#az-workloads-sap-supported-sku&preserve-view=true) to get a list of SKUs supported for your SAP system deployment type from Azure Center for SAP solutions |
| 44 | +1. Run [az workloads sap-supported-sku](/cli/azure/workloads?view=azure-cli-latest#az-workloads-sap-supported-sku&preserve-view=true) to get a list of SKUs supported for your SAP system deployment type: |
54 | 45 |
|
55 | | -```azurecli-interactive |
56 | | -az workloads sap-supported-sku --app-location "eastus" --database-type "HANA" --deployment-type "ThreeTier" --environment "Prod" --high-availability-type "AvailabilitySet" --sap-product "S4HANA" --location "eastus" |
57 | | -``` |
58 | | -You can use any of these SKUs recommended for App tier and Database tier when deploying infrastructure in the later steps. Or you can use the recommended SKUs by *Azure Center for SAP solutions* in the next step. |
| 46 | + ```azurecli-interactive |
| 47 | + az workloads sap-supported-sku --app-location "eastus" --database-type "HANA" --deployment-type "ThreeTier" --environment "Prod" --high-availability-type "AvailabilitySet" --sap-product "S4HANA" --location "eastus" |
| 48 | + ``` |
59 | 49 |
|
60 | | -## Check for recommended SKUs for SAPS and Memory requirements for your SAP system |
| 50 | +1. Review the output to identify supported SKUs for the app tier and database tier. You can use any of these SKUs when you deploy infrastructure, or use the recommended SKUs from the next section. |
61 | 51 |
|
62 | | -Use [az workloads sap-sizing-recommendation](/cli/azure/workloads?view=azure-cli-latest#az-workloads-sap-sizing-recommendation&preserve-view=true) to get SAP system sizing recommendations by providing SAPS input for application tier and memory required for database tier |
| 52 | +## Check recommended SKUs for SAPS and memory requirements |
63 | 53 |
|
64 | | -```azurecli-interactive |
65 | | -az workloads sap-sizing-recommendation --app-location "eastus" --database-type "HANA" --db-memory 1024 --deployment-type "ThreeTier" --environment "Prod" --high-availability-type "AvailabilitySet" --sap-product "S4HANA" --saps 75000 --location "eastus2" --db-scale-method ScaleUp |
66 | | -``` |
| 54 | +1. Run [az workloads sap-sizing-recommendation](/cli/azure/workloads?view=azure-cli-latest#az-workloads-sap-sizing-recommendation&preserve-view=true) to get SAP system sizing recommendations by providing SAPS input for the application tier and memory required for the database tier: |
| 55 | + |
| 56 | + ```azurecli-interactive |
| 57 | + az workloads sap-sizing-recommendation --app-location "eastus" --database-type "HANA" --db-memory 1024 --deployment-type "ThreeTier" --environment "Prod" --high-availability-type "AvailabilitySet" --sap-product "S4HANA" --saps 75000 --location "eastus2" --db-scale-method ScaleUp |
| 58 | + ``` |
| 59 | + |
| 60 | +1. Review the recommended SKUs from the output. You use these values when you create the configuration file. |
| 61 | + |
| 62 | +## Create a JSON configuration file with custom resource names |
67 | 63 |
|
68 | | -## Create *json* configuration file with custom resource names |
69 | | - |
70 | | -- Prepare a *json* file with the configuration (payload) to use for the deployment of SAP system infrastructure. You can make edits in this [sample payload](https://github.com/Azure/Azure-Center-for-SAP-solutions-preview/blob/main/Payload_Samples/CreatePayload_withTransportDirectory_withHAAvSet_withCustomResourceName.json) or use the examples listed in the [Rest API documentation](/rest/api/workloads) for Azure Center for SAP solutions |
71 | | -- In this json file, provide the custom resource names for the infrastructure that is deployed for your SAP system |
72 | | -- The parameters available for customization are: |
73 | | - - VM Name |
74 | | - - Host Name |
75 | | - - Network interface name |
76 | | - - OS Disk Name |
77 | | - - Load Balancer Name |
78 | | - - Frontend IP Configuration Names |
79 | | - - Backend Pool Names |
80 | | - - Health Probe Names |
81 | | - - Data Disk Names: default, hanaData or hana/data, hanaLog or hana/log, usrSap or usr/sap, hanaShared or hana/shared, backup |
82 | | - - Shared Storage Account Name |
83 | | - - Shared Storage Account Private End Point Name |
84 | | - |
85 | | -You can download the [sample payload](https://github.com/Azure/Azure-Center-for-SAP-solutions-preview/blob/main/Payload_Samples/CreatePayload_withTransportDirectory_withHAAvSet_withCustomResourceName.json) and replace the resource names and any other parameter as needed |
| 64 | +1. Download the [sample payload](https://github.com/Azure/Azure-Center-for-SAP-solutions-preview/blob/main/Payload_Samples/CreatePayload_withTransportDirectory_withHAAvSet_withCustomResourceName.json) or use the examples in the [REST API documentation](/rest/api/workloads) for Azure Center for SAP solutions. |
| 65 | + |
| 66 | +1. Open the JSON file and replace the default resource names with your custom names. The following parameters are available for customization: |
| 67 | + |
| 68 | + - VM name |
| 69 | + - Host name |
| 70 | + - Network interface name |
| 71 | + - OS disk name |
| 72 | + - Load balancer name |
| 73 | + - Frontend IP configuration names |
| 74 | + - Backend pool names |
| 75 | + - Health probe names |
| 76 | + - Data disk names: default, hanaData or hana/data, hanaLog or hana/log, usrSap or usr/sap, hanaShared or hana/shared, backup |
| 77 | + - Shared storage account name |
| 78 | + - Shared storage account private endpoint name |
| 79 | + |
| 80 | +1. Save the JSON file. Remember the file path for use in the deployment command. |
86 | 81 |
|
87 | 82 | ## Deploy infrastructure for your SAP system |
88 | 83 |
|
89 | | -Use [az workloads sap-virtual-instance create](/cli/azure/workloads/sap-virtual-instance?view=azure-cli-latest#az-workloads-sap-virtual-instance-create&preserve-view=true) to deploy infrastructure for your SAP system with Three tier HA architecture. |
| 84 | +1. Run [az workloads sap-virtual-instance create](/cli/azure/workloads/sap-virtual-instance?view=azure-cli-latest#az-workloads-sap-virtual-instance-create&preserve-view=true) to deploy infrastructure for your SAP system with a three-tier HA architecture: |
90 | 85 |
|
91 | | -```azurecli-interactive |
92 | | -az workloads sap-virtual-instance create -g <Resource Group Name> -n <VIS Name> --environment NonProd --sap-product s4hana --configuration <Payload file path> --identity "{type:UserAssigned,userAssignedIdentities:{<Managed_Identity_ResourceID>:{}}}" |
93 | | -``` |
94 | | -This will deploy your SAP system and the Virtual instance for SAP solutions (VIS) resource representing your SAP system in Azure. |
| 86 | + ```azurecli-interactive |
| 87 | + az workloads sap-virtual-instance create -g <Resource_Group_Name> -n <VIS_Name> --environment NonProd --sap-product s4hana --configuration <Payload_file_path> --identity "{type:UserAssigned,userAssignedIdentities:{<Managed_Identity_ResourceID>:{}}}" |
| 88 | + ``` |
| 89 | + |
| 90 | +1. Wait for the deployment to complete. The command creates your SAP system infrastructure and the Virtual Instance for SAP solutions (VIS) resource that represents your SAP system in Azure. |
95 | 91 |
|
96 | | -## Cleanup |
97 | | -If you no longer wish to use the VIS resource, you can delete it by using [az workloads sap-virtual-instance delete](/cli/azure/workloads/sap-virtual-instance?view=azure-cli-latest#az-workloads-sap-virtual-instance-delete&preserve-view=true) |
| 92 | +## Clean up resources |
| 93 | + |
| 94 | +If you no longer need the VIS resource, delete it by running [az workloads sap-virtual-instance delete](/cli/azure/workloads/sap-virtual-instance?view=azure-cli-latest#az-workloads-sap-virtual-instance-delete&preserve-view=true): |
98 | 95 |
|
99 | 96 | ```azurecli-interactive |
100 | | -az workloads sap-virtual-instance delete -g <Resource_Group_Name> -n <VIS Name> |
| 97 | +az workloads sap-virtual-instance delete -g <Resource_Group_Name> -n <VIS_Name> |
101 | 98 | ``` |
102 | | -This command will only delete the VIS and other resources created by Azure Center for SAP solutions. This will not delete the deployed infrastructure like VMs, Disks etc. |
103 | 99 |
|
| 100 | +This command deletes only the VIS and other resources created by Azure Center for SAP solutions. It doesn't delete the deployed infrastructure, such as VMs and disks. To remove those resources, delete them separately through the Azure portal or Azure CLI. |
| 101 | + |
| 102 | +## Next step |
104 | 103 |
|
105 | | -## Next steps |
106 | | -In this tutorial, you deployed infrastructure in Azure for an SAP system using Azure Center for SAP solutions. You used custom resource names for the infrastructure. Continue to the next article to learn how to install SAP software on the infrastructure deployed. |
107 | 104 | > [!div class="nextstepaction"] |
108 | 105 | > [Install SAP software](install-software.md) |
0 commit comments