Skip to content

Commit 2a079e9

Browse files
authored
Update how-to-troubleshoot-environments.md
1 parent f209360 commit 2a079e9

File tree

1 file changed

+20
-19
lines changed

1 file changed

+20
-19
lines changed

articles/machine-learning/how-to-troubleshoot-environments.md

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ Azure Machine Learning environments are an encapsulation of the environment wher
2323
They specify the base docker image, Python packages, and software settings around your training and scoring scripts.
2424
Environments are managed and versioned assets within your Machine Learning workspace that enable reproducible, auditable, and portable machine learning workflows across various compute targets.
2525

26-
## Types of environments
26+
### Types of environments
2727

2828
Environments can broadly be divided into three categories: curated, user-managed, and system-managed.
2929

@@ -40,7 +40,7 @@ System-managed environments are used when you want conda to manage the Python en
4040
A new isolated conda environment is materialized from your conda specification on top of a base Docker image. By default, common properties are added to the derived image.
4141
Note that environment isolation implies that Python dependencies installed in the base image won't be available in the derived image.
4242

43-
## Create and manage environments
43+
### Create and manage environments
4444

4545
You can create and manage environments from clients like AzureML Python SDK, AzureML CLI, AzureML Studio UI, VS code extension.
4646

@@ -52,9 +52,9 @@ It also caches the environments in the Azure Container Registry associated with
5252
Multiple environments with the same definition may result the same image, so the cached image will be reused.
5353
Running a training script remotely requires the creation of a Docker image.
5454

55-
## Reproducibility and vulnerabilities
55+
### Reproducibility and vulnerabilities
5656

57-
### Vulnerabilities
57+
#### *Vulnerabilities*
5858

5959
Vulnerabilities can be addressed by upgrading to a newer version of a dependency or migrating to a different dependency that satisfies security
6060
requirements. Mitigating vulnerabilities is time consuming and costly since it can require refactoring of code and infrastructure. With the prevalence
@@ -66,7 +66,7 @@ There are some ways to decrease the impact of vulnerabilities:
6666
- Compartmentalize your environment so issues can be scoped and fixed in one place.
6767
- Understand flagged vulnerabilities and their relevance to your scenario.
6868

69-
### Vulnerabilities vs Reproducibility
69+
#### *Vulnerabilities vs Reproducibility*
7070

