Skip to content

Commit 3aa265c

Browse files
authored
Merge pull request #314780 from Xelu86/troublesapdaf
[Update] Troubleshooting the SAP Deployment Automation Framework
2 parents ed931c7 + cf48b39 commit 3aa265c

1 file changed

Lines changed: 49 additions & 56 deletions

File tree

Lines changed: 49 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,38 @@
11
---
2-
title: Troubleshoot the SAP Deployment Automation Framework
3-
description: Describe how to troubleshoot the SAP Deployment Automation Framework.
2+
title: Troubleshoot SAP Deployment Automation Framework
3+
description: Learn how to troubleshoot common issues with SAP Deployment Automation Framework, including deployment, configuration, and software download problems.
44
author: kimforss
55
ms.author: kimforss
6-
ms.reviewer: kimforss
7-
ms.date: 12/05/2023
8-
ms.topic: concept-article
6+
ms.date: 04/15/2026
7+
ms.topic: troubleshooting-general
98
ms.service: sap-on-azure
109
ms.subservice: sap-automation
11-
ms.custom:
1210
# Customer intent: As an SAP deployment engineer, I want to troubleshoot issues in the SAP Deployment Automation Framework, so that I can ensure successful deployments and maintain system integrity during the configuration and software download processes.
1311
---
1412

15-
# Troubleshooting the SAP Deployment Automation Framework
13+
# Troubleshoot SAP Deployment Automation Framework
1614

17-
18-
Within the SAP Deployment Automation Framework (SDAF), we recognize that there are many moving parts. This article is intended to help you troubleshoot issues that you can encounter.
15+
SAP Deployment Automation Framework (SDAF) has many moving parts. This article helps you troubleshoot issues that you might encounter.
1916

2017
## Control plane deployment
2118

2219
The control plane deployment consists of the following steps:
2320

24-
1. Deploy the deployer infrastructure.
25-
2. Add the Service Principal details to the Deployer key vault.
26-
3. Deploy the SAP Library infrastructure
27-
4. Migrate the Terraform state for the Deployer to the SAP Library.
28-
5. Migrate the Terraform state for the SAP Library to the SAP Library.
29-
30-
To track the progress of the deployment, the state is persisted in a file in the `.sap_deployment_automation` folder in the WORKSPACES directory.
21+
* Deploy the deployer infrastructure.
22+
* Add the service principal details to the deployer key vault.
23+
* Deploy the SAP Library infrastructure.
24+
* Migrate the Terraform state for the deployer to the SAP Library.
25+
* Migrate the Terraform state for the SAP Library to the SAP Library.
3126

32-
> [!div class="mx-tdCol2BreakAll "]
33-
> | Step | What is being deployed | State file location |
34-
> | ----- | ------------------------------------------------------------------------- | ------------------------ |
35-
> | 0 | Deployment infrastructure (virtual machine, key vault, Firewall, Bastion) | local |
36-
> | 1 | Service Principal details persisted in the deployer's key vault | local |
37-
> | 2 | SAP Library infrastructure (storage accounts, Private DNS) | local |
38-
> | 3 | Deployer terraform state migrated to remote storage | SAP Library |
39-
> | 4 | SAP Library terraform state migrated to remote storage | SAP Library |
27+
To track the progress of the deployment, the state is persisted in a file in the `.sap_deployment_automation` folder in the WORKSPACES directory.
4028

29+
| Step | What is being deployed | State file location |
30+
| ----- | ------------------------------------------------------------------------- | ------------------------ |
31+
| 0 | Deployment infrastructure (virtual machine, key vault, Firewall, Bastion) | local |
32+
| 1 | Service Principal details persisted in the deployer's key vault | local |
33+
| 2 | SAP Library infrastructure (storage accounts, Private DNS) | local |
34+
| 3 | Deployer terraform state migrated to remote storage | SAP Library |
35+
| 4 | SAP Library terraform state migrated to remote storage | SAP Library |
4136

4237
## Deployment
4338

@@ -47,12 +42,12 @@ This section describes how to troubleshoot issues that you can encounter when pe
4742

4843
If you see an error similar to the following error when running the deployment:
4944

50-
```text
51-
Unable to access keyvault: XXXXYYYYDEP00userBEB
45+
```
46+
Unable to access keyvault: XXXXYYYYDEP00userBEB
5247
Please ensure the key vault exists.
5348
```
5449

55-
This error indicates that the specified key vault doesn't exist or that the deployment environment is unable to access it.
50+
This error indicates that the specified key vault doesn't exist or that the deployment environment is unable to access it.
5651

5752
Depending on the deployment stage, you can resolve this issue in the following ways:
5853

@@ -69,18 +64,18 @@ public_network_access_enabled = true
6964

7065
If you see an error similar to the following error when running the deployment:
7166

72-
```text
67+
```
7368
Error: : Error retrieving keys for Storage Account "mgmtweeutfstate###": azure.BearerAuthorizer#WithAuthorization: Failed to refresh the Token for request to
7469
https://management.azure.com/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/MGMT-WEEU-SAP_LIBRARY/providers/Microsoft.Storage/storageAccounts/mgmtweeutfstate###/listKeys?api-version=2021-01-01
7570
: StatusCode=400 -- Original Error: adal: Refresh request failed. Status Code = '400'. Response body: {"error":"invalid_request","error_description":"Identity not found"} Endpoint
7671
http://169.254.169.254/metadata/identity/oauth2/token?api-version=2018-02-01&client_id=yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy&resource=https%3A%2F%2Fmanagement.azure.com%2F
7772
```
7873

