You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/sql-database/sql-database-quickstart-r-create-script.md
+11-6Lines changed: 11 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,21 +15,26 @@ manager: cgronlun
15
15
ms.date: 04/11/2019
16
16
---
17
17
18
-
# Create and run simple R scripts in Azure SQL Database Machine Learning Services (preview)
18
+
# Quickstart: Create and run simple R scripts in Azure SQL Database Machine Learning Services (preview)
19
19
20
-
In this quickstart, you'll create and run a set of simple R scripts using the public preview of [Machine Learning Services (with R) in Azure SQL Database](sql-database-machine-learning-services-overview.md). You'll learn how to wrap a well-formed R script in the stored procedure [sp_execute_external_script](https://docs.microsoft.com/sql/relational-databases/system-stored-procedures/sp-execute-external-script-transact-sql) and execute the script in a SQL database.
20
+
In this quickstart, you create and run a set of R scripts using Machine Learning Services (with R) in Azure SQL Database.
-If you don't have an Azure subscription, [create an account](https://azure.microsoft.com/free/) before you begin.
26
+
-An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?ref=microsoft.com&utm_source=microsoft.com&utm_medium=docs&utm_campaign=visualstudio).
27
27
28
-
-To run the example code in these exercises, you must first have an Azure SQL database with Machine Learning Services (with R) enabled. During the public preview, Microsoft will onboard you and enable machine learning for your existing or new database. Follow the steps in [Sign up for the preview](sql-database-machine-learning-services-overview.md#signup).
28
+
-An [Azure SQL database](sql-database-single-database-get-started.md) with a [server-level firewall rule](sql-database-server-level-firewall-rule.md)
29
29
30
-
-Make sure you've installed the latest [SQL Server Management Studio](https://docs.microsoft.com/sql/ssms/sql-server-management-studio-ssms) (SSMS). You can run R scripts using other database management or query tools, but in this quickstart you'll use SSMS.
30
+
-[Machine Learning Services](sql-database-machine-learning-services-overview.md) with R enabled. [Sign up for the preview](sql-database-machine-learning-services-overview.md#signup).
31
31
32
-
- This quickstart requires that you configure a server-level firewall rule. For information on how to do this, see [Create server-level firewall rule](sql-database-server-level-firewall-rule.md).
32
+
-[SQL Server Management Studio](/sql/ssms/sql-server-management-studio-ssms) (SSMS)
33
+
34
+
> [!NOTE]
35
+
> During the public preview, Microsoft will onboard you and enable machine learning for your existing or new database.
36
+
37
+
This example uses the stored procedure [sp_execute_external_script](/sql/relational-databases/system-stored-procedures/sp-execute-external-script-transact-sql) to wrap a well-formed R script.
Copy file name to clipboardExpand all lines: articles/sql-database/sql-database-quickstart-r-train-score-model.md
+14-11Lines changed: 14 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,26 +15,29 @@ manager: cgronlun
15
15
ms.date: 04/11/2019
16
16
---
17
17
18
-
# Create and train a predictive model in R with Azure SQL Database Machine Learning Services (preview)
18
+
# Quickstart: Create and train a predictive model in R with Azure SQL Database Machine Learning Services (preview)
19
19
20
-
In this quickstart, you'll create and train a predictive model using R, save the model to a table in your SQL database, then use the model to predict values from new data using the public preview of [Machine Learning Services (with R) in Azure SQL Database](sql-database-machine-learning-services-overview.md).
21
-
22
-
The model you'll use in this quickstart is a simple regression model that predicts the stopping distance of a car based on speed. You'll use the **cars** dataset included with R, because it's small and easy to understand.
23
-
24
-
> [!TIP]
25
-
> Many datasets, small and large, are included with the R runtime. To get a list of datasets installed with R, type `library(help="datasets")` from an R command prompt.
20
+
In this quickstart, you create and train a predictive model using R, save the model to a table in your database, then use the model to predict values from new data using Machine Learning Services (with R) in Azure SQL Database.
- If you don't have an Azure subscription, [create an account](https://azure.microsoft.com/free/) before you begin.
26
+
- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?ref=microsoft.com&utm_source=microsoft.com&utm_medium=docs&utm_campaign=visualstudio).
27
+
28
+
- An [Azure SQL database](sql-database-single-database-get-started.md) with a [server-level firewall rule](sql-database-server-level-firewall-rule.md)
32
29
33
-
-To run the example code in these exercises, you must first have an Azure SQL database with Machine Learning Services (with R) enabled. During the public preview, Microsoft will onboard you and enable machinelearning for your existing or new database. Follow the steps in[Sign up for the preview](sql-database-machine-learning-services-overview.md#signup).
30
+
-[Machine Learning Services](sql-database-machine-learning-services-overview.md) with R enabled.[Sign up for the preview](sql-database-machine-learning-services-overview.md#signup).
34
31
35
-
-Make sure you've installed the latest [SQL Server Management Studio](https://docs.microsoft.com/sql/ssms/sql-server-management-studio-ssms) (SSMS). You can run the R scripts using other database management or query tools, but in this quickstart you'll use SSMS.
32
+
-[SQL Server Management Studio](/sql/ssms/sql-server-management-studio-ssms) (SSMS)
36
33
37
-
- This quickstart requires that you configure a server-level firewall rule. For information on how to do this, see [Create server-level firewall rule](sql-database-server-level-firewall-rule.md).
34
+
> [!NOTE]
35
+
> During the public preview, Microsoft will onboard you and enable machine learning for your existing or new database.
36
+
37
+
This example uses a simple regression model to predict the stopping distance of a car based on speed using the **cars** dataset included with R.
38
+
39
+
> [!TIP]
40
+
> Many datasets are included with the R runtime, to get a list of installed datasets, type `library(help="datasets")` from the R command prompt.
Copy file name to clipboardExpand all lines: articles/virtual-machines/linux/image-builder-json.md
+91-35Lines changed: 91 additions & 35 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,9 +1,9 @@
1
1
---
2
2
title: Create an Azure Image Builder template (preview)
3
3
description: Learn how to create a template to use with Azure Image Builder.
4
-
author: cynthn
5
-
ms.author: cynthn
6
-
ms.date: 07/31/2019
4
+
author: danis
5
+
ms.author: danis
6
+
ms.date: 01/23/2020
7
7
ms.topic: article
8
8
ms.service: virtual-machines-linux
9
9
manager: gwallace
@@ -22,11 +22,15 @@ This is the basic template format:
22
22
"tags": {
23
23
"<name": "<value>",
24
24
"<name>": "<value>"
25
-
},
25
+
}
26
26
"identity":{},
27
27
"dependsOn": [],
28
28
"properties": {
29
-
"buildTimeoutInMinutes": <minutes>,
29
+
"buildTimeoutInMinutes": <minutes>,
30
+
"vmProfile":
31
+
{
32
+
"vmSize": "<vmSize>"
33
+
},
30
34
"build": {},
31
35
"customize": {},
32
36
"distribute": {}
@@ -59,6 +63,24 @@ The location is the region where the custom image will be created. For the Image
59
63
```json
60
64
"location": "<region>",
61
65
```
66
+
## vmProfile
67
+
By default Image Builder will use a "Standard_D1_v2" build VM, you can override this, for example, if you want to customize an Image for a GPU VM, you need a GPU VM size. This is optional.
68
+
69
+
```json
70
+
{
71
+
"vmSize": "Standard_D1_v2"
72
+
},
73
+
```
74
+
75
+
## osDiskSizeGB
76
+
77
+
By default, Image Builder will not change the size of the image, it will use the size from the source image. You can adjust the size of the OS Disk (Win and Linux), note, do not go too small than the minimum required space required for the OS. This is optional, and a value of 0 means leave the same size as the source image. This is optional.
78
+
79
+
```json
80
+
{
81
+
"osDiskSizeGB": 100
82
+
},
83
+
```
62
84
63
85
## Tags
64
86
@@ -132,13 +154,7 @@ In the list of **Installers and Images for Red Hat Enterprise Linux Server**, yo
132
154
> The access tokens of the links are refreshed at frequent intervals, so every time you want to submit a template, you must check if the RH link address has changed.
133
155
134
156
### PlatformImage source
135
-
Azure Image Builder supports the following Azure Marketplace images:
136
-
* Ubuntu 18.04
137
-
* Ubuntu 16.04
138
-
* RHEL 7.6
139
-
* CentOS 7.6
140
-
* Windows 2016
141
-
* Windows 2019
157
+
Azure Image Builder supports Windows Server and client, and Linux Azure Marketplace images, see [here](https://docs.microsoft.com/azure/virtual-machines/windows/image-builder-overview#os-support) for the full list.
142
158
143
159
```json
144
160
"source": {
@@ -217,7 +233,8 @@ When using `customize`:
217
233
{
218
234
"type": "Shell",
219
235
"name": "<name>",
220
-
"scriptUri": "<path to script>"
236
+
"scriptUri": "<path to script>",
237
+
"sha256Checksum": "<sha256 checksum>"
221
238
},
222
239
{
223
240
"type": "Shell",
@@ -243,7 +260,8 @@ The shell customizer supports running shell scripts, these must be publicly acce
243
260
{
244
261
"type": "Shell",
245
262
"name": "<name>",
246
-
"scriptUri": "<link to script>"
263
+
"scriptUri": "<link to script>",
264
+
"sha256Checksum": "<sha256 checksum>"
247
265
},
248
266
],
249
267
"customize": [
@@ -263,7 +281,12 @@ Customize properties:
263
281
-**name** - name for tracking the customization
264
282
-**scriptUri** - URI to the location of the file
265
283
-**inline** - array of shell commands, separated by commas.
266
-
284
+
-**sha256Checksum** - Value of sha256 checksum of the file, you generate this locally, and then Image Builder will checksum and validate.
285
+
* To generate the sha256Checksum, using a terminal on Mac/Linux run: `sha256sum <fileName>`
286
+
287
+
288
+
For commands to run with super user privileges, they must be prefixed with `sudo`.
289
+
267
290
> [!NOTE]
268
291
> When running the shell customizer with RHEL ISO source, you need to ensure your first customization shell handles registering with a Red Hat entitlement server before any customization occurs. Once customization is complete, the script should unregister with the entitlement server.
269
292
@@ -272,12 +295,15 @@ The Restart customizer allows you to restart a Windows VM and wait for it come b
@@ -297,13 +323,16 @@ The shell customizer supports running PowerShell scripts and inline command, the
297
323
{
298
324
"type": "PowerShell",
299
325
"name": "<name>",
300
-
"scriptUri": "<path to script>"
326
+
"scriptUri": "<path to script>",
327
+
"runElevated": "<true false>",
328
+
"sha256Checksum": "<sha256 checksum>"
301
329
},
302
330
{
303
331
"type": "PowerShell",
304
332
"name": "<name>",
305
333
"inline": "<PowerShell syntax to run>",
306
-
"valid_exit_codes": "<exit code>"
334
+
"valid_exit_codes": "<exit code>",
335
+
"runElevated": "<true or false>"
307
336
}
308
337
],
309
338
```
@@ -316,6 +345,10 @@ Customize properties:
316
345
-**scriptUri** - URI to the location of the PowerShell script file.
317
346
-**inline** – Inline commands to be run, separated by commas.
318
347
-**valid_exit_codes** – Optional, valid codes that can be returned from the script/inline command, this will avoid reported failure of the script/inline command.
348
+
-**runElevated** – Optional, boolean, support for running commands and scripts with elevated permissions.
349
+
-**sha256Checksum** - Value of sha256 checksum of the file, you generate this locally, and then Image Builder will checksum and validate.
350
+
* To generate the sha256Checksum, using a PowerShell on Windows [Get-Hash](https://docs.microsoft.com/powershell/module/microsoft.powershell.utility/get-filehash?view=powershell-6)
351
+
319
352
320
353
### File customizer
321
354
@@ -327,7 +360,8 @@ The File customizer lets image builder download a file from a GitHub or Azure st
327
360
"type": "File",
328
361
"name": "<name>",
329
362
"sourceUri": "<source location>",
330
-
"destination": "<destination>"
363
+
"destination": "<destination>",
364
+
"sha256Checksum": "<sha256 checksum>"
331
365
}
332
366
]
333
367
```
@@ -395,8 +429,39 @@ Azure Image Builder supports three distribution targets:
395
429
396
430
You can distribute an image to both of the target types in the same configuration, please see [examples](https://github.com/danielsollondon/azvmimagebuilder/blob/7f3d8c01eb3bf960d8b6df20ecd5c244988d13b6/armTemplates/azplatform_image_deploy_sigmdi.json#L80).
397
431
398
-
Because you can have more than one target to distribute to, Image Builder maintains a state for every distribution target that can be accessed by querying the `runOutputName`. The `runOutputName` is an object you can query post distribution for information about that distribution. For example, you can query the location of the VHD, or regions where the image version was replicated to. This is a property of every distribution target. The `runOutputName` must be unique to each distribution target.
399
-
432
+
Because you can have more than one target to distribute to, Image Builder maintains a state for every distribution target that can be accessed by querying the `runOutputName`. The `runOutputName` is an object you can query post distribution for information about that distribution. For example, you can query the location of the VHD, or regions where the image version was replicated to, or SIG Image version created. This is a property of every distribution target. The `runOutputName` must be unique to each distribution target. Here is an example, this is querying a Shared Image Gallery distribution:
433
+
434
+
```bash
435
+
subscriptionID=<subcriptionID>
436
+
imageResourceGroup=<resourceGroup of image template>
0 commit comments