Azure / Azure/azure-quickstart-templates

[USER ERROR] - Azure SQL Data store fails on creation, even with existing Azure SQL Server and AML Workspace

Open
#7,967 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Bicep
Stars
14.9k
Forks
16.2k
Avg merge
6d 21h
Merged PRs (30d)
6

Description

--------------------MESSAGE FROM ADMIN, DELETE BEFORE SUBMITTING----------------------

Sorry to hear you had a bad experience with one of the templates :worried: But, in case you're just asking a question, we're happy to help. You can also check if the question might already have been asked here https://github.com/Azure/azure-quickstart-templates/issues?utf8=%E2%9C%93&q=is%3Aissue

We've created an outline of recommended sections to fill out that will help make this Pull Request awesome!

--------------------MESSAGE FROM ADMIN, DELETE BEFORE SUBMITTING----------------------

[Create SQL Datastore in Azure Machine Learning Workspace](https://github.com/Azure/azure-quickstart-templates/blob/master/101-machine-learning-datastore-create-sql/azuredeploy.json)

### Issue Details
I am trying to create and attach an Azure SQL Datastore to an already existing, Azure SQL Server and DB. I can do this same thing from the portal, but fails, with the same parameters, using the ARM template. Below is the datastore section from my template

```
{
"type": "Microsoft.MachineLearningServices/workspaces/datastores",
"name": "[concat(parameters('workspaceName'), '/', parameters('datastoreName'))]",
"apiVersion": "2020-05-01-preview",
"location": "[parameters('location')]",
"dependsOn": [
"[resourceId('Microsoft.MachineLearningServices/workspaces', parameters('workspaceName'))]",
"[resourceId('Microsoft.Sql/servers', concat(parameters('serverName')))]"
],
"properties": {
"DataStoreType": "sqldb",
"SkipValidation": "[parameters('skipValidation')]",
"DatabaseName": "[parameters('sqlDBName')]",
"ServerName": "[parameters('serverName')]",
"UserName": "[parameters('serverAdminUserName')]",
"Password": "[parameters('serverAdminPassword')]",
"AuthorityUrl": "[parameters('authorityUrl')]",
"ResourceUrl": "[parameters('resourceUrl')]",
"Endpoint": "[parameters('endpoint')]"
}
}
```

No matter what I try, I end with the error below.
```
cli.azure.cli.core.util : Deployment failed. Correlation ID: beefcdfd-44f3-4d67-b20a-a915d8337173. {
"error": {
"code": "UserError",
"severity": null,
"message": "Azure SQL Database Error -2146232060: Please check the correctness of the datastore information.",
"messageFormat": null,
"messageParameters": null,
"referenceCode": null,
"detailsUri": null,
"target": null,
"details": [],
"innerError": null,
"debugInfo": null
},
"correlation": {
"operation": "",
"request": ""
},
"environment": "eastus",
"location": "eastus",
"time": "2020-08-13T13:46:31.4869049+00:00",
"componentName": "account-rp"
}
```
I am using the Server username and password and not Service Principal and TenantId, just as I can do from the portal.

### Repro steps (*if necessary, delete otherwise*)
1. Create Azure SQL Server and Db with ARM template
2. Create an AML workspace
3. Make sure `dependsOn` is set for the Datastore to wait for 1 and 2 above.
4. Create Datastore at this point, and it always fails with the error above.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with 101-machine-learning-datastore-create-sql/azuredeploy.json and inspect the Microsoft.MachineLearningServices/workspaces/datastores resource shown in the report. Reproduce the deployment using an existing Azure SQL Server, database, and AML workspace, then compare the template parameters with the portal configuration. Done means the datastore is created successfully or the template documents the required correction.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
cloud, databases
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.