79-
This error indicates that the credentials used to do the deployment doesn't have access to the storage account. To resolve this issue, assign the 'Storage Account Contributor' role to the deployment credential on the terraform state storage account, the resource group or the subscription (if feasible).
74+
This error indicates that the credentials used to do the deployment don't have access to the storage account. To resolve this issue, assign the **Storage Account Contributor** role to the deployment credential on the Terraform state storage account, the resource group, or the subscription (if feasible).
8075

8176
You can verify if the deployment is being performed using a service principal or a managed identity by checking the output of the deployment. If the deployment is using a service principal, the output contains the following section:
8277

83-
```text
78+
```
8479
[set_executing_user_environment_variables]: Identifying the executing user and client
8580
[set_azure_cloud_environment]: Identifying the executing cloud environment
8681
[set_azure_cloud_environment]: Azure cloud environment: public
@@ -95,12 +90,11 @@ You can verify if the deployment is being performed using a service principal or
9590
ARM_USE_MSI: false
9691
```
9792

98-
Look for the following line in the output: "ARM_USE_MSI: false"
93+
Look for the following line in the output: `ARM_USE_MSI: false`
9994

10095
If the deployment is using a managed identity, the output contains the following section:
10196

102-
```text
103-
97+
```
10498
[set_executing_user_environment_variables]: Identifying the executing user and client
10599
[set_azure_cloud_environment]: Identifying the executing cloud environment
106100
[set_azure_cloud_environment]: Azure cloud environment: public
@@ -114,9 +108,9 @@ If the deployment is using a managed identity, the output contains the following
114108
ARM_USE_MSI: true
115109
```
116110

117-
Look for the following line in the output: "ARM_USE_MSI: true"
111+
Look for the following line in the output: `ARM_USE_MSI: true`
118112

119-
You can assign the 'Storage Account Contributor' role to the deployment credential on the terraform state storage account, the resource group or the subscription (if feasible). Use the ARM_CLIENT_ID from the deployment output.
113+
You can assign the **Storage Account Contributor** role to the deployment credential on the Terraform state storage account, the resource group, or the subscription (if feasible). Use the `ARM_CLIENT_ID` from the deployment output.
120114

121115
```cloudshell-interactive
122116
export appId="<ARM_CLIENT_ID>"
@@ -126,7 +120,7 @@ az role assignment create --assignee ${appId} \
126120
--scope /subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/MGMT-WEEU-SAP_LIBRARY/providers/Microsoft.Storage/storageAccounts/mgmtweeutfstate###
127121
```
128122

129-
You may also need to assign the reader role to the deployment credential on the subscription containing the resource group with the Terraform state file. You can do that with the following command:
123+
You might also need to assign the Reader role to the deployment credential on the subscription containing the resource group with the Terraform state file. You can do that with the following command:
130124

131125
```cloudshell-interactive
132126
export appId="<ARM_CLIENT_ID>"
@@ -138,9 +132,9 @@ az role assignment create --assignee ${appId} \
138132

139133
### Private DNS Zone Name 'xxx' wasn't found
140134

141-
If you see an error similar to the following error when running the deployment:
135+
If you see an error similar to the following errors when running the deployment:
142136

143-
```text
137+
```
144138
Private DNS Zone Name: "privatelink.file.core.windows.net" was not found
145139
146140
or
@@ -150,10 +144,9 @@ Private DNS Zone Name: "privatelink.blob.core.windows.net" was not found
150144
or
151145
152146
Private DNS Zone Name: "privatelink.vaultcore.azure.net" was not found
153-
154147
```
155148

156-
This error indicates that the Private DNS zone listed in the error isn't available. You can resolve this issue by either creating the Private DNS or providing the configuration for an existing private DNS Zone. For more information on how to create the Private DNS Zone, see [Create a private DNS zone](/azure/dns/private-dns-getstarted-cli#create-a-private-dns-zone).
149+
This error indicates that the Private DNS zone listed in the error isn't available. You can resolve this issue by either creating the Private DNS zone or providing the configuration for an existing Private DNS zone. For more information on how to create a Private DNS zone, see [Create a private DNS zone](/azure/dns/private-dns-getstarted-cli#create-a-private-dns-zone).
157150

158151
You can specify the details for an existing private DNS zone by using the following variables:
159152