7171
Reproducibility is one of the foundations of software development. While developing production code, a repeated operation must guarantee the same
7272
result. Mitigating vulnerabilities can disrupt reproducibility by changing dependencies.
@@ -102,7 +102,7 @@ automate this process based on triggers from Microsoft Defender, see [Automate r
102102

103103
## **Environment definition problems**
104104

105-
### *Environment name issues*
105+
## *Environment name issues*
106106
### Curated prefix not allowed
107107
<!--issueDescription-->
108108
This issue can happen when the name of your custom environment uses terms reserved only for curated environments. *Curated* environments are environments that Microsoft maintains. *Custom* environments are environments that you create and maintain.
@@ -135,7 +135,7 @@ This issue can happen when the name of your custom environment uses terms reserv
135135

136136
Update your environment name to be 255 characters or less
137137

138-
### *Docker issues*
138+
## *Docker issues*
139139

140140
*Applies to: Azure CLI & Python SDK v1*
141141

@@ -456,7 +456,7 @@ Shorten your Dockerfile to get it under this limit
456456
**Resources**
457457
* See [best practices](https://docs.docker.com/develop/develop-images/dockerfile_best-practices/)
458458

459-
### *Docker build context issues*
459+
## *Docker build context issues*
460460
### Missing Docker build context location
461461
<!--issueDescription-->
462462
**Potential causes:**
@@ -584,7 +584,7 @@ For scenarios in which you're storing your Docker build context in a storage acc
584584
* [Python SDK/Azure CLI v2 sample](https://aka.ms/azureml/environment/create-env-build-context-v2)
585585
* [Understand build context](https://docs.docker.com/develop/develop-images/dockerfile_best-practices/#understand-build-context)
586586

587-
### *Base image issues*
587+
## *Base image issues*
588588
### Base image is deprecated
589589
<!--issueDescription-->
590590
**Potential causes:**
@@ -636,7 +636,7 @@ Include at least one of the following on your specified base image
636636
* Digest
637637
* See [image with immutable identifier](https://aka.ms/azureml/environment/pull-image-by-digest)
638638

639-
### *Environment variable issues*
639+
## *Environment variable issues*
640640
### Misplaced runtime variables
641641
<!--issueDescription-->
642642
**Potential causes:**
@@ -652,7 +652,7 @@ Include at least one of the following on your specified base image
652652

653653
Use the `environment_variables` attribute on the [RunConfiguration object](https://aka.ms/azureml/environment/environment-variables-on-run-config) instead
654654

655-
### *Python issues*
655+
## *Python issues*
656656
### Python section missing
657657
<!--issueDescription-->
658658
**Potential causes:**
@@ -797,7 +797,7 @@ channels:
797797
**Resources**
798798
* See [conda package pinning](https://aka.ms/azureml/environment/how-to-pin-conda-packages)
799799
800-
### *Conda issues*
800+
## *Conda issues*
801801
### Missing conda dependencies
802802
<!--issueDescription-->
803803
**Potential causes:**
@@ -916,7 +916,7 @@ environment definition
916916
version of a package on subsequent builds of an environment. This behavior can lead to unexpected errors
917917
- See [conda package pinning](https://aka.ms/azureml/environment/how-to-pin-conda-packages)
918918

919-
### *Pip issues*
919+
## *Pip issues*
920920
### Pip not specified
921921
- For reproducibility, pip should be specified as a dependency in your conda specification, and it should be pinned
922922
- See [how to set a conda dependency](https://aka.ms/azureml/environment/add-conda-package-v1)
@@ -930,18 +930,19 @@ image builds on the environment
930930
- See [conda package pinning](https://aka.ms/azureml/environment/how-to-pin-conda-packages)
931931
- See [how to set pip as a dependency](https://aka.ms/azureml/environment/add-conda-package-v1)
932932

933-
### *Deprecated environment property issues*
933+
## *Deprecated environment property issues*
934934
### R section is deprecated
935935
- The Azure Machine Learning SDK for R will be deprecated by the end of 2021 to make way for an improved R training and deployment
936936
experience using Azure Machine Learning CLI 2.0
937937
- See the [samples repository](https://aka.ms/azureml/environment/train-r-models-cli-v2) to get started with the edition CLI 2.0.
938938

939939
## **Image build problems**
940940

941-
### *Miscellaneous issues*
941+
## *Miscellaneous issues*
942942
### Build log unavailable
943943
- Build logs are optional and not available for all environments since the image might already exist
944944

945+
## *ACR issues*
945946
### ACR unreachable
946947
<!--issueDescription-->
947948
This issue can happen by failing to access a workspace's associated Azure Container Registry (ACR) resource.
@@ -986,7 +987,7 @@ az ml workspace update --name myworkspace --resource-group myresourcegroup --ima
986987
* [Enable Azure Container Registry (ACR)](https://aka.ms/azureml/environment/acr-private-endpoint)
987988
* [How To Use Environments](https://aka.ms/azureml/environment/how-to-use-environments)
988989

989-
### *Docker pull issues*
990+
## *Docker pull issues*
990991
### Failed to pull Docker image
991992
<!--issueDescription-->
992993
This issue can happen when a Docker image pull fails during an image build.
@@ -1044,7 +1045,7 @@ Assess your workspace set-up. Are you using a virtual network, or are any of the
10441045
If you aren't using a virtual network, or if you've configured it correctly
10451046
* Try rebuilding your image. If the timeout was due to a network issue, the problem might be transient, and a rebuild could fix the problem
10461047

1047-
### *Conda issues during build*
1048+
## *Conda issues during build*
10481049
### Bad spec
10491050
<!--issueDescription-->
10501051
This issue can happen when a package listed in your conda specification is invalid or when a conda command is executed incorrectly.
@@ -1456,7 +1457,7 @@ This issue can happen when there's a failure decoding a character in your conda
14561457
* Failure in running jobs because it will implicitly build the environment in the first step.
14571458
<!--/issueDescription-->
14581459
1459-
### *Pip issues during build*
1460+
## *Pip issues during build*
14601461
### Failed to install packages
14611462
<!--issueDescription-->
14621463
This issue can happen when your image build fails during Python package installation.
@@ -1505,7 +1506,7 @@ pip install --ignore-installed [package]
15051506
15061507
Try creating a separate environment using conda
15071508
1508-
### *Docker push issues*
1509+
## *Docker push issues*
15091510
### Failed to store Docker image
15101511
<!--issueDescription-->
15111512
This issue can happen when a Docker image fails to be stored (pushed) to a container registry.

0 commit comments

Comments
 (0)