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
Learn how to create a [compute instance](concept-compute-instance.md) in your Azure Machine Learning workspace.
20
+
Learn how to create a [compute instance](concept-compute-instance.md) in your Azure Machine Learning workspace.
21
21
22
22
Use a compute instance as your fully configured and managed development environment in the cloud. For development and testing, you can also use the instance as a [training compute target](concept-compute-target.md#training-compute-targets). A compute instance can run multiple jobs in parallel and has a job queue. As a development environment, a compute instance can't be shared with other users in your workspace.
23
23
@@ -48,7 +48,7 @@ Choose the tab for the environment you're using for other prerequisites.
48
48
49
49
# [Studio](#tab/azure-studio)
50
50
51
-
* No extra prerequisites.
51
+
* No extra prerequisites.
52
52
53
53
# [Studio (preview)](#tab/azure-studio-preview)
54
54
@@ -62,11 +62,11 @@ Choose the tab for the environment you're using for other prerequisites.
62
62
63
63
**Time estimate**: Approximately 5 minutes.
64
64
65
-
Creating a compute instance is a one time process for your workspace. You can reuse the compute as a development workstation or as a compute target for training. You can have multiple compute instances attached to your workspace.
65
+
Creating a compute instance is a one time process for your workspace. You can reuse the compute as a development workstation or as a compute target for training. You can have multiple compute instances attached to your workspace.
66
66
67
67
The dedicated cores per region per VM family quota and total regional quota, which applies to compute instance creation, is unified and shared with Azure Machine Learning training compute cluster quota. Stopping the compute instance doesn't release quota to ensure you are able to restart the compute instance. It isn't possible to change the virtual machine size of compute instance once it's created.
68
68
69
-
The fastest way to create a compute instance is to follow the [Create resources you need to get started](quickstart-create-resources.md).
69
+
The fastest way to create a compute instance is to follow the [Create resources you need to get started](quickstart-create-resources.md).
70
70
71
71
Or use the following examples to create a compute instance with more options:
72
72
@@ -100,7 +100,7 @@ Where the file *create-instance.yml* is:
100
100
1. Under __Manage__, select __Compute__.
101
101
1. Select **Compute instance** at the top.
102
102
1. If you have no compute instances, select **Create** in the middle of the page.
1. If you see a list of compute resources, select **+New** above the list.
@@ -127,18 +127,18 @@ Where the file *create-instance.yml* is:
127
127
128
128
* If you're using an __Azure Virtual Network__, specify the **Resource group**, **Virtual network**, and **Subnet** to create the compute instance inside an Azure Virtual Network. You can also select __No public IP__ to prevent the creation of a public IP address, which requires a private link workspace. You must also satisfy these [network requirements](./how-to-secure-training-vnet.md) for virtual network setup.
129
129
130
-
* If you're using an Azure Machine Learning __managed virtual network__, the compute instance is created inside the managed virtual network. You can also select __No public IP__ to prevent the creation of a public IP address. For more information, see [managed compute with a managed network](./how-to-managed-network-compute.md).
130
+
* If you're using an Azure Machine Learning __managed virtual network__, the compute instance is created inside the managed virtual network. You can also select __No public IP__ to prevent the creation of a public IP address. For more information, see [managed compute with a managed network](./how-to-managed-network-compute.md).
131
131
132
132
* Assign the computer to another user. For more about assigning to other users, see [Create on behalf of](#create-on-behalf-of).
133
133
* Provision with a setup script - for more information about how to create and use a setup script, see [Customize the compute instance with a script](how-to-customize-compute-instance.md).
134
-
134
+
135
135
# [Studio (preview)](#tab/azure-studio-preview)
136
136
137
137
1. Navigate to [Azure Machine Learning studio](https://ml.azure.com).
138
138
1. Under __Manage__, select __Compute__.
139
139
1. Select **Compute instance** at the top.
140
140
1. If you have no compute instances, select **Create** in the middle of the page.
141
-
141
+
142
142
:::image type="content" source="media/how-to-create-attach-studio/create-compute-target.png" alt-text="Screenshot shows create in the middle of the page.":::
143
143
144
144
1. If you see a list of compute resources, select **+New** above the list.
@@ -166,7 +166,7 @@ Where the file *create-instance.yml* is:
166
166
167
167
* If you're using an __Azure Virtual Network__, specify the **Resource group**, **Virtual network**, and **Subnet** to create the compute instance inside an Azure Virtual Network. You can also select __No public IP__ to prevent the creation of a public IP address, which requires a private link workspace. You must also satisfy these [network requirements](./how-to-secure-training-vnet.md) for virtual network setup.
168
168
169
-
* If you're using an Azure Machine Learning __managed virtual network__, the compute instance is created inside the managed virtual network. You can also select __No public IP__ to prevent the creation of a public IP address. For more information, see [managed compute with a managed network](./how-to-managed-network-compute.md).
169
+
* If you're using an Azure Machine Learning __managed virtual network__, the compute instance is created inside the managed virtual network. You can also select __No public IP__ to prevent the creation of a public IP address. For more information, see [managed compute with a managed network](./how-to-managed-network-compute.md).
170
170
* Allow root access. (preview)
171
171
172
172
1. Select **Applications** if you want to add custom applications to use on your compute instance, such as RStudio or Posit Workbench. See [Add custom applications such as RStudio or Posit Workbench](#add-custom-applications-such-as-rstudio-or-posit-workbench).
@@ -187,10 +187,10 @@ A compute instance is considered inactive if the below conditions are met:
187
187
* No active Jupyter terminal sessions
188
188
* No active Azure Machine Learning runs or experiments
189
189
* No SSH connections
190
-
* No VS Code connections; you must close your VS Code connection for your compute instance to be considered inactive. Sessions are autoterminated if VS Code detects no activity for 3 hours.
190
+
* No VS Code connections; you must close your VS Code connection for your compute instance to be considered inactive. Sessions are autoterminated if VS Code detects no activity for 3 hours.
191
191
* No custom applications are running on the compute
192
192
193
-
A compute instance won't be considered idle if any custom application is running. There are also some basic bounds around inactivity time periods; compute instance must be inactive for a minimum of 15 mins and a maximum of three days.
193
+
A compute instance won't be considered idle if any custom application is running. There are also some basic bounds around inactivity time periods; compute instance must be inactive for a minimum of 15 mins and a maximum of three days.
194
194
195
195
Also, if a compute instance has already been idle for a certain amount of time, if idle shutdown settings are updated to an amount of time shorter than the current idle duration, the idle time clock is reset to 0. For example, if the compute instance has already been idle for 20 minutes, and the shutdown settings are updated to 15 minutes, the idle time clock is reset to 0.
196
196
@@ -227,12 +227,12 @@ You can't change the idle time of an existing compute instance with the CLI.
227
227
228
228
* When creating a new compute instance:
229
229
230
-
1. Select **Advanced** after completing required settings.
230
+
1. Select **Advanced** after completing required settings.
231
231
1. Select **Enable idle shutdown** to enable or disable.
@@ -369,7 +369,7 @@ Once the compute instance is created, you can view, edit, or add new schedules f
369
369
# [Studio (preview)](#tab/azure-studio-preview)
370
370
371
371
1. [Fill out the form](?tabs=azure-studio-preview#create).
372
-
1. Select **Next** to advance to **Scheduling** after completing required settings.
372
+
1. Select **Next** to advance to **Scheduling** after completing required settings.
373
373
1. Select **Add schedule** to add a new schedule.
374
374
375
375
:::image type="content" source="media/how-to-create-compute-instance/add-schedule-preview.png" alt-text="Screenshot: Add schedule in advanced settings.":::
@@ -425,20 +425,20 @@ Then use either cron or LogicApps expressions to define the schedule that starts
425
425
"action": "Start",
426
426
"status": "Enabled"
427
427
},
428
-
{
428
+
{
429
429
"triggerType": "Recurrence",
430
430
"recurrence": {
431
431
"frequency": "Day",
432
432
"interval": 1,
433
433
"timeZone": "UTC",
434
-
"schedule": {
434
+
"schedule": {
435
435
"hours": [17],
436
-
"minutes": [0]
436
+
"minutes": [0]
437
437
}
438
-
},
438
+
},
439
439
"action": "Stop",
440
440
"status": "Enabled"
441
-
}
441
+
}
442
442
]
443
443
}
444
444
}
@@ -510,7 +510,7 @@ Following is a sample policy to default a shutdown schedule at 10 PM PST.
510
510
]
511
511
}
512
512
}
513
-
}
513
+
}
514
514
```
515
515
516
516
## Create on behalf of
@@ -523,7 +523,7 @@ As an administrator, you can create a compute instance on behalf of a data scien
523
523
524
524
## Assign managed identity
525
525
526
-
You can assign a system- or user-assigned [managed identity](../active-directory/managed-identities-azure-resources/overview.md) to a compute instance, to authenticate against other Azure resources such as storage. Using managed identities for authentication helps improve workspace security and management. For example, you can allow users to access training data only when logged in to a compute instance. Or use a common user-assigned managed identity to permit access to a specific storage account.
526
+
You can assign a system- or user-assigned [managed identity](../active-directory/managed-identities-azure-resources/overview.md) to a compute instance, to authenticate against other Azure resources such as storage. Using managed identities for authentication helps improve workspace security and management. For example, you can allow users to access training data only when logged in to a compute instance. Or use a common user-assigned managed identity to permit access to a specific storage account.
527
527
528
528
# [Python SDK](#tab/python)
529
529
@@ -570,7 +570,7 @@ name: myinstance
570
570
type: computeinstance
571
571
identity:
572
572
type: user_assigned
573
-
user_assigned_identities:
573
+
user_assigned_identities:
574
574
- resource_id: identity_resource_id
575
575
```
576
576
@@ -599,7 +599,7 @@ You can create compute instance with managed identity from Azure Machine Learnin
599
599
Once the managed identity is created, grant the managed identity at least Storage Blob Data Reader role on the storage account of the datastore, see [Accessing storage services](how-to-identity-based-service-authentication.md?tabs=cli#accessing-storage-services). Then, when you work on the compute instance, the managed identity is used automatically to authenticate against datastores.
600
600
601
601
> [!NOTE]
602
-
> The name of the created system managed identity will be in the format /workspace-name/computes/compute-instance-name in your Azure Active Directory.
602
+
> The name of the created system managed identity will be in the format /workspace-name/computes/compute-instance-name in your Azure Active Directory.
603
603
604
604
You can also use the managed identity manually to authenticate against other Azure resources. The following example shows how to use it to get an Azure Resource Manager access token:
To use Azure CLI with the managed identity for authentication, specify the identity client ID as the username when logging in:
618
+
To use Azure CLI with the managed identity for authentication, specify the identity client ID as the username when logging in:
619
619
620
620
```azurecli
621
621
az login --identity --username $DEFAULT_IDENTITY_CLIENT_ID
@@ -626,7 +626,7 @@ az login --identity --username $DEFAULT_IDENTITY_CLIENT_ID
626
626
627
627
## Enable SSH access
628
628
629
-
SSH access is disabled by default. SSH access can't be enabled or disabled after creation. Make sure to enable access if you plan to debug interactively with [VS Code Remote](how-to-set-up-vs-code-remote.md).
629
+
SSH access is disabled by default. SSH access can't be enabled or disabled after creation. Make sure to enable access if you plan to debug interactively with [VS Code Remote](how-to-set-up-vs-code-remote.md).
@@ -681,7 +681,7 @@ Use either Studio or Studio (preview) to see how to set up applications.
681
681
682
682
1. Fill out the form to [create a new compute instance](?tabs=azure-studio-preview#create)
683
683
1. Select **Applications**
684
-
1. Select **Add application**
684
+
1. Select **Add application**
685
685
686
686
:::image type="content" source="media/how-to-create-compute-instance/custom-service-setup-preview.png" alt-text="Screenshot showing Custom Service Setup.":::
687
687
@@ -692,46 +692,46 @@ Use either Studio or Studio (preview) to see how to set up applications.
692
692
RStudio is one of the most popular IDEs among R developers for ML and data science projects. You can easily set up Posit Workbench, which provides access to RStudio along with other development tools, to run on your compute instance, using your own Posit license, and access the rich feature set that Posit Workbench offers
693
693
694
694
1. Follow the steps listed above to **Add application** when creating your compute instance.
695
-
1. Select **Posit Workbench (bring your own license)** in the **Application** dropdown and enter your Posit Workbench license key in the **License key** field. You can get your Posit Workbench license or trial license [from posit](https://posit.co).
695
+
1. Select **Posit Workbench (bring your own license)** in the **Application** dropdown and enter your Posit Workbench license key in the **License key** field. You can get your Posit Workbench license or trial license [from posit](https://posit.co).
696
696
1. Select **Create** to add Posit Workbench application to your compute instance.
[!INCLUDE [private link ports](includes/machine-learning-private-link-ports.md)]
701
701
702
702
> [!NOTE]
703
703
> * Support for accessing your workspace file store from Posit Workbench is not yet available.
704
704
> * When accessing multiple instances of Posit Workbench, if you see a "400 Bad Request. Request Header Or Cookie Too Large" error, use a new browser or access from a browser in incognito mode.
705
-
705
+
706
706
707
707
### Setup RStudio (open source)
708
708
709
709
To use RStudio, set up a custom application as follows:
710
710
711
711
1. Follow the previous steps to **Add application** when creating your compute instance.
712
-
1. Select **Custom Application** on the **Application** dropdown
712
+
1. Select **Custom Application** in the **Application** dropdown list.
713
713
1. Configure the **Application name** you would like to use.
714
-
1. Set up the application to run on **Target port** `8787` - the docker image for RStudio open source listed below needs to run on this Target port.
714
+
1. Set up the application to run on **Target port** `8787` - the docker image for RStudio open source listed below needs to run on this Target port.
715
715
716
716
1. Set up the application to be accessed on **Published port** `8787` - you can configure the application to be accessed on a different Published port if you wish.
717
-
1. Point the **Docker image** to `ghcr.io/azure/rocker-rstudio-ml-verse:latest`.
717
+
1. Point the **Docker image** to `ghcr.io/azure/rocker-rstudio-ml-verse:latest`.
718
718
719
719
1. Select **Create** to set up RStudio as a custom application on your compute instance.
720
720
721
721
:::image type="content" source="media/how-to-create-compute-instance/rstudio-open-source.png" alt-text="Screenshot shows form to set up RStudio as a custom application" lightbox="media/how-to-create-compute-instance/rstudio-open-source.png":::
722
722
723
723
[!INCLUDE [private link ports](includes/machine-learning-private-link-ports.md)]
724
-
724
+
725
725
### Setup other custom applications
726
726
727
727
Set up other custom applications on your compute instance by providing the application on a Docker image.
728
728
729
729
1. Follow the previous steps to **Add application** when creating your compute instance.
730
-
1. Select **Custom Application** on the **Application** dropdown.
730
+
1. Select **Custom Application** on the **Application** dropdown.
731
731
1. Configure the **Application name**, the **Target port** you wish to run the application on, the **Published port** you wish to access the application on and the **Docker image** that contains your application.
732
732
1. Optionally, add **Environment variables** you wish to use for your application.
733
-
1. Use **Bind mounts** to add access to the files in your default storage account:
734
-
* Specify **/home/azureuser/cloudfiles** for **Host path**.
733
+
1. Use **Bind mounts** to add access to the files in your default storage account:
734
+
* Specify **/home/azureuser/cloudfiles** for **Host path**.
735
735
* Specify **/home/azureuser/cloudfiles** for the **Container path**.
736
736
* Select **Add** to add this mounting. Because the files are mounted, changes you make to them are available in other compute instances and applications.
737
737
1. Select **Create** to set up the custom application on your compute instance.
0 commit comments