@@ -165,32 +158,32 @@ management_dns_resourcegroup_name="<resource group name for the Private DNS Zone
165158
management_dns_subscription_id="<subscription id for resource group name for the Private DNS Zone>"
166159
167160
use_custom_dns_a_registration=false
168-
169161
```
170162

171163
Rerun the deployment after you made these changes.
172164

173165
### OverconstrainedAllocationRequest error
166+
174167
If you see an error similar to the following error when running the deployment:
175168

176-
```text
169+
```
177170
Virtual Machine Name: "devsap01app01": Code="OverconstrainedAllocationRequest" Message="Allocation failed. VM(s) with the following constraints cannot be allocated, because the condition is too restrictive. Please remove some constraints and try again. Constraints applied are:
178171
- Networking Constraints (such as Accelerated Networking or IPv6)
179172
- VM Size
180173
```
181174

182-
This error indicates that the selected VM size isn't available using the provided constraints. To resolve this issue, select a different VM size or a different availability zone.
175+
This error indicates that the selected virtual machine (VM) size isn't available using the provided constraints. To resolve this issue, select a different VM size or a different availability zone.
183176

184-
### The client 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' with object id error
185-
If you see an error similar to the following message when running the deployment:
177+
### The client 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' with object ID error
186178

187-
```text
179+
If you see an error similar to the following message when running the deployment:
188180

181+
```
189182
The client 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' with object id 'yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy' does not have
190183
authorization or an ABAC condition not fulfilled to perform action 'Microsoft.Authorization/roleAssignments/write' over scope '/subscriptions/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/resourceGroups/DEV-WEEU-SAP01-X00/providers/Microsoft.Storage/storageAccounts/....
191184
```
192185

193-
The error indicates that the deployment credential doesn't have 'User Access Administrator' role on the resource group. To resolve this issue, assign the 'User Access Administrator' role to the deployment credential on the resource group or the subscription (if feasible).
186+
The error indicates that the deployment credential doesn't have the **User Access Administrator** role on the resource group. To resolve this issue, assign the **User Access Administrator** role to the deployment credential on the resource group or the subscription (if feasible).
194187

195188
## Configuration
196189

@@ -200,19 +193,19 @@ This section describes how to troubleshoot issues that you can encounter when pe
200193

201194
If you see an error similar to the following message when running the deployment:
202195

203-
```text
196+
```
204197
ERROR! this task 'ansible.builtin.command' has extra params, which is only allowed in the following modules: set_fact, shell, include_tasks, win_shell, import_tasks, import_role, include, win_command, command, include_role, meta, add_host, script, group_by, raw, include_vars
205198
```
206199

207-
This error indicates that the version of Ansible installed on the agent doesn't support this task. To resolve this issue, upgrade to the latest version of Ansible on the agent virtual machine.
200+
This error indicates that the version of Ansible installed on the agent doesn't support this task. To resolve this issue, upgrade to the latest version of Ansible on the agent VM.
208201

209202
## Software download
210203

211204
This section describes how to troubleshoot issues that you can encounter when downloading the SAP software using the SAP Deployment Automation Framework.
212205

213206
### "HTTP Error 404: Not Found"
214207

215-
This error indicates that the software version is no longer available for download. Open a GitHub issue [New Issue](https://github.com/Azure/SAP-automation-samples/issues/new/choose)to request an update to the Bill of Materials file, or update the Bill of Materials file yourself and submit a pull request.
208+
This error indicates that the software version is no longer available for download. Open a GitHub issue [New Issue](https://github.com/Azure/SAP-automation-samples/issues/new/choose) to request an update to the Bill of Materials file, or update the Bill of Materials file yourself and submit a pull request.
216209

217210
## Azure DevOps
218211

@@ -222,15 +215,15 @@ This section describes how to troubleshoot issues that you can encounter when us
222215

223216
If you see an error similar to the following message when running the Azure Pipelines:
224217

225-
```text
218+
```
226219
##[error]Variable group SDAF-MGMT could not be found.
227220
##[error]Bash exited with code '2'.
228221
```
229222

230-
This error indicates that the configured personal access token doesn't have permissions to access the variable group. Ensure that the personal access token has the **Read & manage** permission for the variable group and that it's still valid. The personal access token is configured in the Azure DevOps pipeline variable groups either as 'PAT' in the control plane variable group or as 'WZ_PAT' in the workload zone variable group.
231-
223+
This error indicates that the configured personal access token doesn't have permissions to access the variable group. Ensure that the personal access token has the **Read & manage** permission for the variable group and that it's still valid. The personal access token is configured in the Azure DevOps pipeline variable groups either as `PAT` in the control plane variable group or as `WZ_PAT` in the workload zone variable group.
232224

233-
## Next step
225+
## Related content
234226

235-
> [!div class="nextstepaction"]
236-
> [Configure custom naming](naming-module.md)
227+
- [SAP Deployment Automation Framework](deployment-framework.md)
228+
- [Deploy the control plane](deploy-control-plane.md)
229+
- [Configure Azure DevOps for the automation framework](configure-devops.md)

0 commit comments

Comments
 (0)