Updates from: 05/02/2023 01:08:55
Service Microsoft Docs article Related commit history on GitHub Change details
active-directory Workday Integration Reference https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/app-provisioning/workday-integration-reference.md
Previously updated : 04/28/2023 Last updated : 05/01/2023
To further secure the connectivity between Azure AD provisioning service and Wor
1. Copy all IP address ranges listed within the element *addressPrefixes* and use the range to build your IP address list. 1. Sign in to Workday admin portal. 1. Access the **Maintain IP Ranges** task to create a new IP range for Azure data centers. Specify the IP ranges (using CIDR notation) as a comma-separated list.
-1. Access the **Manage Authentication Policies** task to create a new authentication policy. In the authentication policy, use the authentication allowlist to specify the Azure AD IP range and the security group that will be allowed access from this IP range. Save the changes.
+1. Access the **Manage Authentication Policies** task to create a new authentication policy. In the authentication policy, use the authentication allowlist to specify the Azure AD IP range and the security group that is allowed access from this IP range. Save the changes.
1. Access the **Activate All Pending Authentication Policy Changes** task to confirm changes. ### Limiting access to worker data in Workday using constrained security groups
-The default steps to [configure the Workday integration system user](../saas-apps/workday-inbound-tutorial.md#configure-integration-system-user-in-workday) grants access to retrieve all users in your Workday tenant. In certain integration scenarios, you may want to limit the access, so that users belonging only to certain supervisory organizations are returned by the Get_Workers API call and processed by the Workday Azure AD connector.
+The default steps to [configure the Workday integration system user](../saas-apps/workday-inbound-tutorial.md#configure-integration-system-user-in-workday) grants access to retrieve all users in your Workday tenant. In certain integration scenarios, you may want to limit access. For example, only return users in certain supervisory organizations from the `Get_Workers` API call.
You can limit access by working with your Workday admin and configuring constrained integration system security groups. For more information about Workday, see [Workday community](https://community.workday.com/forums/customer-questions/620393) (*Workday Community access required for this article*).
To test connectivity to Workday, Azure AD sends the following *Get_Workers* Work
```xml <!-- Test connection query tries to retrieve one record from the first page --> <!-- Replace version with Workday Web Services version present in your connection URL -->
-<!-- Replace timestamps below with the UTC time corresponding to the test connection event -->
+<!-- Replace timestamps with the UTC time corresponding to the test connection event -->
<Get_Workers_Request p1:version="v21.1" xmlns:p1="urn:com.workday/bsvc" xmlns="urn:com.workday/bsvc"> <p1:Request_Criteria> <p1:Transaction_Log_Criteria_Data>
Azure AD sends the following *Get_Workers* Workday Web Services request to retri
```xml <!-- Workday full sync query --> <!-- Replace version with Workday Web Services version present in your connection URL -->
-<!-- Replace timestamps below with the UTC time corresponding to full sync run -->
+<!-- Replace timestamps with the UTC time corresponding to full sync run -->
<!-- Count specifies the number of records to return in each page --> <!-- Response_Group flags derived from provisioning attribute mapping -->
The following *Get_Workers* request queries for manual updates that happened bet
```xml <!-- Workday incremental sync query for manual updates --> <!-- Replace version with Workday Web Services version present in your connection URL -->
-<!-- Replace timestamps below with the UTC time corresponding to last execution and current execution time -->
+<!-- Replace timestamps with the UTC time corresponding to last execution and current execution time -->
<!-- Count specifies the number of records to return in each page --> <!-- Response_Group flags derived from provisioning attribute mapping -->
The following *Get_Workers* request queries for effective-dated updates that hap
```xml <!-- Workday incremental sync query for effective-dated updates --> <!-- Replace version with Workday Web Services version present in your connection URL -->
-<!-- Replace timestamps below with the UTC time corresponding to last execution and current execution time -->
+<!-- Replace timestamps with the UTC time corresponding to last execution and current execution time -->
<!-- Count specifies the number of records to return in each page --> <!-- Response_Group flags derived from provisioning attribute mapping -->
If any of the above queries returns a future-dated hire, then the following *Get
```xml <!-- Workday incremental sync query to get new hire data effective as on hire date/first day of work --> <!-- Replace version with Workday Web Services version present in your connection URL -->
-<!-- Replace timestamps below hire date/first day of work -->
+<!-- Replace timestamps hire date/first day of work -->
<!-- Count specifies the number of records to return in each page --> <!-- Response_Group flags derived from provisioning attribute mapping -->
If any of the above queries returns a future-dated hire, then the following *Get
The *Get_Workers* API can return different data sets associated with a worker. Depending on the [XPATH API expressions](workday-attribute-reference.md) configured in the provisioning schema, Azure AD provisioning service determines which data sets to retrieve from Workday. Accordingly, the *Response_Group* flags are set in the *Get_Workers* request.
-The table below provides guidance on mapping configuration to use to retrieve a specific data set.
+The table provides guidance on mapping configuration to use to retrieve a specific data set.
| \# | Workday Entity | Included by default | XPATH pattern to specify in mapping to fetch nondefault entities | |-|--||-|
-| 1 | Personal Data | Yes | `wd:Worker_Data/wd:Personal_Data` |
-| 2 | Employment Data | Yes | `wd:Worker_Data/wd:Employment_Data` |
-| 3 | Additional Job Data | Yes | `wd:Worker_Data/wd:Employment_Data/wd:Worker_Job_Data[@wd:Primary_Job=0]`|
-| 4 | Organization Data | Yes | `wd:Worker_Data/wd:Organization_Data` |
-| 5 | Management Chain Data | Yes | `wd:Worker_Data/wd:Management_Chain_Data` |
-| 6 | Supervisory Organization | Yes | `SUPERVISORY` |
-| 7 | Company | Yes | `COMPANY` |
-| 8 | Business Unit | No | `BUSINESS_UNIT` |
-| 9 | Business Unit Hierarchy | No | `BUSINESS_UNIT_HIERARCHY` |
-| 10 | Company Hierarchy | No | `COMPANY_HIERARCHY` |
-| 11 | Cost Center | No | `COST_CENTER` |
-| 12 | Cost Center Hierarchy | No | `COST_CENTER_HIERARCHY` |
-| 13 | Fund | No | `FUND` |
-| 14 | Fund Hierarchy | No | `FUND_HIERARCHY` |
-| 15 | Gift | No | `GIFT` |
-| 16 | Gift Hierarchy | No | `GIFT_HIERARCHY` |
-| 17 | Grant | No | `GRANT` |
-| 18 | Grant Hierarchy | No | `GRANT_HIERARCHY` |
-| 19 | Business Site Hierarchy | No | `BUSINESS_SITE_HIERARCHY` |
-| 20 | Matrix Organization | No | `MATRIX` |
-| 21 | Pay Group | No | `PAY_GROUP` |
-| 22 | Programs | No | `PROGRAMS` |
-| 23 | Program Hierarchy | No | `PROGRAM_HIERARCHY` |
-| 24 | Region | No | `REGION_HIERARCHY` |
-| 25 | Location Hierarchy | No | `LOCATION_HIERARCHY` |
-| 26 | Account Provisioning Data | No | `wd:Worker_Data/wd:Account_Provisioning_Data` |
-| 27 | Background Check Data | No | `wd:Worker_Data/wd:Background_Check_Data` |
-| 28 | Benefit Eligibility Data | No | `wd:Worker_Data/wd:Benefit_Eligibility_Data` |
-| 29 | Benefit Enrollment Data | No | `wd:Worker_Data/wd:Benefit_Enrollment_Data` |
-| 30 | Career Data | No | `wd:Worker_Data/wd:Career_Data` |
-| 31 | Compensation Data | No | `wd:Worker_Data/wd:Compensation_Data` |
-| 32 | Contingent Worker Tax Authority Data | No | `wd:Worker_Data/wd:Contingent_Worker_Tax_Authority_Form_Type_Data` |
-| 33 | Development Item Data | No | `wd:Worker_Data/wd:Development_Item_Data` |
-| 34 | Employee Contracts Data | No | `wd:Worker_Data/wd:Employee_Contracts_Data` |
-| 35 | Employee Review Data | No | `wd:Worker_Data/wd:Employee_Review_Data` |
-| 36 | Feedback Received Data | No | `wd:Worker_Data/wd:Feedback_Received_Data` |
-| 37 | Worker Goal Data | No | `wd:Worker_Data/wd:Worker_Goal_Data` |
-| 38 | Photo Data | No | `wd:Worker_Data/wd:Photo_Data` |
-| 39 | Qualification Data | No | `wd:Worker_Data/wd:Qualification_Data` |
-| 40 | Related Persons Data | No | `wd:Worker_Data/wd:Related_Persons_Data` |
-| 41 | Role Data | No | `wd:Worker_Data/wd:Role_Data` |
-| 42 | Skill Data | No | `wd:Worker_Data/wd:Skill_Data` |
-| 43 | Succession Profile Data | No | `wd:Worker_Data/wd:Succession_Profile_Data` |
-| 44 | Talent Assessment Data | No | `wd:Worker_Data/wd:Talent_Assessment_Data` |
-| 45 | User Account Data | No | `wd:Worker_Data/wd:User_Account_Data` |
-| 46 | Worker Document Data | No | `wd:Worker_Data/wd:Worker_Document_Data` |
+| 1 | `Personal Data` | Yes | `wd:Worker_Data/wd:Personal_Data` |
+| 2 | `Employment Data` | Yes | `wd:Worker_Data/wd:Employment_Data` |
+| 3 | `Additional Job Data` | Yes | `wd:Worker_Data/wd:Employment_Data/wd:Worker_Job_Data[@wd:Primary_Job=0]`|
+| 4 | `Organization Data` | Yes | `wd:Worker_Data/wd:Organization_Data` |
+| 5 | `Management Chain Data` | Yes | `wd:Worker_Data/wd:Management_Chain_Data` |
+| 6 | `Supervisory Organization` | Yes | `SUPERVISORY` |
+| 7 | `Company` | Yes | `COMPANY` |
+| 8 | `Business Unit` | No | `BUSINESS_UNIT` |
+| 9 | `Business Unit Hierarchy` | No | `BUSINESS_UNIT_HIERARCHY` |
+| 10 | `Company Hierarchy` | No | `COMPANY_HIERARCHY` |
+| 11 | `Cost Center` | No | `COST_CENTER` |
+| 12 | `Cost Center Hierarchy` | No | `COST_CENTER_HIERARCHY` |
+| 13 | `Fund` | No | `FUND` |
+| 14 | `Fund Hierarchy` | No | `FUND_HIERARCHY` |
+| 15 | `Gift` | No | `GIFT` |
+| 16 | `Gift Hierarchy` | No | `GIFT_HIERARCHY` |
+| 17 | `Grant` | No | `GRANT` |
+| 18 | `Grant Hierarchy` | No | `GRANT_HIERARCHY` |
+| 19 | `Business Site Hierarchy` | No | `BUSINESS_SITE_HIERARCHY` |
+| 20 | `Matrix Organization` | No | `MATRIX` |
+| 21 | `Pay Group` | No | `PAY_GROUP` |
+| 22 | `Programs` | No | `PROGRAMS` |
+| 23 | `Program Hierarchy` | No | `PROGRAM_HIERARCHY` |
+| 24 | `Region` | No | `REGION_HIERARCHY` |
+| 25 | `Location Hierarchy` | No | `LOCATION_HIERARCHY` |
+| 26 | `Account Provisioning Data` | No | `wd:Worker_Data/wd:Account_Provisioning_Data` |
+| 27 | `Background Check Data` | No | `wd:Worker_Data/wd:Background_Check_Data` |
+| 28 | `Benefit Eligibility Data` | No | `wd:Worker_Data/wd:Benefit_Eligibility_Data` |
+| 29 | `Benefit Enrollment Data` | No | `wd:Worker_Data/wd:Benefit_Enrollment_Data` |
+| 30 | `Career Data` | No | `wd:Worker_Data/wd:Career_Data` |
+| 31 | `Compensation Data` | No | `wd:Worker_Data/wd:Compensation_Data` |
+| 32 | `Contingent Worker Tax Authority Data` | No | `wd:Worker_Data/wd:Contingent_Worker_Tax_Authority_Form_Type_Data` |
+| 33 | `Development Item Data` | No | `wd:Worker_Data/wd:Development_Item_Data` |
+| 34 | `Employee Contracts Data` | No | `wd:Worker_Data/wd:Employee_Contracts_Data` |
+| 35 | `Employee Review Data` | No | `wd:Worker_Data/wd:Employee_Review_Data` |
+| 36 | `Feedback Received Data` | No | `wd:Worker_Data/wd:Feedback_Received_Data` |
+| 37 | `Worker Goal Data` | No | `wd:Worker_Data/wd:Worker_Goal_Data` |
+| 38 | `Photo Data` | No | `wd:Worker_Data/wd:Photo_Data` |
+| 39 | `Qualification Data` | No | `wd:Worker_Data/wd:Qualification_Data` |
+| 40 | `Related Persons Data` | No | `wd:Worker_Data/wd:Related_Persons_Data` |
+| 41 | `Role Data` | No | `wd:Worker_Data/wd:Role_Data` |
+| 42 | `Skill Data` | No | `wd:Worker_Data/wd:Skill_Data` |
+| 43 | `Succession Profile Data` | No | `wd:Worker_Data/wd:Succession_Profile_Data` |
+| 44 | `Talent Assessment Data` | No | `wd:Worker_Data/wd:Talent_Assessment_Data` |
+| 45 | `User Account Data` | No | `wd:Worker_Data/wd:User_Account_Data` |
+| 46 | `Worker Document Data` | No | `wd:Worker_Data/wd:Worker_Document_Data` |
>[!NOTE] >Each Workday entity listed in the table is protected by a **Domain Security Policy** in Workday. If you are unable to retrieve any attribute associated with the entity after setting the right XPATH, check with your Workday admin to ensure that the appropriate domain security policy is configured for the integration system user associated with the provisioning app. For example, to retrieve *Skill data*, *Get* access is required on the Workday domain *Worker Data: Skills and Experience*.
The above data sets aren't included by default.
To retrieve these data sets: 1. Sign in to the Azure portal and open your Workday to AD/Azure AD user provisioning app. 1. In the Provisioning blade, edit the mappings and open the Workday attribute list from the advanced section.
-1. Add the following attributes definitions and mark them as "Required". These attributes won't be mapped to any attribute in AD or Azure AD. They just serve as signals to the connector to retrieve the Cost Center, Cost Center Hierarchy and Pay Group information.
+1. Add the following attributes definitions and mark them as "Required". These attributes aren't mapped to any attribute in AD or Azure AD. They serve as signals to the connector to retrieve the Cost Center, Cost Center Hierarchy and Pay Group information.
> [!div class="mx-tdCol2BreakAll"] >| Attribute Name | XPATH API expression |
To retrieve these data sets:
>| CostCenterFlag | wd:Worker/wd:Worker_Data/wd:Organization_Data/wd:Worker_Organization_Data[wd:Organization_Data/wd:Organization_Type_Reference/wd:ID[@wd:type='Organization_Type_ID']='COST_CENTER']/wd:Organization_Data/wd:Organization_Code/text() | >| PayGroupFlag | wd:Worker/wd:Worker_Data/wd:Organization_Data/wd:Worker_Organization_Data[wd:Organization_Data/wd:Organization_Type_Reference/wd:ID[@wd:type='Organization_Type_ID']='PAY_GROUP']/wd:Organization_Data/wd:Organization_Reference_ID/text() |
-1. Once the Cost Center and Pay Group data set is available in the *Get_Workers* response, you can use the below XPATH values to retrieve the cost center name, cost center code and pay group.
+1. Once the Cost Center and Pay Group data set is available in the *Get_Workers* response, you can use the XPATH values to retrieve the cost center name, cost center code and pay group.
> [!div class="mx-tdCol2BreakAll"] >| Attribute Name | XPATH API expression |
This section covers how you can customize the provisioning app for the following
This section describes the Azure AD provisioning service support for scenarios when a worker converts from full-time employee (FTE) to contingent worker (CW) or vice versa. Depending on how worker conversions are processed in Workday, there may be different implementation aspects to consider. * [Scenario 1: Backdated conversion from FTE to CW or vice versa](#scenario-1-backdated-conversion-from-fte-to-cw-or-vice-versa)
-* [Scenario 2: Worker employed as CW/FTE today, will change to FTE/CW today](#scenario-2-worker-employed-as-cwfte-today-will-change-to-ftecw-today)
+* [Scenario 2: Worker employed as CW/FTE today, changes to FTE/CW today](#scenario-2-worker-employed-as-cwfte-today-changes-to-ftecw-today)
* [Scenario 3: Worker employed as CW/FTE is terminated, rejoins as FTE/CW after a significant gap](#scenario-3-worker-employed-as-cwfte-is-terminated-rejoins-as-ftecw-after-a-significant-gap) * [Scenario 4: Future-dated conversion, when worker is an active CW/FTE](#scenario-4-future-dated-conversion-when-worker-is-an-active-cwfte) #### Scenario 1: Backdated conversion from FTE to CW or vice versa
-Your HR team may backdate a worker conversion transaction in Workday for valid business reasons, such as payroll processing, budget compliance, legal requirements or benefits management. Here's an example to illustrate how provisioning is handled for this scenario.
+Your HR team may backdate a worker conversion transaction in Workday for valid business reasons. Examples include payroll processing, budget compliance, legal requirements and benefits management. Here's an example to illustrate how provisioning is handled for the scenario.
* It's January 15, 2023 and Jane Doe is employed as a contingent worker. HR offers Jane a full-time position. * The terms of Jane's contract change require backdating the transaction so it aligns with the start of the current month. HR initiates a backdated worker conversion transaction Workday on January 15, 2023 with effective date as January 1, 2023. Now there are two worker profiles in Workday for Jane. The CW profile is inactive, while the FTE profile is active.
-* The Azure AD provisioning service will detect this change in the Workday transaction log on January 15, 2023 and automatically provision attributes of the new FTE profile in the next sync cycle.
+* The Azure AD provisioning service detects this change in the Workday transaction log on January 15, 2023. The service automatically provision attributes of the new FTE profile in the next sync cycle.
* No changes are required in the provisioning app configuration to handle this scenario.
-#### Scenario 2: Worker employed as CW/FTE today, will change to FTE/CW today
-This scenario is similar to the above scenario, except that instead of backdating the transaction, HR performs a worker conversion that is effective immediately. The Azure AD provisioning service will detect this change in the Workday transaction log and automatically provision attributes associated with active FTE profile in the next sync cycle. No changes are required in the provisioning app configuration to handle this scenario.
+#### Scenario 2: Worker employed as CW/FTE today, changes to FTE/CW today
+This scenario is similar to the above scenario, except that instead of backdating the transaction, HR performs a worker conversion that is effective immediately. The Azure AD provisioning service detects this change in the Workday transaction log. In the next sync cycle, the service automatically provisions any associated attributes with an active FTE profile. No changes are required in the provisioning app configuration to handle this scenario.
#### Scenario 3: Worker employed as CW/FTE is terminated, rejoins as FTE/CW after a significant gap It's common for workers to start work at a company as a contingent worker, leave the company and then rejoin after several months as a full-time employee. Here's an example to illustrate how provisioning is handled for this scenario.
Sometimes, a worker may already be an active contingent worker, when HR initiate
* It's January 1, 2023 and John Smith starts work at as a contingent worker. As there's no AD account associated with John's *WorkerID* (matching attribute), the provisioning service creates a new AD account and links John's contingent worker *WID (WorkdayID)* to John's AD account. * On January 15, HR initiates a transaction to convert John from contingent worker to full-time employee effective February 1, 2023.
-* Since Azure AD provisioning service automatically processes future-dated hires, it will process John's new full-time employee worker profile on January 15, and update John's profile in AD with full-time employment details even though he's still a contingent worker.
+* Since Azure AD provisioning service automatically processes future-dated hires, it processes John's new full-time employee worker profile on January 15, and update John's profile in AD with full-time employment details even though he's still a contingent worker.
* To avoid this behavior and ensure that John's FTE details get provisioned on February 1, 2023, perform the following configuration changes. **Configuration changes**
Sometimes, a worker may already be an active contingent worker, when HR initiate
1. Update the Azure AD provisioning app to read this provisioning group. Refer to instructions here on how to [retrieve the provisioning group](#example-3-retrieving-provisioning-group-assignments) 1. Create a [scoping filter](define-conditional-rules-for-provisioning-user-accounts.md) in Azure AD to exclude worker profiles that are part of this provisioning group. 1. In Workday, implement logic so that when the date of conversion is effective, Workday removes the relevant employee/contingent worker record from the provisioning group in Workday.
- 1. With this configuration, the existing employee/contingent worker record will continue to be effective and the provisioning change will happen only on the day of conversion.
+ 1. With this configuration, the existing employee/contingent worker record continues to be effective and the provisioning changes happen only on the day of conversion.
>[!NOTE]
->During initial full sync, you may notice a behavior where the attribute values associated with the previous inactive worker profile flow to the AD account of converted workers. This is temporary and as full sync progresses, it will eventually be overwritten by attribute values from the active worker profile. Once the full sync is complete and the provisioning job reaches steady state, it will always pick the active worker profile during incremental sync.
+>During initial full sync, you may notice a behavior where the attribute values associated with the previous inactive worker profile flow to the AD account of converted workers. This is temporary and as full sync progresses, it is eventually be overwritten by attribute values from the active worker profile. Once the full sync is complete and the provisioning job reaches steady state, it always picks the active worker profile during incremental sync.
### Retrieving international job assignments and secondary job details
-By default, the Workday connector retrieves attributes associated with the worker's primary job. The connector also supports retrieving *Additional Job Data* associated with international job assignments or secondary jobs.
+By default, the Workday connector retrieves attributes associated with the worker's primary job. The connector also supports retrieving `Additional Job Data` associated with international job assignments or secondary jobs.
-Use the steps below to retrieve attributes associated with international job assignments:
+Use the steps to retrieve attributes associated with international job assignments:
1. Set the Workday connection URL uses Workday Web Service API version 30.0 or above. Accordingly set the [correct XPATH values](workday-attribute-reference.md#xpath-values-for-workday-web-services-wws-api-v30) in your Workday provisioning app. 1. Use the selector `@wd:Primary_Job=0` on the `Worker_Job_Data` node to retrieve the correct attribute.
active-directory Application Proxy Configure Single Sign On With Headers https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/app-proxy/application-proxy-configure-single-sign-on-with-headers.md
Azure Active Directory (Azure AD) Application Proxy natively supports single sig
* **No additional software or changes to your apps** - You can use your existing Application Proxy connectors and it doesn't require any additional software to be installed.
-* **Wide list of attributes and transformations available** - All header values available are based on standard claims that are issued by Azure AD. All attributes and transformations available for [configuring claims for SAML or OIDC applications](../develop/active-directory-saml-claims-customization.md#attributes) are also available to be used as header values.
+* **Wide list of attributes and transformations available** - All header values available are based on standard claims that are issued by Azure AD. All attributes and transformations available for [configuring claims for SAML or OIDC applications](../develop/saml-claims-customization.md#attributes) are also available to be used as header values.
## Pre-requisites Before you get started with single sign-on for header-based authentication apps, make sure your environment is ready with the following settings and configurations:
Before you get started with single sign-on for header-based applications, you sh
3. In Basic Configuration, **Azure Active Directory**, will be selected as the default. 4. Select the edit pencil, in Headers to configure headers to send to the application. 5. Select **Add new header**. Provide a **Name** for the header and select either **Attribute** or **Transformation** and select from the drop-down which header your application needs.
- - To learn more about the list of attribute available, see [Claims Customizations- Attributes](../develop/active-directory-saml-claims-customization.md#attributes).
- - To learn more about the list of transformation available, see [Claims Customizations- Claim Transformations](../develop/active-directory-saml-claims-customization.md#claim-transformations).
+ - To learn more about the list of attribute available, see [Claims Customizations- Attributes](../develop/saml-claims-customization.md#attributes).
+ - To learn more about the list of transformation available, see [Claims Customizations- Claim Transformations](../develop/saml-claims-customization.md#claim-transformations).
- You may also add a **Group Header**, to send all the groups a user is part of, or the groups assigned to the application as a header. To learn more about configuring groups as a value see: [Configure group claims for applications](../hybrid/how-to-connect-fed-group-claims.md#add-group-claims-to-tokens-for-saml-applications-using-sso-configuration). 6. Select Save.
active-directory Location Condition https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/conditional-access/location-condition.md
Multiple Conditional Access policies may prompt users for their GPS location bef
Some IP addresses don't map to a specific country or region. To capture these IP locations, check the box **Include unknown countries/regions** when defining a geographic location. This option allows you to choose if these IP addresses should be included in the named location. Use this setting when the policy using the named location should apply to unknown locations.
+### Define locations
+
+1. Sign in to the **Azure portal** as a Conditional Access Administrator or Security Administrator.
+1. Browse to **Azure Active Directory** > **Security** > **Conditional Access** > **Named locations**.
+1. Choose **New location**.
+1. Give your location a name.
+1. Choose **IP ranges** if you know the specific externally accessible IPv4 address ranges that make up that location or **Countries/Regions**.
+ 1. Provide the **IP ranges** or select the **Countries/Regions** for the location you're specifying.
+ * If you choose Countries/Regions, you can optionally choose to include unknown areas.
+1. Choose **Save**
+ ## Location condition in policy When you configure the location condition, you can distinguish between:
active-directory Active Directory Enterprise App Role Management https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/develop/active-directory-enterprise-app-role-management.md
To delete an existing role, perform the following steps:
## Next steps -- For information about customizing claims, see [Customize claims issued in the SAML token for enterprise applications](active-directory-saml-claims-customization.md).
+- For information about customizing claims, see [Customize claims issued in the SAML token for enterprise applications](saml-claims-customization.md).
active-directory Configure Token Lifetimes https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/develop/configure-token-lifetimes.md
Previously updated : 04/04/2023 Last updated : 05/01/2023
To get started, download the latest [Microsoft Graph PowerShell SDK](/powershell
In the following steps, you'll create a policy that requires users to authenticate less frequently in your web app. This policy sets the lifetime of the access/ID tokens for your web app. ```powershell
+Install-Module Microsoft.Graph
+ Connect-MgGraph -Scopes "Policy.ReadWrite.ApplicationConfiguration","Policy.Read.All","Application.ReadWrite.All" # Create a token lifetime policy
active-directory Jwt Claims Customization https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/develop/jwt-claims-customization.md
+
+ Title: Customize app JSON Web Token (JWT) claims (Preview)
+description: Learn how to customize the claims issued by Microsoft identity platform in the JSON web token (JWT) token for enterprise applications.
+++++++ Last updated : 05/01/2023+++++
+# Customize claims issued in the JSON web token (JWT) for enterprise applications (Preview)
+
+The Microsoft identity platform supports [single sign-on (SSO)](../manage-apps/what-is-single-sign-on.md) with most preintegrated applications in the Azure Active Directory (Azure AD) application gallery and custom applications. When a user authenticates to an application through the Microsoft identity platform using the OIDC protocol, the Microsoft identity platform sends a token to the application. The application validates and uses the token to sign the user in instead of prompting for a username and password.
+
+These JSON Web tokens (JWT) used by OIDC and OAuth applications (preview) contain pieces of information about the user known as *claims*. A claim is information that an identity provider states about a user inside the token they issue for that user. In an [OIDC response](v2-protocols-oidc.md), claims data is typically contained in the ID Token issued by the identity provider in the form of a JWT.
+
+## View or edit claims
+
+To view or edit the claims issued in the JWT to the application, open the application in Azure portal. Then select **Single sign-on** blade in the left-hand menu and open the **Attributes & Claims** section.
++
+An application may need claims customization for various reasons. For example, when an application requires a different set of claim URIs or claim values. Using the **Attributes & Claims** section, you can add or remove a claim for your application. You can also create a custom claim that is specific for an application based on the use case.
+
+The following steps describe how to assign a constant value:
+
+1. In the [Azure portal](https://portal.azure.com/), on the **Attributes & Claims** section, Select **Edit** to edit the claims.
+1. Select the required claim that you want to modify.
+1. Enter the constant value without quotes in the **Source attribute** as per your organization, and then select **Save**.
++
+The Attributes overview displays the constant value.
++
+## Special claims transformations
+
+You can use the following special claims transformations functions.
+
+| Function | Description |
+|-|-|
+| **ExtractMailPrefix()** | Removes the domain suffix from either the email address or the user principal name. This function extracts only the first part of the user name. For example, `joe_smith` instead of `joe_smith@contoso.com`. |
+| **ToLower()** | Converts the characters of the selected attribute into lowercase characters. |
+| **ToUpper()** | Converts the characters of the selected attribute into uppercase characters. |
+
+## Add application-specific claims
+
+To add application-specific claims:
+
+1. In **User Attributes & Claims**, select **Add new claim** to open the **Manage user claims** page.
+1. Enter the **name** of the claims. The value doesn't strictly need to follow a URI pattern. If you need a URI pattern, you can put that in the **Namespace** field.
+1. Select the **Source** where the claim is going to retrieve its value. You can select a user attribute from the source attribute dropdown or apply a transformation to the user attribute before emitting it as a claim.
+
+### Claim transformations
+
+To apply a transformation to a user attribute:
+
+1. In **Manage claim**, select *Transformation* as the claim source to open the **Manage transformation** page.
+1. Select the function from the transformation dropdown. Depending on the function selected, provide parameters and a constant value to evaluate in the transformation.
+1. **Treat source as multivalued** indicates whether the transform is applied to all values or just the first. By default, the first element in a multi-value claim is applied the transformations. When you check this box, it ensures it's applied to all. This checkbox is only enabled for multi-valued attributes. For example, `user.proxyaddresses`.
+1. To apply multiple transformations, select **Add transformation**. You can apply a maximum of two transformations to a claim. For example, you could first extract the email prefix of the `user.mail`. Then, make the string upper case.
+
+ :::image type="content" source="./media/jwt-claims-customization/sso-saml-multiple-claims-transformation.png" alt-text="Screenshot of claims transformation.":::
+
+You can use the following functions to transform claims.
+
+| Function | Description |
+|-|-|
+| **ExtractMailPrefix()** | Removes the domain suffix from either the email address or the user principal name. This function extracts only the first part of the user name. For example, `joe_smith` instead of `joe_smith@contoso.com`. |
+| **Join()** | Creates a new value by joining two attributes. Optionally, you can use a separator between the two attributes. For NameID claim transformation, the Join() function has specific behavior when the transformation input has a domain part. It removes the domain part from input before joining it with the separator and the selected parameter. For example, if the input of the transformation is `joe_smith@contoso.com` and the separator is `@` and the parameter is `fabrikam.com`, this input combination results in `joe_smith@fabrikam.com`. |
+| **ToLowercase()** | Converts the characters of the selected attribute into lowercase characters. |
+| **ToUppercase()** | Converts the characters of the selected attribute into uppercase characters. |
+| **Contains()** | Outputs an attribute or constant if the input matches the specified value. Otherwise, you can specify another output if there's no match. <br/>For example, if you want to emit a claim where the value is the user's email address if it contains the domain `@contoso.com`, otherwise you want to output the user principal name. To perform this function, you configure the following values:<br/>*Parameter 1(input)*: user.email<br/>*Value*: "@contoso.com"<br/>Parameter 2 (output): user.email<br/>Parameter 3 (output if there's no match): user.userprincipalname |
+| **EndWith()** | Outputs an attribute or constant if the input ends with the specified value. Otherwise, you can specify another output if there's no match.<br/>For example, if you want to emit a claim where the value is the user's employee ID if the employee ID ends with "000", otherwise you want to output an extension attribute. To perform this function, you configure the following values:<br/>*Parameter 1(input)*: user.employeeid<br/>*Value*: "000"<br/>Parameter 2 (output): user.employeeid<br/>Parameter 3 (output if there's no match): user.extensionattribute1 |
+| **StartWith()** | Outputs an attribute or constant if the input starts with the specified value. Otherwise, you can specify another output if there's no match.<br/>For example, if you want to emit a claim where the value is the user's employee ID if the country/region starts with "US", otherwise you want to output an extension attribute. To perform this function, you configure the following values:<br/>*Parameter 1(input)*: user.country<br/>*Value*: "US"<br/>Parameter 2 (output): user.employeeid<br/>Parameter 3 (output if there's no match): user.extensionattribute1 |
+| **Extract() - After matching** | Returns the substring after it matches the specified value.<br/>For example, if the input's value is `Finance_BSimon`, the matching value is `Finance_`, then the claim's output is `BSimon`. |
+| **Extract() - Before matching** | Returns the substring until it matches the specified value.<br/>For example, if the input's value is `BSimon_US`, the matching value is `_US`, then the claim's output is `BSimon`. |
+| **Extract() - Between matching** | Returns the substring until it matches the specified value.<br/>For example, if the input's value is `Finance_BSimon_US`, the first matching value is `Finance_`, the second matching value is `_US`, then the claim's output is `BSimon`. |
+| **ExtractAlpha() - Prefix** | Returns the prefix alphabetical part of the string.<br/>For example, if the input's value is `BSimon_123`, then it returns `BSimon`. |
+| **ExtractAlpha() - Suffix** | Returns the suffix alphabetical part of the string.<br/>For example, if the input's value is `123_Simon`, then it returns `Simon`. |
+| **ExtractNumeric() - Prefix** | Returns the prefix numerical part of the string.<br/>For example, if the input's value is `123_BSimon`, then it returns `123`. |
+| **ExtractNumeric() - Suffix** | Returns the suffix numerical part of the string.<br/>For example, if the input's value is `BSimon_123`, then it returns `123`. |
+| **IfEmpty()** | Outputs an attribute or constant if the input is null or empty.<br/>For example, if you want to output an attribute stored in an extension attribute if the employee ID for a given user is empty. To perform this function, configure the following values:<br/>Parameter 1(input): user.employeeid<br/>Parameter 2 (output): user.extensionattribute1<br/>Parameter 3 (output if there's no match): user.employeeid |
+| **IfNotEmpty()** | Outputs an attribute or constant if the input isn't null or empty.<br/>For example, if you want to output an attribute stored in an extension attribute if the employee ID for a given user isn't empty. To perform this function, you configure the following values:<br/>Parameter 1(input): user.employeeid<br/>Parameter 2 (output): user.extensionattribute1 |
+| **Substring() - Fixed Length** (Preview)| Extracts parts of a string claim type, beginning at the character at the specified position, and returns the specified number of characters.<br/>SourceClaim - The claim source of the transform that should be executed.<br/>StartIndex - The zero-based starting character position of a substring in this instance.<br/>Length - The length in characters of the substring.<br/>For example:<br/>sourceClaim - PleaseExtractThisNow<br/>StartIndex - 6<br/>Length - 11<br/>Output: ExtractThis |
+| **Substring() - EndOfString** (Preview) | Extracts parts of a string claim type, beginning at the character at the specified position, and returns the rest of the claim from the specified start index. <br/>SourceClaim - The claim source of the transform.<br/>StartIndex - The zero-based starting character position of a substring in this instance.<br/>For example:<br/>sourceClaim - PleaseExtractThisNow<br/>StartIndex - 6<br/>Output: ExtractThisNow |
+| **RegexReplace()** (Preview) | RegexReplace() transformation accepts as input parameters:<br/>- Parameter 1: a user attribute as regex input<br/>- An option to trust the source as multivalued<br/>- Regex pattern<br/>- Replacement pattern. The replacement pattern may contain static text format along with a reference that points to regex output groups and more input parameters. |
+
+If you need other transformations, submit your idea in the [feedback forum in Azure AD](https://feedback.azure.com/d365community/forum/22920db1-ad25-ec11-b6e6-000d3a4f0789) under the *SaaS application* category.
+
+## Regex-based claims transformation
+
+The following image shows an example of the first level of transformation:
++
+The following table provides information about the first level of transformations. The actions listed in the table correspond to the labels in the previous image. Select **Edit** to open the claims transformation blade.
+
+| Action | Field | Description |
+| :-- | :- | :- |
+| 1 | `Transformation` | Select the **RegexReplace()** option from the **Transformation** options to use the regex-based claims transformation method for claims transformation. |
+| 2 | `Parameter 1` | The input for the regular expression transformation. For example, user.mail that has a user email address such as `admin@fabrikam.com`. |
+| 3 | `Treat source as multivalued` | Some input user attributes can be multi-value user attributes. If the selected user attribute supports multiple values and the user wants to use multiple values for the transformation, they need to select **Treat source as multivalued**. If selected, all values are used for the regex match, otherwise only the first value is used. |
+| 4 | `Regex pattern` | A regular expression that is evaluated against the value of user attribute selected as *Parameter 1*. For example, a regular expression to extract the user alias from the user's email address is represented as `(?'domain'^.*?)(?i)(\@fabrikam\.com)$`. |
+| 5 | `Add additional parameter` | More than one user attribute can be used for the transformation. The values of the attributes would then be merged with regex transformation output. Up to five more parameters are supported. |
+| 6 | `Replacement pattern` | The replacement pattern is the text template, which contains placeholders for regex outcome. All group names must be wrapped inside the curly braces such as {group-name}. Let's say the administration wants to use user alias with some other domain name, for example `xyz.com` and merge country name with it. In this case, the replacement pattern would be `{country}.{domain}@xyz.com`, where `{country}` is the value of input parameter and `{domain}` is the group output from the regular expression evaluation. In such a case, the expected outcome is `US.swmal@xyz.com`. |
+
+The following image shows an example of the second level of transformation:
++
+The following table provides information about the second level of transformations. The actions listed in the table correspond to the labels in the previous image.
+
+| Action | Field | Description |
+| :-- | :- | :- |
+| 1 | `Transformation` | Regex-based claims transformations aren't limited to the first transformation and can be used as the second level transformation as well. Any other transformation method can be used as the first transformation. |
+| 2 | `Parameter 1` | If **RegexReplace()** is selected as a second level transformation, output of first level transformation is used as an input for the second level transformation. To apply the transformation, the second level regex expression should match the output of the first transformation. |
+| 3 | `Regex pattern` | **Regex pattern** is the regular expression for the second level transformation. |
+| 4 | `Parameter input` | User attribute inputs for the second level transformations. |
+| 5 | `Parameter input` | Administrators can delete the selected input parameter if they don't need it anymore. |
+| 6 | `Replacement pattern` | The replacement pattern is the text template, which contains placeholders for regex outcome group name, input parameter group name, and static text value. All group names must be wrapped inside the curly braces such as `{group-name}`. Let's say the administration wants to use user alias with some other domain name, for example `xyz.com` and merge country name with it. In this case, the replacement pattern would be `{country}.{domain}@xyz.com`, where `{country}` is the value of input parameter and `{domain}` is the group output from the regular expression evaluation. In such a case, the expected outcome is `US.swmal@xyz.com`. |
+| 7 | `Test transformation` | The RegexReplace() transformation is evaluated only if the value of the selected user attribute for *Parameter 1* matches with the regular expression provided in the **Regex pattern** textbox. If they don't match, the default claim value is added to the token. To validate regular expression against the input parameter value, a test experience is available within the transform blade. This test experience operates on dummy values only. When more input parameters are used, the name of the parameter is added to the test result instead of the actual value. To access the test section, select **Test transformation**. |
+
+The following image shows an example of testing the transformations:
++
+The following table provides information about testing the transformations. The actions listed in the table correspond to the labels in the previous image.
+
+| Action | Field | Description |
+| :-- | :- | :- |
+| 1 | `Test transformation` | Select the close or (X) button to hide the test section and re-render the **Test transformation** button again on the blade. |
+| 2 | `Test regex input` | Accepts input that is used for the regular expression test evaluation. In case regex-based claims transformation is configured as a second level transformation, provide a value that is the expected output of the first transformation. |
+| 3 | `Run test` | After the test regex input is provided and the **Regex pattern**, **Replacement pattern** and **Input parameters** are configured, the expression can be evaluated by selecting **Run test**. |
+| 4 | `Test transformation result` | If evaluation succeeds, an output of test transformation is rendered against the **Test transformation result** label. |
+| 5 | `Remove transformation` | The second level transformation can be removed by selecting **Remove transformation**. |
+| 6 | `Specify output if no match` | When a regex input value is configured against the *Parameter 1* that doesn't match the **Regular expression**, the transformation is skipped. In such cases, the alternate user attribute can be configured, which is added to the token for the claim by checking **Specify output if no match**. |
+| 7 | `Parameter 3` | If an alternate user attribute needs to be returned when there's no match and **Specify output if no match** is checked, an alternate user attribute can be selected using the dropdown. This dropdown is available against **Parameter 3 (output if no match)**. |
+| 8 | `Summary` | At the bottom of the blade, a full summary of the format is displayed that explains the meaning of the transformation in simple text. |
+| 9 | `Add` | After the configuration settings for the transformation are verified, it can be saved to a claims policy by selecting **Add**. Select **Save** on the **Manage Claim** blade to save the changes. |
+
+RegexReplace() transformation is also available for the group claims transformations.
+
+### Transformation validations
+
+A message provides more information when the following conditions occur after selecting **Add** or **Run test**:
+
+* Input parameters with duplicate user attributes were used.
+* Unused input parameters found. Defined input parameters should have respective usage into the Replacement pattern text.
+* The provided test regex input doesn't match with the provided regular expression.
+* No sources for the groups in the replacement pattern are found.
+
+## Emit claims based on conditions
+
+You can specify the source of a claim based on user type and the group to which the user belongs.
+
+The user type can be:
+
+* **Any** - All users are allowed to access the application.
+* **Members**: Native member of the tenant
+* **All guests**: User moved from an external organization with or without Azure AD.
+* **AAD guests**: Guest user belongs to another organization using Azure AD.
+* **External guests**: Guest user belongs to an external organization that doesn't have Azure AD.
+
+One scenario where the user type is helpful is when the source of a claim is different for a guest and an employee accessing an application. You can specify that if the user is an employee, get the NameID from user.email. If the user is a guest, then the NameID comes from user.extensionattribute1.
+
+To add a claim condition:
+
+1. In **Manage claim**, expand the Claim conditions.
+1. Select the user type.
+1. Select the group(s) to which the user should belong. You can select up to 50 unique groups across all claims for a given application.
+1. Select the **Source** where the claim is going to retrieve its value. You can select a user attribute from the source attribute dropdown or apply a transformation to the user attribute before emitting it as a claim.
+
+The order in which you add the conditions are important. Azure AD first evaluates all conditions with source `Attribute` and then evaluates all conditions with source `Transformation` to decide which value to emit in the claim. Azure AD evaluates conditions with the same source from top to bottom. The claim emits the last value that matches the expression in the claim. Transformations such as `IsNotEmpty` and `Contains` act like restrictions.
+
+For example, Britta Simon is a guest user in the Contoso tenant. Britta belongs to another organization that also uses Azure AD. Given the following configuration for the Fabrikam application, when Britta tries to sign in to Fabrikam, the Microsoft identity platform evaluates the conditions.
+
+First, the Microsoft identity platform verifies whether Britta's user type is **All guests**. Because the type is **All guests**, the Microsoft identity platform assigns the source for the claim to `user.extensionattribute1`. Second, the Microsoft identity platform verifies whether Britta's user type is **AAD guests**. Because the type is **All guests**, the Microsoft identity platform assigns the source for the claim to `user.mail`. Finally, the claim is emitted with a value of `user.mail` for Britta.
++
+As another example, consider when Britta Simon tries to sign in using the following configuration. Azure AD first evaluates all conditions with source `Attribute`. The source for the claim is `user.mail` when Britta's user type is **AAD guests**. Next, Azure AD evaluates the transformations. Because Britta is a guest, `user.extensionattribute1` is the new source for the claim. Because Britta is in **AAD guests**, `user.othermail` is the new source for this claim. Finally, the claim is emitted with a value of `user.othermail` for Britta.
++
+As a final example, consider what happens if Britta has no `user.othermail` configured or it's empty. The claim falls back to `user.extensionattribute1` ignoring the condition entry in both cases.
+
+## Advanced claims options
+
+Configure advanced claims options for OIDC applications to expose the same claim as SAML tokens. Also for applications that intend to use the same claim for both SAML2.0 and OIDC response tokens.
+
+Configure advanced claim options by checking the box under **Advanced Claims Options** in the **Manage claims** blade.
+
+## Next steps
+
+* Learn more about the [claims and tokens used in Azure AD](security-tokens.md).
active-directory Saml Claims Customization https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/develop/saml-claims-customization.md
+
+ Title: Customize SAML token claims
+description: Learn how to customize the claims issued by Microsoft identity platform in the SAML token for enterprise applications.
+++++++ Last updated : 05/01/2023+++++
+# Customize claims issued in the SAML token for enterprise applications
+
+The Microsoft identity platform supports [single sign-on (SSO)](../manage-apps/what-is-single-sign-on.md) with most preintegrated applications in the Azure Active Directory (Azure AD) application gallery and custom applications. When a user authenticates to an application through the Microsoft identity platform using the SAML 2.0 protocol, the Microsoft identity platform sends a token to the application. The application validates and uses the token to sign the user in instead of prompting for a username and password.
+
+These SAML tokens contain pieces of information about the user known as *claims*. A claim is information that an identity provider states about a user inside the token they issue for that user. In a SAML token, claims data is typically contained in the SAML Attribute Statement. The user's unique ID is typically represented in the SAML Subject, which is also referred to as the name identifier (`nameID`).
+
+By default, the Microsoft identity platform issues a SAML token to an application that contains a `NameIdentifier` claim with a value of the user's username (also known as the user principal name) in Azure AD, which can uniquely identify the user. The SAML token also contains other claims that include the user's email address, first name, and last name.
+
+## View or edit claims
+
+To view or edit the claims issued in the SAML token to the application, open the application in Azure portal. Then open the **Attributes & Claims** section.
++
+You might need to edit the claims issued in the SAML token for the following reasons:
+
+* The application requires the `NameIdentifier` or `nameID` claim to be something other than the username (or user principal name) stored in Azure AD.
+* The application has been written to require a different set of claim URIs or claim values.
+
+## Edit nameID
+
+To edit the `nameID` (name identifier value) claim:
+
+1. Open the **Name identifier value** page.
+1. Select the attribute or transformation that you want to apply to the attribute. Optionally, you can specify the format that you want the `nameID` claim to have.
+
+ :::image type="content" source="./media/saml-claims-customization/saml-sso-manage-user-claims.png" alt-text="Screenshot of editing the nameID (name identifier) value in the Azure portal.":::
+
+### NameID format
+
+If the SAML request contains the element `NameIDPolicy` with a specific format, then the Microsoft identity platform honors the format in the request.
+
+If the SAML request doesn't contain an element for `NameIDPolicy`, then the Microsoft identity platform issues the `nameID` with the format you specify. If no format is specified, the Microsoft identity platform uses the default source format associated with the claim source selected. If a transformation results in a null or illegal value, Azure AD sends a persistent pairwise identifier in the `nameID`.
+
+From the **Choose name identifier format** dropdown, select one of the options in the following table.
+
+| `nameID` format | Description |
+||-|
+| **Default** | Microsoft identity platform uses the default source format. |
+| **Persistent** | Microsoft identity platform uses `Persistent` as the `nameID` format. |
+| **Email address** | Microsoft identity platform uses `EmailAddress` as the `nameID` format. |
+| **Unspecified** | Microsoft identity platform uses `Unspecified` as the `nameID` format. |
+|**Windows domain qualified name**| Microsoft identity platform uses the `WindowsDomainQualifiedName` format.|
+
+Transient `nameID` is also supported, but isn't available in the dropdown and can't be configured on Azure's side. To learn more about the `NameIDPolicy` attribute, see [Single sign-On SAML protocol](single-sign-on-saml-protocol.md).
+
+### Attributes
+
+Select the desired source for the `NameIdentifier` (or `nameID`) claim. You can select from the options in the following table.
+
+| Name | Description |
+||-|
+| `Email` | The email address of the user. |
+| `userprincipalName` | The user principal name (UPN) of the user. |
+| `onpremisessamaccountname` | The SAM account name that has been synced from on-premises Azure AD. |
+| `objectid` | The object ID of the user in Azure AD. |
+| `employeeid` | The employee ID of the user. |
+| `Directory extensions` | The directory extensions [synced from on-premises Active Directory using Azure AD Connect Sync](../hybrid/how-to-connect-sync-feature-directory-extensions.md). |
+| `Extension Attributes 1-15` | The on-premises extension attributes used to extend the Azure AD schema. |
+| `pairwiseid` | The persistent form of user identifier. |
+
+For more information about identifier values, see the table that lists the valid ID values per source later in this page.
+
+Any constant (static) value can be assigned to any claim that is defined in Azure AD. Use the following steps to assign a constant value:
+
+1. In the [Azure portal](https://portal.azure.com/), in the **User Attributes & Claims** section, select **Edit** to edit the claims.
+1. Select the required claim that you want to modify.
+1. Enter the constant value without quotes in the **Source attribute** as per your organization and select **Save**.
+
+ :::image type="content" source="./media/saml-claims-customization/organization-attribute.png" alt-text="Screenshot of the organization Attributes & Claims section in the Azure portal.":::
+
+1. The constant value is displayed as shown in the following image.
+
+ :::image type="content" source="./media/saml-claims-customization/edit-attributes-claims.png" alt-text="Screenshot of editing in the Attributes & Claims section in the Azure portal.":::
+
+### Directory Schema extensions (Preview)
+
+You can also configure directory schema extension attributes as non-conditional/conditional attributes in Azure AD. Use the following steps to configure the single or multi-valued directory schema extension attribute as a claim:
+
+1. In the [Azure portal](https://portal.azure.com/), in the **User Attributes & Claims** section, select **Edit** to edit the claims.
+1. Select **Add new claim** or edit an existing claim.
+
+ :::image type="content" source="./media/saml-claims-customization/mv-extension-1.jpg" alt-text="Screenshot of the MultiValue extension configuration section in the Azure portal.":::
+
+1. Select source application from application picker where extension property is defined.
+ :::image type="content" source="./media/saml-claims-customization/mv-extension-2.jpg" alt-text="Screenshot of the source application selection in MultiValue extension configuration section in the Azure portal.":::
+
+1. Select **Add** to add the selection to the claims.
+
+<!
+5. To select single or multi-valued directory schema extension attribute as conditional attribute select **Directory schema extension** option from the source dropdown.
+
+ :::image type="content" source="./media/active-directory-saml-claims-customization/mv-extension-3.png" alt-text="Screenshot of the MultiValue extension configuration for conditional claims section in the Azure portal.":::
+>
+
+5. Click **Save** to commit the changes.
++
+## Special claims transformations
+
+You can use the following special claims transformations functions.
+
+| Function | Description |
+|-|-|
+| **ExtractMailPrefix()** | Removes the domain suffix from either the email address or the user principal name. This function extracts only the first part of the user name being passed through (for example, "joe_smith" instead of joe_smith@contoso.com). |
+| **ToLower()** | Converts the characters of the selected attribute into lowercase characters. |
+| **ToUpper()** | Converts the characters of the selected attribute into uppercase characters. |
+
+## Add application-specific claims
+
+To add application-specific claims:
+
+1. In **User Attributes & Claims**, select **Add new claim** to open the **Manage user claims** page.
+1. Enter the **name** of the claims. The value doesn't strictly need to follow a URI pattern, per the SAML spec. If you need a URI pattern, you can put that in the **Namespace** field.
+1. Select the **Source** where the claim is going to retrieve its value. You can select a user attribute from the source attribute dropdown or apply a transformation to the user attribute before emitting it as a claim.
+
+### Claim transformations
+
+To apply a transformation to a user attribute:
+
+1. In **Manage claim**, select *Transformation* as the claim source to open the **Manage transformation** page.
+1. Select the function from the transformation dropdown. Depending on the function selected, provide parameters and a constant value to evaluate in the transformation.
+1. Select the source of the attribute by clicking on the appropriate radio button. Directory schema extension source is in preview currently.
+
+ :::image type="content" source="./media/saml-claims-customization/mv-extension-4.png" alt-text="Screenshot of claims transformation.":::
+
+1. Select the attribute name from the dropdown.
+
+1. **Treat source as multivalued** is a checkbox indicating whether the transform should be applied to all values or just the first. By default, transformations are only applied to the first element in a multi-value claim, by checking this box it ensures it's applied to all. This checkbox is only be enabled for multi-valued attributes, for example `user.proxyaddresses`.
+
+1. To apply multiple transformations, select **Add transformation**. You can apply a maximum of two transformations to a claim. For example, you could first extract the email prefix of the `user.mail`. Then, make the string upper case.
++
+You can use the following functions to transform claims.
+
+| Function | Description |
+|-|-|
+| **ExtractMailPrefix()** | Removes the domain suffix from either the email address or the user principal name. This function extracts only the first part of the user name being passed through (for example, "joe_smith" instead of joe_smith@contoso.com). |
+| **Join()** | Creates a new value by joining two attributes. Optionally, you can use a separator between the two attributes. For NameID claim transformation, the Join() function has specific behavior when the transformation input has a domain part. It removes the domain part from input before joining it with the separator and the selected parameter. For example, if the input of the transformation is 'joe_smith@contoso.com' and the separator is '@' and the parameter is 'fabrikam.com', this input combination results in 'joe_smith@fabrikam.com'. |
+| **ToLowercase()** | Converts the characters of the selected attribute into lowercase characters. |
+| **ToUppercase()** | Converts the characters of the selected attribute into uppercase characters. |
+| **Contains()** | Outputs an attribute or constant if the input matches the specified value. Otherwise, you can specify another output if there's no match. <br/>For example, if you want to emit a claim where the value is the user's email address if it contains the domain "@contoso.com", otherwise you want to output the user principal name. To perform this function, you configure the following values:<br/>*Parameter 1(input)*: user.email<br/>*Value*: "@contoso.com"<br/>Parameter 2 (output): user.email<br/>Parameter 3 (output if there's no match): user.userprincipalname |
+| **EndWith()** | Outputs an attribute or constant if the input ends with the specified value. Otherwise, you can specify another output if there's no match.<br/>For example, if you want to emit a claim where the value is the user's employee ID if the employee ID ends with "000", otherwise you want to output an extension attribute. To perform this function, you configure the following values:<br/>*Parameter 1(input)*: user.employeeid<br/>*Value*: "000"<br/>Parameter 2 (output): user.employeeid<br/>Parameter 3 (output if there's no match): user.extensionattribute1 |
+| **StartWith()** | Outputs an attribute or constant if the input starts with the specified value. Otherwise, you can specify another output if there's no match.<br/>For example, if you want to emit a claim where the value is the user's employee ID if the country/region starts with "US", otherwise you want to output an extension attribute. To perform this function, you configure the following values:<br/>*Parameter 1(input)*: user.country<br/>*Value*: "US"<br/>Parameter 2 (output): user.employeeid<br/>Parameter 3 (output if there's no match): user.extensionattribute1 |
+| **Extract() - After matching** | Returns the substring after it matches the specified value.<br/>For example, if the input's value is "Finance_BSimon", the matching value is "Finance_", then the claim's output is "BSimon". |
+| **Extract() - Before matching** | Returns the substring until it matches the specified value.<br/>For example, if the input's value is "BSimon_US", the matching value is "_US", then the claim's output is "BSimon". |
+| **Extract() - Between matching** | Returns the substring until it matches the specified value.<br/>For example, if the input's value is "Finance_BSimon_US", the first matching value is "Finance\_", the second matching value is "\_US", then the claim's output is "BSimon". |
+| **ExtractAlpha() - Prefix** | Returns the prefix alphabetical part of the string.<br/>For example, if the input's value is "BSimon_123", then it returns "BSimon". |
+| **ExtractAlpha() - Suffix** | Returns the suffix alphabetical part of the string.<br/>For example, if the input's value is "123_Simon", then it returns "Simon". |
+| **ExtractNumeric() - Prefix** | Returns the prefix numerical part of the string.<br/>For example, if the input's value is "123_BSimon", then it returns "123". |
+| **ExtractNumeric() - Suffix** | Returns the suffix numerical part of the string.<br/>For example, if the input's value is "BSimon_123", then it returns "123". |
+| **IfEmpty()** | Outputs an attribute or constant if the input is null or empty.<br/>For example, if you want to output an attribute stored in an extension attribute if the employee ID for a given user is empty. To perform this function, you configure the following values:<br/>Parameter 1(input): user.employeeid<br/>Parameter 2 (output): user.extensionattribute1<br/>Parameter 3 (output if there's no match): user.employeeid |
+| **IfNotEmpty()** | Outputs an attribute or constant if the input isn't null or empty.<br/>For example, if you want to output an attribute stored in an extension attribute if the employee ID for a given user isn't empty. To perform this function, you configure the following values:<br/>Parameter 1(input): user.employeeid<br/>Parameter 2 (output): user.extensionattribute1 |
+| **Substring() - Fixed Length** (Preview)| Extracts parts of a string claim type, beginning at the character at the specified position, and returns the specified number of characters.<br/>SourceClaim - The claim source of the transform that should be executed.<br/>StartIndex - The zero-based starting character position of a substring in this instance.<br/>Length - The length in characters of the substring.<br/>For example:<br/>sourceClaim - PleaseExtractThisNow<br/>StartIndex - 6<br/>Length - 11<br/>Output: ExtractThis |
+| **Substring() - EndOfString** (Preview) | Extracts parts of a string claim type, beginning at the character at the specified position, and returns the rest of the claim from the specified start index. <br/>SourceClaim - The claim source of the transform that should be executed.<br/>StartIndex - The zero-based starting character position of a substring in this instance.<br/>For example:<br/>sourceClaim - PleaseExtractThisNow<br/>StartIndex - 6<br/>Output: ExtractThisNow |
+| **RegexReplace()** (Preview) | RegexReplace() transformation accepts as input parameters:<br/>- Parameter 1: a user attribute as regex input<br/>- An option to trust the source as multivalued<br/>- Regex pattern<br/>- Replacement pattern. The replacement pattern may contain static text format along with a reference that points to regex output groups and more input parameters.<br/><br/>More instructions about how to use the RegexReplace() transformation are described later in this article. |
+
+If you need other transformations, submit your idea in the [feedback forum in Azure AD](https://feedback.azure.com/d365community/forum/22920db1-ad25-ec11-b6e6-000d3a4f0789) under the *SaaS application* category.
+
+## Regex-based claims transformation
+
+The following image shows an example of the first level of transformation:
++
+The following table provides information about the first level of transformations. The actions listed in the table correspond to the labels in the previous image. Select **Edit** to open the claims transformation blade.
+
+| Action | Field | Description |
+| :-- | :- | :- |
+| 1 | `Transformation` | Select the **RegexReplace()** option from the **Transformation** options to use the regex-based claims transformation method for claims transformation. |
+| 2 | `Parameter 1` | The input for the regular expression transformation. For example, user.mail that has a user email address such as `admin@fabrikam.com`. |
+| 3 | `Treat source as multivalued` | Some input user attributes can be multi-value user attributes. If the selected user attribute supports multiple values and the user wants to use multiple values for the transformation, they need to select **Treat source as multivalued**. If selected, all values are used for the regex match, otherwise only the first value is used. |
+| 4 | `Regex pattern` | A regular expression that is evaluated against the value of user attribute selected as *Parameter 1*. For example, a regular expression to extract the user alias from the user's email address would be represented as `(?'domain'^.*?)(?i)(\@fabrikam\.com)$`. |
+| 5 | `Add additional parameter` | More than one user attribute can be used for the transformation. The values of the attributes would then be merged with regex transformation output. Up to five more parameters are supported. |
+| 6 | `Replacement pattern` | The replacement pattern is the text template, which contains placeholders for regex outcome. All group names must be wrapped inside the curly braces such as `{group-name}`. Let's say the administration wants to use user alias with some other domain name, for example `xyz.com` and merge country name with it. In this case, the replacement pattern would be `{country}.{domain}@xyz.com`, where `{country}` is the value of input parameter and `{domain}` is the group output from the regular expression evaluation. In such a case, the expected outcome is `US.swmal@xyz.com`. |
+
+The following image shows an example of the second level of transformation:
++
+The following table provides information about the second level of transformations. The actions listed in the table correspond to the labels in the previous image.
+
+| Action | Field | Description |
+| :-- | :- | :- |
+| 1 | `Transformation` | Regex-based claims transformations aren't limited to the first transformation and can be used as the second level transformation as well. Any other transformation method can be used as the first transformation. |
+| 2 | `Parameter 1` | If **RegexReplace()** is selected as a second level transformation, output of first level transformation is used as an input for the second level transformation. To apply the transformation, the second level regex expression should match the output of the first transformation. |
+| 3 | `Regex pattern` | **Regex pattern** is the regular expression for the second level transformation. |
+| 4 | `Parameter input` | User attribute inputs for the second level transformations. |
+| 5 | `Parameter input` | Administrators can delete the selected input parameter if they don't need it anymore. |
+| 6 | `Replacement pattern` | The replacement pattern is the text template, which contains placeholders for regex outcome group name, input parameter group name, and static text value. All group names must be wrapped inside the curly braces such as `{group-name}`. Let's say the administration wants to use user alias with some other domain name, for example `xyz.com` and merge country name with it. In this case, the replacement pattern would be `{country}.{domain}@xyz.com`, where `{country}` is the value of input parameter and {domain} is the group output from the regular expression evaluation. In such a case, the expected outcome is `US.swmal@xyz.com`. |
+| 7 | `Test transformation` | The RegexReplace() transformation is evaluated only if the value of the selected user attribute for *Parameter 1* matches with the regular expression provided in the **Regex pattern** textbox. If they don't match, the default claim value is added to the token. To validate regular expression against the input parameter value, a test experience is available within the transform blade. This test experience operates on dummy values only. When more input parameters are used, the name of the parameter is added to the test result instead of the actual value. To access the test section, select **Test transformation**. |
+
+The following image shows an example of testing the transformations:
++
+The following table provides information about testing the transformations. The actions listed in the table correspond to the labels in the previous image.
+
+| Action | Field | Description |
+| :-- | :- | :- |
+| 1 | `Test transformation` | Select the close or (X) button to hide the test section and re-render the **Test transformation** button again on the blade. |
+| 2 | `Test regex input` | Accepts input that is used for the regular expression test evaluation. In case regex-based claims transformation is configured as a second level transformation, provide a value that is the expected output of the first transformation. |
+| 3 | `Run test` | After the test regex input is provided and the **Regex pattern**, **Replacement pattern** and **Input parameters** are configured, the expression can be evaluated by selecting **Run test**. |
+| 4 | `Test transformation result` | If evaluation succeeds, an output of test transformation is rendered against the **Test transformation result** label. |
+| 5 | `Remove transformation` | The second level transformation can be removed by selecting **Remove transformation**. |
+| 6 | `Specify output if no match` | When a regex input value is configured against the *Parameter 1* that doesn't match the **Regular expression**, the transformation is skipped. In such cases, the alternate user attribute can be configured, which is added to the token for the claim by checking **Specify output if no match**. |
+| 7 | `Parameter 3` | If an alternate user attribute needs to be returned when there's no match and **Specify output if no match** is checked, an alternate user attribute can be selected using the dropdown. This dropdown is available against **Parameter 3 (output if no match)**. |
+| 8 | `Summary` | At the bottom of the blade, a full summary of the format is displayed that explains the meaning of the transformation in simple text. |
+| 9 | `Add` | After the configuration settings for the transformation are verified, it can be saved to a claims policy by selecting **Add**. Select **Save** on the **Manage Claim** blade to save the changes. |
+
+RegexReplace() transformation is also available for the group claims transformations.
+
+### RegexReplace() transformation validations
+
+When the following conditions occur after **Add** or **Run test** is selected, a message is displayed that provides more information about the issue:
+
+* Input parameters with duplicate user attributes aren't allowed.
+* Unused input parameters found. Defined input parameters should have respective usage into the Replacement pattern text.
+* The provided test regex input doesn't match with the provided regular expression.
+* The source for the groups into the replacement pattern isn't found.
+
+## Add the UPN claim to SAML tokens
+
+The `http://schemas.xmlsoap.org/ws/2005/05/identity/claims/upn` claim is part of the [SAML restricted claim set](reference-claims-mapping-policy-type.md#table-2-saml-restricted-claim-set), so you can't add it in the **Attributes & Claims** section. As a workaround, you can add it as an [optional claim](active-directory-optional-claims.md) through **App registrations** in the Azure portal.
+
+Open the application in **App registrations**, select **Token configuration**, and then select **Add optional claim**. Select the **SAML** token type, choose **upn** from the list, and then click **Add** to add the claim to the token.
+
+## Emit claims based on conditions
+
+You can specify the source of a claim based on user type and the group to which the user belongs.
+
+The user type can be:
+
+* **Any** - All users are allowed to access the application.
+* **Members**: Native member of the tenant
+* **All guests**: User is brought over from an external organization with or without Azure AD.
+* **AAD guests**: Guest user belongs to another organization using Azure AD.
+* **External guests**: Guest user belongs to an external organization that doesn't have Azure AD.
+
+One scenario where the user type is helpful is when the source of a claim is different for a guest and an employee accessing an application. You can specify that if the user is an employee, the NameID is sourced from user.email. If the user is a guest, then the NameID is sourced from user.extensionattribute1.
+
+To add a claim condition:
+
+1. In **Manage claim**, expand the Claim conditions.
+1. Select the user type.
+1. Select the group(s) to which the user should belong. You can select up to 50 unique groups across all claims for a given application.
+1. Select the **Source** where the claim is going to retrieve its value. You can either select a user attribute from the dropdown for the source attribute or apply a transformation to the user attribute. You can also select a directory schema extension (preview) before emitting it as a claim.
+
+The order in which you add the conditions are important. Azure AD first evaluates all conditions with source `Attribute` and then evaluates all conditions with source `Transformation` to decide which value to emit in the claim. Conditions with the same source are evaluated from top to bottom. The last value, which matches the expression is emitted in the claim. Transformations such as `IsNotEmpty` and `Contains` act like restrictions.
+
+For example, Britta Simon is a guest user in the Contoso tenant. Britta belongs to another organization that also uses Azure AD. Given the following configuration for the Fabrikam application, when Britta tries to sign in to Fabrikam, the Microsoft identity platform evaluates the conditions.
+
+First, the Microsoft identity platform verifies whether Britta's user type is **All guests**. Because the type is **All guests**, the Microsoft identity platform assigns the source for the claim to `user.extensionattribute1`. Second, the Microsoft identity platform verifies whether Britta's user type is **AAD guests**. Because the type is **All guests**, the Microsoft identity platform assigns the source for the claim to `user.mail`. Finally, the claim is emitted with a value of `user.mail` for Britta.
++
+As another example, consider when Britta Simon tries to sign in and the following configuration is used. Azure AD first evaluates all conditions with source `Attribute`. Because Britta's user type is **AAD guests**, `user.mail` is assigned as the source for the claim. Next, Azure AD evaluates the transformations. Because Britta is a guest, `user.extensionattribute1` is now the new source for the claim. Because Britta is in **AAD guests**, `user.othermail` is now the source for this claim. Finally, the claim is emitted with a value of `user.othermail` for Britta.
++
+As a final example, consider what happens if Britta has no `user.othermail` configured or it's empty. In both cases the condition entry is ignored, and the claim falls back to `user.extensionattribute1` instead.
+
+## Advanced SAML claims options
+
+Advanced claims options can be configured for SAML2.0 applications to expose the same claim to OIDC tokens and vice versa for applications that intend to use the same claim for both SAML2.0 and OIDC response tokens.
+
+Advanced claim options can be configured by checking the box under **Advanced SAML Claims Options** in the **Manage claims** blade.
+
+The following table lists other advanced options that can be configured for an application.
+
+| Option | Description |
+|--|-|
+| Append application ID to issuer | Automatically adds the application ID to the issuer claim. This option ensures a unique claim value for each instance when there are multiple instances of the same application. This setting is ignored if a custom signing key isn't configured for the application. |
+| Override audience claim | Allows for the overriding of the audience claim sent to the application. The value provided must be a valid absolute URI. This setting is ignored if a custom signing key isn't configured for the application. |
+| Include attribute name format | If selected, Azure Active Directory adds an attribute called `NameFormat` that describes the format of the name to restricted, core, and optional claims for the application. For more information, see, [Claims mapping policy type](reference-claims-mapping-policy-type.md#claim-sets) |
+
+## Next steps
+
+* [Configure single sign-on for applications that aren't in the Azure AD application gallery](../manage-apps/configure-saml-single-sign-on.md)
active-directory Whats New Docs https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/develop/whats-new-docs.md
Welcome to what's new in the Microsoft identity platform documentation. This art
### New articles -- [Customize claims issued in the JSON web token (JWT) for enterprise applications](active-directory-jwt-claims-customization.md)
+- [Customize claims issued in the JSON web token (JWT) for enterprise applications](jwt-claims-customization.md)
### Updated articles
active-directory Whats New https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/fundamentals/whats-new.md
Last year we announced the combined registration user experience for MFA and se
+### General Availability - System preferred MFA method
+
+**Type:** Changed feature
+**Service category:** Authentications (Logins)
+**Product capability:** Identity Security & Protection
+
+Currently, organizations and users rely on a range of authentication methods, each offering varying degrees of security. While Multifactor Authentication (MFA) is crucial, some MFA methods are more secure than others. Despite having access to more secure MFA options, users frequently choose less secure methods for various reasons.
+
+To address this challenge, we're introducing a new system-preferred authentication method for MFA. When users sign in, the system will determine and display the most secure MFA method that the user has registered. This prompts users to switch from the default method to the most secure option. While users may still choose a different MFA method, they'll always be prompted to use the most secure method first for every session that requires MFA. For more information, see: [System-preferred multifactor authentication - Authentication methods policy](../authentication/concept-system-preferred-multifactor-authentication.md).
+++ ### General Availability - PIM alert: Alert on active-permanent role assignments in Azure or assignments made outside of PIM **Type:** Fixed
Last year we announced the combined registration user experience for MFA and se
**Service category:** User Management **Product capability:** User Management
-Admins can now define more properties when creating and inviting a user in the Entra admin portal. These improvements bring our UX to parity with our [Create User APIS](/graph/api/user-post-users). Additionally, admins can now add users to a group or administrative unit, as well as assign roles. For more information, see: [Add or delete users using Azure Active Directory](../fundamentals/add-users-azure-active-directory.md).
+Admins can now define more properties when creating and inviting a user in the Entra admin portal. These improvements bring our UX to parity with our [Create User APIS](/graph/api/user-post-users). Additionally, admins can now add users to a group or administrative unit, and assign roles. For more information, see: [Add or delete users using Azure Active Directory](../fundamentals/add-users-azure-active-directory.md).
The protected actions public preview introduces the ability to apply Conditional
**Service category:** Conditional Access **Product capability:** User Authentication
-Token Protection for sign-in sessions is our first release on a road-map to combat attacks involving token theft and replay. It provides conditional access enforcement of token proof-of-possession for supported clients and services that ensures that access to specified resources is only from a device to which the user has signed in. For more information, see: [Conditional Access: Token protection (preview)](../conditional-access/concept-token-protection.md).
+Token Protection for sign-in sessions is our first release on a road-map to combat attacks involving token theft and replay. It provides conditional access enforcement of token proof-of-possession for supported clients and services that ensure that access to specified resources is only from a device to which the user has signed in. For more information, see: [Conditional Access: Token protection (preview)](../conditional-access/concept-token-protection.md).
active-directory How To Connect Sync Feature Preferreddatalocation https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/hybrid/how-to-connect-sync-feature-preferreddatalocation.md
The purpose of this topic is to walk you through how to configure the attribute
For a list of all geos supported by Azure AD Connect see [Microsoft 365 Multi-Geo availability](/microsoft-365/enterprise/microsoft-365-multi-geo#microsoft-365-multi-geo-availability) ## Enable synchronization of preferred data location
-By default, Microsoft 365 resources for your users are located in the same geo as your Azure AD tenant. For example, if your tenant is located in North America, then the users' Exchange mailboxes are also located in North America. For a multinational organization, this might not be optimal.
+By default, Microsoft 365 resources for your users are located in the same geo as your Azure AD tenant. For example, if the _Tenant_ is located in North America, then the users' Exchange mailboxes are also located in North America. For a multinational organization, this might not be optimal.
By setting the attribute **preferredDataLocation**, you can define a user's geo. You can have the user's Microsoft 365 resources, such as the mailbox and OneDrive, in the same geo as the user, and still have one tenant for your entire organization. > [!IMPORTANT]
-> Multi-Geo is currently available to customers with an active Enterprise Agreement and a minimum of 250 Microsoft 365 Services subscriptions. Please talk to your Microsoft representative for details.
+> As of June 1, 2023, Multi-Geo is available for CSP partners to purchase, at a minimum of 5% of their customerΓÇÖs total Microsoft 365 subscription seats.
+>
+> Multi-Geo is also available to customers with an active Enterprise Agreement. Please talk to your Microsoft representative for details.
> > For a list of all geos supported by Azure AD Connect see [Microsoft 365 Multi-Geo availability](/microsoft-365/enterprise/microsoft-365-multi-geo#microsoft-365-multi-geo-availability).
active-directory Pim Resource Roles Assign Roles https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/privileged-identity-management/pim-resource-roles-assign-roles.md
# Assign Azure resource roles in Privileged Identity Management
-With Azure AD Privileged Identity Management (Azure AD PIM), part of Microsoft Entra, can manage the built-in Azure resource roles, and custom roles, including (but not limited to):
+With Azure AD Privileged Identity Management (Azure AD PIM), part of Microsoft Entra, you can manage the built-in Azure resource roles, and custom roles, including (but not limited to):
- Owner - User Access Administrator
active-directory Memo 22 09 Authorization https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/standards/memo-22-09-authorization.md
Title: Memo 22-09 authorization requirements
-description: Get guidance on meeting authorization requirements outlined in US government OMB memorandum 22-09.
+ Title: Meet authorization requirements of memorandum 22-09
+description: Learn how to meet authorization requirements outlined in OMB memorandum 22-09.
Previously updated : 3/10/2022 Last updated : 05/01/2023 # Meet authorization requirements of memorandum 22-09
-This series of articles offers guidance for employing Azure Active Directory (Azure AD) as a centralized identity management system for implementing Zero Trust principles, as described in the US federal government's Office of Management and Budget (OMB) [memorandum 22-09](https://www.whitehouse.gov/wp-content/uploads/2022/01/M-22-09.pdf).
-
-The memo requires specific types of enforcement within your multifactor authentication (MFA) policies. Specifically, you must account for device-based controls, role-based controls, attribute-based controls, and privileged access management.
+This article series has guidance to employ Azure Active Directory (Azure AD) as a centralized identity management system when implementing Zero Trust principles. See, US Office of Management and Budget (OMB) [M 22-09 Memorandum for the Heads of Executive Departments and Agencies](https://www.whitehouse.gov/wp-content/uploads/2022/01/M-22-09.pdf).
+The memo requirements are enforcement types in multifactor authentication policies, and controls for devices, roles, attributes, and privileged access management.
## Device-based controls
-Memorandum 22-09 specifically requires the use of at least one device-based signal when you're making an authorization decision to access a system or application. You can enforce this requirement by using conditional access. Several device signals can be applied during the authorization. The following table describes the signal and the requirements to retrieve the signal:
+A memorandum 22-09 requirement is at least one device-based signal for authorization decisions to access a system or application. Enforce the requirement by using Conditional Access. Apply several device signals during the authorization. See the following table for the signal and the requirement to retrieve the signal.
| Signal| Signal retrieval | | - | - |
-| Device must be managed| Integration with Intune or another mobile device management (MDM) solution that supports this integration is required.
-Hybrid Azure AD joined| The device is managed by Active Directory and qualifies.
-| Device must be compliant| Integration with Intune or another MDM solution that supports this integration is required. For more information, see [Use device compliance policies to set rules for devices you manage with Intune](/mem/intune/protect/device-compliance-get-started). |
-| Threat signals| Microsoft Defender for Endpoint and other endpoint detection and response (EDR) tools have integrations with Azure AD and Intune to send threat signals that can be used to deny access. Threat signals are part of the compliant status signal. |
-| Cross-tenant access policies (public preview)| These policies permit an organization to trust device signals from devices that belong to other organizations. |
+| Device is managed| Integration with Intune or another mobile device management (MDM) solution supporting integration.
+Hybrid Azure AD joined| Active Directory manages the device, and it qualifies.
+| Device is compliant| Integration with Intune or another MDM solution supporting the integration. See, [Create a compliance policy in Microsoft Intune](/mem/intune/protect/device-compliance-get-started). |
+| Threat signals| Microsoft Defender for Endpoint and other endpoint detection and response (EDR) tools have Azure AD and Intune integrations that send threat signals to deny access. Threat signals support the compliant status signal. |
+| Cross-tenant access policies (public preview)| Trust device signals from devices in other organizations. |
## Role-based controls
-Role-based access control (RBAC) is an important way to enforce basic authorizations through assignments of users to a role in a particular scope. Azure AD has tools that make RBAC assignment and lifecycle management easier. For example, you can assign access by using [entitlement management](../governance/entitlement-management-overview.md) features, including [access packages](../governance/entitlement-management-access-package-create.md) and [access reviews](../governance/access-reviews-overview.md).
+Use role-based access control (RBAC) to enforce authorizations through role assignments in a particular scope. For example, assign access by using entitlement management features, including access packages and access reviews. Manage authorizations with self-service requests and use automation to manage lifecycle. For example, automatically end access based on criteria.
+
+Learn more:
-These features ease the burden of managing authorizations by providing self-service requests and automated functions to manage the lifecycle. For example, you can automatically end access based on specific criteria.
+* [What is entitlement management?](../governance/entitlement-management-overview.md)
+* [Create a new access package in entitlement management](../governance/entitlement-management-access-package-create.md)
+* [What are access reviews?](../governance/access-reviews-overview.md)
## Attribute-based controls
-Attribute-based access control (ABAC) relies on metadata assigned to a user or resource as a mechanism to permit or deny access during authentication. There are several ways to create authorizations by using ABAC enforcements for data and resources through authentication.
+Attribute-based access control (ABAC) uses metadata assigned to a user or resource to permit or deny access during authentication. See the following sections to create authorizations by using ABAC enforcements for data and resources through authentication.
### Attributes assigned to users
-You can use attributes assigned to users and stored in Azure AD to create authorizations for users. Users can be automatically assigned to [dynamic groups](../enterprise-users/groups-create-rule.md) based on a particular ruleset that you define during group creation. Rules are configured to add or remove a user from the group based on the evaluation of the rule against the user and one or more of their attributes. This feature has greater value when your attributes are maintained and not statically set on users from the day of creation.
+Use attributes assigned to users, stored in Azure AD, to create user authorizations. Users are automatically assigned to dynamic groups based on a rule set you define during group creation. Rules add or remove a user from the group based on rule evaluation against the user and their attributes. We recommend you maintain attributes and don't set static attributes on creation day.
+
+Learn more: [Create or update a dynamic group in Azure AD](../enterprise-users/groups-create-rule.md)
### Attributes assigned to data
-Azure AD allows integration of an authorization directly to the data. You can integrate authorization in multiple ways.
+With Azure AD, you can integrate authorization to the data. See the following sections to integrate authorization. You can configure authentication in Conditional Access policies: restrict actions users take in an application or on data. These authentication policies are then mapped in the data source.
-You can configure [authentication context](../conditional-access/concept-conditional-access-cloud-apps.md) within conditional access policies. This allows you to, for example, restrict which actions a user can take within an application or on specific data. These authentication contexts are then mapped within the data source itself.
+Data sources can be Microsoft Office files like Word, Excel, or SharePoint sites mapped to authentication. Use authentication assigned to data in applications. This approach requires integration with the application code and for developers to adopt the capability. Use authentication integration with Microsoft Defender for Cloud Apps to control actions taken on data through session controls.
-Data sources can be Microsoft Office files like Word and Excel, or SharePoint sites that are mapped to your authentication context. For an example of this integration, see [Manage site access based on sensitivity label](/sharepoint/authentication-context-example).
+Combine dynamic groups with authentication context to control user access mappings between the data and the user attributes.
-You can also use authentication context assigned to data directly in your applications. This approach requires integration with the application code and [developers](../develop/developer-guide-conditional-access-authentication-context.md) to adopt this capability. You can use authentication context integration with Microsoft Defender for Cloud Apps to control [actions taken on data through session controls](/defender-cloud-apps/session-policy-aad).
+Learn more:
-If you combine dynamic groups with authentication context, you can control user access mappings between the data and the user attributes.
+* [Conditional Access: Cloud apps, actions, and authentication context](../conditional-access/concept-conditional-access-cloud-apps.md)
+* [Developer guide to Conditional Access authentication context](../develop/developer-guide-conditional-access-authentication-context.md)
+* [Session policies](/defender-cloud-apps/session-policy-aad)
### Attributes assigned to resources
-Azure includes [ABAC for Storage](../../role-based-access-control/conditions-overview.md), which allows the assignment of metadata tags on data stored in an Azure Blob Storage account. You can then assign this metadata to users by using role assignments to grant access.
-
-## Privileged access management
-
-The memo specifically calls out the use of privileged access management tools that use single-factor ephemeral credentials for accessing systems as insufficient. These technologies often include password vault products that accept MFA sign-in for an admin and produce a generated password for an alternate account that's used to access the system. The system is still accessed with a single factor.
-
-Microsoft has tools for implementing [Privileged Identity Management](../privileged-identity-management/pim-configure.md) (PIM) for privileged systems with the central identity management system of Azure AD. You can enforce MFA for most privileged systems directly, whether these systems are applications, infrastructure elements, or devices.
+Azure includes attribute-based access control (Azure ABAC) for storage. Assign metadata tags on data stored in an Azure Blob Storage account. Assign the metadata to users by using role assignments to grant access.
-Azure also features PIM capabilities to step up into a specific privileged role. This requires implementation of PIM with Azure AD identities, along with identifying systems that are privileged and require additional protections to prevent lateral movement. For configuration guidance, see [Plan a Privileged Identity Management deployment](../privileged-identity-management/pim-deployment-plan.md).
+Learn more: [What is Azure attribute-based access control?](../../role-based-access-control/conditions-overview.md)
-## Next steps
+## Privileged access management
-The following articles are part of this documentation set:
+The memo cites the inefficiency of using of privileged access management tools with single-factor ephemeral credentials to access systems. These technologies include password vaults that accept multifactor authentication sign-in for an admin. These tools generate a password for an alternate account to access the system. System access occurs with a single factor.
-[Meet identity requirements of memorandum 22-09](memo-22-09-meet-identity-requirements.md)
+Microsoft tools implement Privileged Identity Management (PIM) for privileged systems with Azure AD as the central identity management system. Enforce multifactor authentication for most privileged systems that are applications, infrastructure elements, or devices.
-[Enterprise-wide identity management system](memo-22-09-enterprise-wide-identity-management-system.md)
+Use PIM for a privileged role, when it's implemented with Azure AD identities. Identify privileged systems that require protections to prevent lateral movement.
-[Multifactor authentication](memo-22-09-multi-factor-authentication.md)
+Learn more:
-[Other areas of Zero Trust](memo-22-09-other-areas-zero-trust.md)
+* [What is Azure AD Privileged Identity Management?](../privileged-identity-management/pim-configure.md)
+* [Plan a Privileged Identity Management deployment](../privileged-identity-management/pim-deployment-plan.md)
-For more information about Zero Trust, see:
+## Next steps
-[Securing identity with Zero Trust](/security/zero-trust/deploy/identity)
+* [Meet identity requirements of memorandum 22-09 with Azure Active Directory](memo-22-09-meet-identity-requirements.md)
+* [Memo 22-09 enterprise-wide identity management system](memo-22-09-enterprise-wide-identity-management-system.md)
+* [Meet multifactor authentication requirements of memorandum 22-09](memo-22-09-multi-factor-authentication.md)
+* [Other areas of Zero Trust addressed in memorandum 22-09](memo-22-09-other-areas-zero-trust.md)
+* [Securing identity with Zero Trust](/security/zero-trust/deploy/identity)
active-directory Memo 22 09 Enterprise Wide Identity Management System https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/standards/memo-22-09-enterprise-wide-identity-management-system.md
Title: Memo 22-09 enterprise-wide identity management system
-description: Get guidance on meeting enterprise-wide identity management system requirements outlined in US government OMB memorandum 22-09.
+description: Guidance on meeting enterprise-wide identity management system requirements outlined in OMB memorandum 22-09.
Previously updated : 3/10/2022 Last updated : 05/01/2023
-# Enterprise-wide identity management system
+# Memo 22-09 enterprise-wide identity management system
-Memorandum 22-09 requires agencies to develop a plan to consolidate their identity platforms to as few agency-managed identity systems as possible within 60 days of the publication date (March 28, 2022). There are several advantages to consolidating your identity platform:
-
-* Centralized management of identity lifecycle, policy enforcement, and auditable controls
+[M 22-09 Memorandum for Heads of Executive Departments and Agencies](https://www.whitehouse.gov/wp-content/uploads/2022/01/M-22-09.pdf) requires agencies to develop a consolidation plan for their identity platforms. The goal is to have as few agency-managed identity systems as possible within 60 days of the publication date (March 28, 2022). There are several advantages to consolidating identity platform:
+* Centralize management of identity lifecycle, policy enforcement, and auditable controls
* Uniform capability and parity of enforcement -
-* Reduced need to train resources across multiple systems
-
-* Enabling users to sign in once and then directly access applications and services in the IT environment
-
-* Integration with as many agency applications as possible
-
-* Use of shared authentication services and trust relationships to facilitate integration among agencies
+* Reduce the need to train resources across multiple systems
+* Enable users to sign in once and then access applications and services in the IT environment
+* Integrate with as many agency applications as possible
+* Use shared authentication services and trust relationships to facilitate integration across agencies
## Why Azure Active Directory?
-Azure Active Directory (Azure AD) provides the capabilities necessary to implement the recommendations from memorandum 22-09. It also provides broad identity controls that support Zero Trust initiatives. Today, If your agency uses Microsoft Office 365 or Azure, you already have Azure AD as an identity provider (IdP) and you can connect your applications and resources to Azure AD as your enterprise-wide identity system.
+Use Azure Active Directory (Azure AD) to implement recommendations from memorandum 22-09. Azure AD has identity controls that support Zero Trust initiatives. With Microsoft Office 365 or Azure, Azure AD is an identity provider (IdP). Connect your applications and resources to Azure AD as your enterprise-wide identity system.
## Single sign-on requirements
-The memo requires that users sign in once and then directly access applications. Microsoft's robust single sign-on (SSO) capabilities enable users to sign in once and then access cloud and other applications. For more information, see [Azure Active Directory single sign-on](../hybrid/how-to-connect-sso.md).
+The memo requires users sign in once and then access applications. With Microsoft single sign-on (SSO) users sign in once and then access cloud services and applications. See, [Azure Active Directory Seamless single sign-on](../hybrid/how-to-connect-sso.md).
## Integration across agencies
-[Azure AD B2B collaboration](../external-identities/what-is-b2b.md) helps you meet the requirement to facilitate integration/collaboration among agencies. Whether the users reside in different Microsoft tenant in the same cloud, [tenant on another microsoft cloud](../external-identities/b2b-government-national-clouds.md), or a [non Azure AD tenant (SAML/WS-Fed identity provider)](..//external-identities/direct-federation.md).
+Use Azure AD B2B collaboration to meet the requirement of facilitating integration and collaboration across agencies. Users can reside in a Microsoft tenant in the same cloud. Tenants can be on another Microsoft cloud, or in a non-Azure AD tenant (SAML/WS-Fed identity provider).
+
+With Azure AD cross-tenant access settings, agencies manage how they collaborate with other Azure AD organizations and other Microsoft Azure clouds:
+
+* Limit what Microsoft tenants users can access
+* Settings for external user access, including multifactor authentication enforcement and device signal
-Azure AD cross-tenant access settings allow agencies to manage how they collaborate with other Azure AD organizations and other Microsoft Azure clouds. It does this by:
+Learn more:
-- Limiting what other Microsoft tenants your users can access.-- Granular settings to control access for external users including enforcement of multifactor authentication (MFA) and device signal.
+* [B2B collaboration overview](../external-identities/what-is-b2b.md)
+* [Azure AD B2B in government and national clouds](../external-identities/b2b-government-national-clouds.md)
+* [Federation with SAML/WS-Fed identity providers for guest users](..//external-identities/direct-federation.md)
## Connecting applications
-To consolidate your enterprise to using Azure AD as the enterprise-wide identity system, you must first understand the assets that will be in scope.
+To consolidate and use Azure AD as the enterprise-wide identity system, review the assets that are in scope.
### Document applications and services
-You must inventory the applications and services that users will access. An identity management system can protect only what it knows.
+Create an inventory of the applications and services users access. An identity management system protects what it knows.
-Classify assets in terms of:
+Asset classification:
-- The sensitivity of data that they contain.-- Laws and regulations that establish specific requirements for confidentiality, integrity, or availability of data/information in each major system and that apply to the system's information protection requirements.
+* The sensitivity of data therein
+* Laws and regulations for confidentiality, integrity, or availability of data and/or information in major systems
+ * Said laws and regulations that apply to system information protection requirements
-As a part of your application inventory, you need to determine if your current applications use cloud-ready protocols or [legacy authentication protocols](../fundamentals/auth-sync-overview.md):
+For your application inventory, determine applications that use cloud-ready protocols or legacy authentication protocols:
-* Cloud-ready applications support modern protocols for authentication, such as SAML, WS-Federation/Trust, OpenID Connect (OIDC), and OAuth 2.0.
+* Cloud-ready applications support modern protocols for authentication:
+ * SAML
+ * WS-Federation/Trust
+ * OpenID Connect (OIDC)
+ * OAuth 2.0.
+* Legacy authentication applications rely on older or proprietary authentication methods:
+ * Kerberos/NTLM (Windows authentication)
+ * Header-based authentication
+ * LDAP
+ * Basic authentication
-* Legacy authentication applications rely on older or proprietary methods of authentication, such as Kerberos/NTLM (Windows authentication), header-based authentication, LDAP, and Basic authentication.
+Learn more [Azure AD integrations with authentication protocols](../fundamentals/auth-sync-overview.md
-#### Tools for application and service discovery
+#### Application and service discovery tools
-Microsoft offers the following tools to help with your discovery of applications:
+Microsoft offers the following tools to support application and service discovery.
| Tool| Usage | | - | - |
-| [Usage Analytics for Active Directory Federation Services (AD FS)](../hybrid/how-to-connect-health-adfs.md)| Analyzes the authentication traffic of your federated servers. |
-| [Microsoft Defender for Cloud Apps](/defender-cloud-apps/what-is-defender-for-cloud-apps)| Scans firewall logs to detect cloud apps, infrastructure as a service (IaaS) services, and platform as a service (PaaS) services that your organization uses. It was previously called Microsoft Cloud App Security. Integrating Defender for Cloud Apps with Defender for Endpoint allows discovery to happen from data analyzed from Windows client devices. |
-| [Application Discovery worksheet](https://download.microsoft.com/download/2/8/3/283F995C-5169-43A0-B81D-B0ED539FB3DD/Application%20Discovery%20worksheet.xlsx)| Helps you document the current states of your applications. |
+|Usage Analytics for Active Directory Federation Services (AD FS)| Analyzes federated server authentication traffic. See, [Monitor AD FS using Azure AD Connect Health](../hybrid/how-to-connect-health-adfs.md)|
+| Microsoft Defender for Cloud Apps| Scans firewall logs to detect cloud apps, infrastructure as a service (IaaS) services, and platform as a service (PaaS) services. Integrate Defender for Cloud Apps with Defender for Endpoint to discovery data analyzed from Windows client devices. See, [Microsoft Defender for Cloud Apps overview](/defender-cloud-apps/what-is-defender-for-cloud-apps)|
+| Application Discovery worksheet| Document the current states of your applications. See, [Application Discovery worksheet](https://download.microsoft.com/download/2/8/3/283F995C-5169-43A0-B81D-B0ED539FB3DD/Application%20Discovery%20worksheet.xlsx)|
-We recognize that your apps might be in systems other than Microsoft's, and that Microsoft tools might not discover those apps. Ensure that you do a complete inventory. All providers should have mechanisms for discovering applications that use their services.
+Your apps might be in systems other than Microsoft, and Microsoft tools might not discover those apps. Ensure a complete inventory. Providers need mechanisms to discover applications that use their services.
-#### Prioritizing applications for connection
+#### Prioritize applications for connection
-After you discover all applications in your environment, you need to prioritize them for migration. Consider business criticality, user profiles, usage, and lifespan.
+After you discover the applications in your environment, prioritize them for migration. Consider:
-For more information on prioritizing applications for migration, see [Migrating your applications to Azure Active Directory](https://aka.ms/migrateapps/whitepaper).
+* Business criticality
+* User profiles
+* Usage
+* Lifespan
-First, connect your cloud-ready apps in priority order. Then look at apps that use [legacy authentication protocols](../fundamentals/auth-sync-overview.md).
+Learn more: [Migrate application authentication to Azure AD](https://aka.ms/migrateapps/whitepaper).
-For apps that use legacy authentication protocols, consider the following:
+Connect your cloud-ready apps in priority order. Determine the apps that use legacy authentication protocols.
-* For apps with modern authentication that aren't yet using Azure AD, reconfigure them to use Azure AD.
+For apps that use legacy authentication protocols:
+* For apps with modern authentication, reconfigure them to use Azure AD
* For apps without modern authentication, there are two choices:
+ * Update the application code to use modern protocols by integrating the Microsoft Authentication Library (MSAL)
+ * Use Azure AD Application Proxy or secure hybrid partner access for secure access
+* Decommission access to apps no longer needed, or that aren't supported
- * Modernize the application code to use modern protocols by integrating the [Microsoft Authentication Library (MSAL)](../develop/v2-overview.md).
+Learn more
- * [Use Azure AD Application Proxy or secure hybrid partner access](../manage-apps/secure-hybrid-access.md) to provide secure access.
+* [Azure AD integrations with authentication protocols](../fundamentals/auth-sync-overview.md)
+* [What is the Microsoft identity platform?](../develop/v2-overview.md)
+* [Secure hybrid access: Protect legacy apps with Azure AD](../manage-apps/secure-hybrid-access.md)
-* Decommission access to apps that are no longer needed or that aren't supported (for example, apps that shadow IT processes added).
## Connecting devices
-Part of centralizing your identity management system will include enabling users to sign in to physical and virtual devices.
+Part of centralizing an identity management system is enabling users to sign in to physical and virtual devices. You can connect Windows and Linux devices in your centralized Azure AD system, which eliminates multiple, separate identity systems.
-You can connect Windows and Linux devices in your centralized Azure AD system. That eliminates the need to have multiple, separate identity systems.
+During your inventory and scoping, identify the devices and infrastructure to be integrated with Azure AD. Integration centralizes your authentication and management by using Conditional Access policies with multifactor authentication enforced through Azure AD.
-During your inventory and scope phase, consider identifying your devices and infrastructure so they can be integrated with Azure AD. This integration will centralize your authentication and management. It will also take advantage of conditional access policies and MFA that can be enforced through Azure AD.
+### Tools to discover devices
-### Tools for discovering devices
+You can use Azure Automation accounts to identify devices through inventory collection connected to Azure Monitor. Microsoft Defender for Endpoint has device inventory features. Discover the devices that have Defender for Endpoint configured and those that don't. Device inventory comes from on-premises systems such as System Center Configuration Manager or other systems that manage devices and clients.
-You can use [Azure Automation accounts](../../automation/change-tracking/manage-inventory-vms.md) to identify devices through inventory collection connected to Azure Monitor.
+Learn more:
-[Microsoft Defender for Endpoint](/microsoft-365/security/defender-endpoint/machines-view-overview) also features device inventory capabilities and discovery. This feature discovers which devices have Defender for Endpoint configured and which devices don't. Device inventory can also come from on-premises systems such as [System Center Configuration Manager](/mem/configmgr/core/clients/manage/inventory/introduction-to-hardware-inventory) or other systems that manage devices and clients.
+* [Manage inventory collection from VMs](../../automation/change-tracking/manage-inventory-vms.md)
+* [Microsoft Defender for Endpoint overview](/microsoft-365/security/defender-endpoint/machines-view-overview)
+* [Introduction to hardware inventory](/mem/configmgr/core/clients/manage/inventory/introduction-to-hardware-inventory)
-### Integration of devices with Azure AD
-Devices integrated with Azure AD can be either [hybrid joined devices](../devices/concept-azure-ad-join-hybrid.md) or [Azure AD joined devices](../devices/concept-azure-ad-join.md). Agencies should separate device onboarding by client and user devices, and by physical and virtual machines that operate as infrastructure. For more information about choosing and implementing your deployment strategy for user devices, see [Plan your Azure AD device deployment](../devices/plan-device-deployment.md). For servers and infrastructure, consider the following examples for connecting:
+### Integrate devices with Azure AD
-* [Azure Windows virtual machines](../devices/howto-vm-sign-in-azure-ad-windows.md)
+Devices integrated with Azure AD are hybrid-joined devices or Azure AD joined devices. Separate device onboarding by client and user devices, and by physical and virtual machines that operate as infrastructure. For more information about deployment strategy for user devices, see the following guidance.
-* [Azure Linux virtual machines](../devices/howto-vm-sign-in-azure-ad-linux.md)
-
-* [Azure Virtual Desktop](/azure/architecture/example-scenario/wvd/azure-virtual-desktop-azure-active-directory-join)
-
-* [Virtual desktop infrastructure](../devices/howto-device-identity-virtual-desktop-infrastructure.md)
+* [Plan your Azure AD device deployment](../devices/plan-device-deployment.md)
+* [Hybrid Azure AD joined devices](../devices/concept-azure-ad-join-hybrid.md)
+* [Azure AD joined devices](../devices/concept-azure-ad-join.md)
+* [Log in to a Windows virtual machine in Azure by using Azure AD including passwordless](../devices/howto-vm-sign-in-azure-ad-windows.md)
+* [Log in to a Linux virtual machine in Azure by using Azure AD and OpenSSH](../devices/howto-vm-sign-in-azure-ad-linux.md)
+* [Azure AD join for Azure Virtual Desktop](/azure/architecture/example-scenario/wvd/azure-virtual-desktop-azure-active-directory-join)
+* [Device identity and desktop virtualization](../devices/howto-device-identity-virtual-desktop-infrastructure.md)
## Next steps The following articles are part of this documentation set:
-[Meet identity requirements of memorandum 22-09](memo-22-09-meet-identity-requirements.md)
-
-[Multifactor authentication](memo-22-09-multi-factor-authentication.md)
-
-[Authorization](memo-22-09-authorization.md)
-
-[Other areas of Zero Trust](memo-22-09-other-areas-zero-trust.md)
-
-For more information about Zero Trust, see:
-
-[Securing identity with Zero Trust](/security/zero-trust/deploy/identity)
+* [Meet identity requirements of memorandum 22-09 with Azure AD](memo-22-09-meet-identity-requirements.md)
+* [Meet multifactor authentication requirements of memorandum 22-09](memo-22-09-multi-factor-authentication.md)
+* [Meet authorization requirements of memorandum 22-09](memo-22-09-authorization.md)
+* [Other areas of Zero Trust addressed in memorandum 22-09](memo-22-09-other-areas-zero-trust.md)
+* [Securing identity with Zero Trust](/security/zero-trust/deploy/identity)
active-directory Memo 22 09 Meet Identity Requirements https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/active-directory/standards/memo-22-09-meet-identity-requirements.md
Previously updated : 3/10/2022 Last updated : 04/28/2023 # Meet identity requirements of memorandum 22-09 with Azure Active Directory
-US executive order [14028, Improving the Nation's Cyber Security](https://www.whitehouse.gov/briefing-room/presidential-actions/2021/05/12/executive-order-on-improving-the-nations-cybersecurity), directs federal agencies on advancing security measures that drastically reduce the risk of successful cyberattacks against the federal government's digital infrastructure. On January 26, 2022, the [Office of Management and Budget (OMB)](https://www.whitehouse.gov/omb/) released the federal Zero Trust strategy in [memorandum 22-09](https://www.whitehouse.gov/wp-content/uploads/2022/01/M-22-09.pdf), in support of EO 14028.
+The [Executive Order on Improving the NationΓÇÖs Cybersecurity (14028)](https://www.whitehouse.gov/briefing-room/presidential-actions/2021/05/12/executive-order-on-improving-the-nations-cybersecurity), directs federal agencies to advance security measures that significantly reduce the risk of successful cyberattacks against federal government digital infrastructure. On January 26, 2022, in support of Executive Order (EO) 14028, the [Office of Management and Budget (OMB)](https://www.whitehouse.gov/omb/) released the federal Zero Trust strategy in [M 22-09 Memorandum for Heads of Executive Departments and Agencies](https://www.whitehouse.gov/wp-content/uploads/2022/01/M-22-09.pdf).
-This series of articles offers guidance for employing Azure Active Directory (Azure AD) as a centralized identity management system for implementing Zero Trust principles, as described in memorandum 22-09.
+This article series has guidance to employ Azure Active Directory (Azure AD) as a centralized identity management system when implementing Zero Trust principles, as described in memorandum 22-09.
-The release of memorandum 22-09 is designed to support Zero Trust initiatives within federal agencies. It also provides regulatory guidance in supporting federal cybersecurity and data privacy laws. The memo cites the [Department of Defense (DoD) Zero Trust Reference Architecture](https://cloudsecurityalliance.org/artifacts/dod-zero-trust-reference-architecture/):
+Memorandum 22-09 supports Zero Trust initiatives in federal agencies. It has regulatory guidance for federal cybersecurity and data privacy laws. The memo cites the [US Department of Defense (DoD) Zero Trust Reference Architecture](https://cloudsecurityalliance.org/artifacts/dod-zero-trust-reference-architecture/):
->"The foundational tenet of the Zero Trust Model is that no actor, system, network, or service operating outside or within the security perimeter is trusted. Instead, we must verify anything and everything attempting to establish access. It is a dramatic paradigm shift in philosophy of how we secure our infrastructure, networks, and data, from verify once at the perimeter to continual verification of each user, device, application, and transaction."
+"*The foundational tenet of the Zero Trust Model is that no actor, system, network, or service operating outside or within the security perimeter is trusted. Instead, we must verify anything and everything attempting to establish access. It is a dramatic paradigm shift in philosophy of how we secure our infrastructure, networks, and data, from verify once at the perimeter to continual verification of each user, device, application, and transaction.*"
-The memo identifies five core goals that federal agencies must reach. These goals are organized through the Cybersecurity Information Systems Architecture (CISA) Maturity Model. CISA's Zero Trust model describes five complementary areas of effort, or pillars: identity, devices, networks, applications and workloads, and data. These themes cut across these areas: visibility and analytics, automation and orchestration, and governance.
+The memo identifies five core goals for federal agencies to reach, organized with the Cybersecurity Information Systems Architecture (CISA) Maturity Model. The CISA Zero Trust model describes five complementary areas of effort, or pillars:
-## Scope of guidance
+* Identity
+* Devices
+* Networks
+* Applications and workloads
+* Data
-This series of articles provides practical guidance for administrators and decision makers to adapt a plan to meet memo requirements. It assumes that you're using Microsoft 365 products and therefore have an Azure AD tenant available. If this is inaccurate, see [Create a new tenant in Azure Active Directory](../fundamentals/active-directory-access-create-new-tenant.md).
+The pillars intersect with:
-The article series features guidance that encompasses existing agency investments in Microsoft technologies that align with the identity-related actions outlined in the memo:
+* Visibility
+* Analytics
+* Automation
+* Orchestration
+* Governance
-* Agencies must employ centralized identity management systems for agency users that can be integrated into applications and common platforms.
+## Scope of guidance
-* Agencies must use strong multifactor authentication (MFA) throughout their enterprise:
+Use the article series to build a plan to meet memo requirements. It assumes use of Microsoft 365 products and an Azure AD tenant.
- * MFA must be enforced at the application layer instead of the network layer.
+Learn more: [Quickstart: Create a new tenant in Azure AD](../fundamentals/active-directory-access-create-new-tenant.md).
- * For agency staff, contractors, and partners, phishing-resistant MFA is required.
-
- * For public users, phishing-resistant MFA must be an option.
-
- * Password policies must not require the use of special characters or regular rotation.
+The article series instructions encompass agency investments in Microsoft technologies that align with the memo's identity-related actions.
-* When agencies are authorizing users to access resources, they must consider at least one device-level signal alongside identity information about the authenticated user.
+* For agency users, agencies employ centralized identity management systems that can be integrated with applications and common platforms
+* Agencies use enterprise-wide, strong multi-factor authentication (MFA)
+ * MFA is enforced at the application layer, not the network layer
+ * For agency staff, contractors, and partners, phishing-resistant MFA is required
+ * For public users, phishing-resistant MFA is an option
+ * Password policies don't require special characters or regular rotation
+* When agencies authorize user access to resources, they consider at least one device-level signal, with identity information about the authenticated user
## Next steps
-The following articles are part of this documentation set:
-
-[Enterprise-wide identity management system](memo-22-09-enterprise-wide-identity-management-system.md)
-
-[Multifactor authentication](memo-22-09-multi-factor-authentication.md)
-
-[Authorization](memo-22-09-authorization.md)
-
-[Other areas of Zero Trust](memo-22-09-other-areas-zero-trust.md)
-
-For more information about Zero Trust, see:
-
-[Securing identity with Zero Trust](/security/zero-trust/deploy/identity)
+* [Enterprise-wide identity management system](memo-22-09-enterprise-wide-identity-management-system.md)
+* [Meet multifactor authentication requirements of memorandum 22-09](memo-22-09-multi-factor-authentication.md)
+* [Meet authorization requirements of memorandum 22-09](memo-22-09-authorization.md)
+* [Other areas of Zero Trust addressed in memorandum 22-09](memo-22-09-other-areas-zero-trust.md)
+* [Securing identity with Zero Trust](/security/zero-trust/deploy/identity)
aks Azure Cni Powered By Cilium https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/aks/azure-cni-powered-by-cilium.md
Azure CNI Powered by Cilium can be deployed using two different methods for assi
- assign IP addresses from a VNet (similar to existing Azure CNI with Dynamic Pod IP Assignment) - assign IP addresses from an overlay network (similar to Azure CNI Overlay mode)
-
-> [!NOTE]
-> Azure CNI Overlay networking currently requires the `Microsoft.ContainerService/AzureOverlayPreview` feature and may be available only in certain regions. For more information, see [Azure CNI Overlay networking](./azure-cni-overlay.md).
If you aren't sure which option to select, read ["Choosing a network model to use"](./azure-cni-overlay.md#choosing-a-network-model-to-use).
aks Concepts Identity https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/aks/concepts-identity.md
In the Azure portal, you can find:
- To get started with Azure AD and Kubernetes RBAC, see [Integrate Azure Active Directory with AKS][aks-aad]. - For associated best practices, see [Best practices for authentication and authorization in AKS][operator-best-practices-identity]. - To get started with Azure RBAC for Kubernetes Authorization, see [Use Azure RBAC to authorize access within the Azure Kubernetes Service (AKS) Cluster](manage-azure-rbac.md).-- To get started securing your `kubeconfig` file, see [Limit access to cluster configuration file](control-kubeconfig-access.md)
+- To get started securing your `kubeconfig` file, see [Limit access to cluster configuration file](control-kubeconfig-access.md).
+- To get started with managed identities in AKS, see [Use a managed identity in AKS](./use-managed-identity.md).
For more information on core Kubernetes and AKS concepts, see the following articles:
aks Faq https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/aks/faq.md
Microsoft provides guidance for other actions you can take to secure your worklo
## How does the managed Control Plane communicate with my Nodes?
-AKS uses a secure tunnel communication to allow the api-server and individual node kubelets to communicate even on separate virtual networks. The tunnel is secured through TLS encryption. The current main tunnel that is used by AKS is [Konnectivity, previously known as apiserver-network-proxy](https://kubernetes.io/docs/tasks/extend-kubernetes/setup-konnectivity/). Verify all network rules follow the [Azure required network rules and FQDNs](limit-egress-traffic.md).
+AKS uses a secure tunnel communication to allow the api-server and individual node kubelets to communicate even on separate virtual networks. The tunnel is secured through mTLS encryption. The current main tunnel that is used by AKS is [Konnectivity, previously known as apiserver-network-proxy](https://kubernetes.io/docs/tasks/extend-kubernetes/setup-konnectivity/). Verify all network rules follow the [Azure required network rules and FQDNs](limit-egress-traffic.md).
## Why are two resource groups created with AKS?
aks Use Managed Identity https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/aks/use-managed-identity.md
Make sure you have Azure CLI version 2.23.0 or later installed. Run `az --versio
* Tenants moving or migrating a managed identity-enabled cluster isn't supported. * If the cluster has Azure AD pod-managed identity (`aad-pod-identity`) enabled, Node-Managed Identity (NMI) pods modify the iptables of the nodes to intercept calls to the Azure Instance Metadata (IMDS) endpoint. This configuration means any request made to the Metadata endpoint is intercepted by NMI, even if the pod doesn't use `aad-pod-identity`. AzurePodIdentityException CRD can be configured to inform `aad-pod-identity` of any requests to the Metadata endpoint originating from a pod that matches labels defined in CRD should be proxied without any processing in NMI. The system pods with `kubernetes.azure.com/managedby: aks` label in *kube-system* namespace should be excluded in `aad-pod-identity` by configuring the AzurePodIdentityException CRD.
- * For more information, see [Disable aad-pod-identity for a specific pod or application](https://azure.github.io/aad-pod-identity/docs/configure/application_exception).
+ * For more information, see [Disable aad-pod-identity for a specific pod or application](./use-azure-ad-pod-identity.md#clean-up).
* To configure an exception, install the [mic-exception YAML](https://github.com/Azure/aad-pod-identity/blob/master/deploy/infra/mic-exception.yaml). * AKS doesn't support the use of a system-assigned managed identity if using a custom private DNS zone.
AKS uses several managed identities for built-in services and add-ons.
| Add-on | Ingress application gateway | Manages required network resources. | Contributor role for node resource group | No | Add-on | omsagent | Used to send AKS metrics to Azure Monitor. | Monitoring Metrics Publisher role | No | Add-on | Virtual-Node (ACIConnector) | Manages required network resources for Azure Container Instances (ACI). | Contributor role for node resource group | No
-| OSS project | aad-pod-identity | Enables applications to access cloud resources securely with Microsoft Azure Active Directory (Azure AD). | N/A | Steps to grant permission at [Azure AD Pod Identity Role Assignment configuration](https://azure.github.io/aad-pod-identity/docs/getting-started/role-assignment/).
+| OSS project | aad-pod-identity | Enables applications to access cloud resources securely with Microsoft Azure Active Directory (Azure AD). | N/A | Steps to grant permission at [Azure AD Pod Identity Role Assignment configuration](./use-azure-ad-pod-identity.md).
## Enable managed identities on a new AKS cluster
After updating your cluster, the control plane and pods use the managed identity
> [!NOTE] >
-> * Keep the following information in mind when updating your cluster:
+> Keep the following information in mind when updating your cluster:
> > * An update only works if there's a VHD update to consume. If you're running the latest VHD, you need to wait until the next VHD is available in order to perform the update. >
aks Workload Identity Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/aks/workload-identity-overview.md
Title: Use an Azure AD workload identities (preview) on Azure Kubernetes Service (AKS)
-description: Learn about Azure Active Directory workload identity (preview) for Azure Kubernetes Service (AKS) and how to migrate your application to authenticate using this identity.
+ Title: Use an Azure AD workload identities on Azure Kubernetes Service (AKS)
+description: Learn about Azure Active Directory workload identity for Azure Kubernetes Service (AKS) and how to migrate your application to authenticate using this identity.
Previously updated : 04/19/2023 Last updated : 05/01/2023
The following table summarizes our migration or deployment recommendations for w
[deploy-configure-workload-identity-new-cluster]: workload-identity-deploy-cluster.md [tutorial-use-workload-identity]: ./learn/tutorial-kubernetes-workload-identity.md [workload-identity-migration-sidecar]: workload-identity-migrate-from-pod-identity.md
-[auto-rotation]: certificate-rotation.md#certificate-auto-rotation
+[auto-rotation]: certificate-rotation.md#certificate-auto-rotation
api-management Return Response Policy https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/api-management/return-response-policy.md
The `return-response` policy cancels pipeline execution and returns either a def
| Element | Description | Required | | | -- | -- |
-| set-status | A [set-status](set-status-policy.md) policy statement. | No |
-| set-header | A [set-header](set-header-policy.md) policy statement. | No |
-| set-body | A [set-body](set-body-policy.md) policy statement. | No |
+| [set-status](set-status-policy.md) | Sets the status code of the response. | No |
+| [set-header](set-header-policy.md) | Sets a header in the response. | No |
+| [set-body](set-body-policy.md) | Sets the body in the response. | No |
## Usage
The `return-response` policy cancels pipeline execution and returns either a def
- [**Policy scopes:**](./api-management-howto-policies.md#scopes) global, workspace, product, API, operation - [**Gateways:**](api-management-gateways-overview.md) dedicated, consumption, self-hosted
+### Usage notes
+
+- A liquid template doesn't work when specified inside the body (set using `set-body`) of the `return-response` policy. The `return-response` policy cancels the current execution pipeline and removes the request body and response body in the current context. As a result, a liquid template specified inside the policy receives an empty string as its input and won't produce the expected output.
+ ## Example ```xml
The `return-response` policy cancels pipeline execution and returns either a def
* [API Management advanced policies](api-management-advanced-policies.md)
app-service Overview Vnet Integration https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/app-service/overview-vnet-integration.md
Title: Integrate your app with an Azure virtual network
description: Integrate your app in Azure App Service with Azure virtual networks. Previously updated : 03/31/2023 Last updated : 05/01/2023
Learn [how to enable virtual network integration](./configure-vnet-integration-e
## <a name="how-regional-virtual-network-integration-works"></a> How virtual network integration works
-Apps in App Service are hosted on worker roles. Virtual network integration works by mounting virtual interfaces to the worker roles with addresses in the delegated subnet. Because the from address is in your virtual network, it can access most things in or through your virtual network like a VM in your virtual network would.
+Apps in App Service are hosted on worker roles. Virtual network integration works by mounting virtual interfaces to the worker roles with addresses in the delegated subnet. The virtual interfaces used aren't resources customers have direct access to. Because the from address is in your virtual network, it can access most things in or through your virtual network like a VM in your virtual network would.
:::image type="content" source="./media/overview-vnet-integration/vnetint-how-regional-works.png" alt-text="Diagram that shows how virtual network integration works.":::
When virtual network integration is enabled, your app makes outbound calls throu
When all traffic routing is enabled, all outbound traffic is sent into your virtual network. If all traffic routing isn't enabled, only private traffic (RFC1918) and service endpoints configured on the integration subnet is sent into the virtual network. Outbound traffic to the internet is routed directly from the app.
-The feature supports two virtual interfaces per worker. Two virtual interfaces per worker mean two virtual network integrations per App Service plan. The apps in the same App Service plan can only use one of the virtual network integrations to a specific subnet. If you need an app to connect to more virtual networks or more subnets in the same virtual network, you need to create another App Service plan. The virtual interfaces used aren't resources customers have direct access to.
+The virtual network integration feature supports two virtual interfaces per worker. Two virtual interfaces per worker mean two virtual network integrations per App Service plan. In other words, an App Service plan can have virtual network integrations with up to two subnets/virtual networks. The apps in the same App Service plan can only use one of the virtual network integrations to a specific subnet, meaning an app can only have a single virtual network integration at a given time.
## Subnet requirements
app-service Webjobs Create https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/app-service/webjobs-create.md
-
+ Title: Run background tasks with WebJobs description: Learn how to use WebJobs to run background tasks in Azure App Service. Choose from a variety of script formats and run them with CRON expressions.
application-gateway Application Gateway Private Deployment https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/application-gateway/application-gateway-private-deployment.md
AGIC v1.7 must be used to introduce support for private frontend IP only.
If Application Gateway has a backend target or key vault reference to a private endpoint located in a VNet that is accessible via global VNet peering, traffic is dropped, resulting in an unhealthy status.
-### Network watcher integration
+### Network Watcher integration
-Connection Troubleshoot and NSG Diagnostics will return an error when running check and diagnostic tests.
+Connection troubleshoot and NSG diagnostics will return an error when running check and diagnostic tests.
### Coexisting v2 Application Gateways created prior to enablement of enhanced network control
azure-app-configuration Quickstart Aspnet Core App https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-app-configuration/quickstart-aspnet-core-app.md
In this example, you'll update a web page to display its content using the setti
h1 { color: @Model.Settings.FontColor;
- font-size: @Model.Settings.FontSize;
+ font-size: @(Model.Settings.FontSize)px;
} </style>
azure-arc Azure Rbac https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-arc/kubernetes/azure-rbac.md
Using a shared kubeconfig requires slightly different steps depending on your Ku
sudo chmod +x /usr/local/bin/kubelogin ```
-5. [Convert](https://azure.github.io/kubelogin/cli/convert-kubeconfig.html) the kubelogin to the appropriate [login mode](https://azure.github.io/kubelogin/concepts/login-modes.html). For example, for [device code login](https://azure.github.io/kubelogin/concepts/login-modes/devicecode.html) with an Azure Active Directory user, the commands would be as follows:
+5. [Convert](https://azure.github.io/kubelogin/cli/convert-kubeconfig.html) the kubelogin to use the appropriate [login mode](https://azure.github.io/kubelogin/concepts/login-modes.html). For example, for [device code login](https://azure.github.io/kubelogin/concepts/login-modes/devicecode.html) with an Azure Active Directory user, the commands would be as follows:
```bash export KUBECONFIG=/path/to/kubeconfig
azure-monitor Azure Monitor Agent Data Collection Endpoint https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/agents/azure-monitor-agent-data-collection-endpoint.md
Title: Define Azure Monitor Agent network settings description: Define network settings and enable network isolation for Azure Monitor Agent. Previously updated : 12/19/2022 Last updated : 5/1/2023
Azure Virtual network service tags can be used to define network access controls
| Azure China | Replace '.com' above with '.cn' | Same as above | Same as above | Same as above| Same as above | >[!NOTE]
-> If you use private links on the agent, you must also add the [data collection endpoints (DCEs)](../essentials/data-collection-endpoint-overview.md#components-of-a-data-collection-endpoint).
+> If you use private links on the agent, you must **only** add the [private data collection endpoints (DCEs)](../essentials/data-collection-endpoint-overview.md#components-of-a-data-collection-endpoint). The agent does not use the non-private endpoints listed above when using private links/data collection endpoints.
> The Azure Monitor Metrics (custom metrics) preview isn't available in Azure Government and Azure China clouds. ## Proxy configuration
azure-monitor Opencensus Python https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/app/opencensus-python.md
Title: Monitor Python applications with Azure Monitor | Microsoft Docs description: This article provides instructions on how to wire up OpenCensus Python with Azure Monitor. Previously updated : 04/24/2023 Last updated : 05/01/2023 ms.devlang: python
# Set up Azure Monitor for your Python application
+> [!NOTE]
+> OpenTelemetry announced the [sunsetting of OpenCensus](https://opentelemetry.io/blog/2023/sunsetting-opencensus/). Azure continues to support the Python OpenCensus SDK and will not drop support for it without at least one year of advance notification. A preview of our [OpenTelemetry-based Python offering](opentelemetry-enable.md?tabs=python) is available.
+ Azure Monitor supports distributed tracing, metric collection, and logging of Python applications. Microsoft's supported solution for tracking and exporting data for your Python applications is through the [OpenCensus Python SDK](#introducing-opencensus-python-sdk) via the [Azure Monitor exporters](#instrument-with-opencensus-python-sdk-with-azure-monitor-exporters).
Microsoft doesn't recommend using any other telemetry SDKs for Python as a telem
OpenCensus is converging into [OpenTelemetry](https://opentelemetry.io/). We continue to recommend OpenCensus while OpenTelemetry gradually matures.
-> [!NOTE]
-> A preview [OpenTelemetry-based Python offering](opentelemetry-enable.md?tabs=python) is available. To learn more, see the [OpenTelemetry overview](opentelemetry-overview.md).
- ## Prerequisites You need an Azure subscription. If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/) before you begin.
azure-monitor Data Collection Rule Edit https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/essentials/data-collection-rule-edit.md
Our final step is to update DCR back in the system. This is accomplished by ΓÇ£P
1. If you are using Azure Cloud Shell, save the file and close the embedded editor, or [upload modified DCR file back to the Cloud Shell environment](../../cloud-shell/using-the-shell-window.md#upload-and-download-files). 2. Execute the following commands to load DCR content from the file and place HTTP call to update the DCR in the system. Replace `<ResourceId>` with DCR ResourceID and `<FilePath>` with the name of the file modified in the previous part of the tutorial. You can omit first two lines if you read and write to the DCR within the same PowerShell session. ```PowerShell
- $ResourceId = ΓÇ£<ResourceId>ΓÇ¥ # Resource ID of the DCR to edit
- $FilePath = ΓÇ£<FilePath>ΓÇ¥ # Store DCR content in this file
+ $ResourceId = "<ResourceId>" # Resource ID of the DCR to edit
+ $FilePath = "<FilePath>" # Store DCR content in this file
$DCRContent = Get-Content $FilePath -Raw Invoke-AzRestMethod -Path ("$ResourceId"+"?api-version=2021-09-01-preview") -Method PUT -Payload $DCRContent ```
azure-monitor Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/logs/api/overview.md
Last updated 02/28/2023
-uid: azure_monitor_logs_api_overview
# Azure Monitor Log Analytics API overview
azure-monitor Azure Monitor Data Explorer Proxy https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/logs/azure-monitor-data-explorer-proxy.md
adx('https://help.kusto.windows.net/Samples').StormEvents
>* Cross-resource query as an alert isn't supported. >* Identifying the Timestamp column in the cluster isn't supported. The Log Analytics Query API won't pass along the time filter. > * The cross-service query ability is used for data retrieval only. For more information, see [Function supportability](#function-supportability).
+> * Private Link is not supported with this feature.
## Function supportability
azure-monitor Basic Logs Configure https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/logs/basic-logs-configure.md
Configure a table for Basic logs if:
| Container Insights | [ContainerLogV2](/azure/azure-monitor/reference/tables/containerlogv2) | | Communication Services | [ACSCallAutomationIncomingOperations](/azure/azure-monitor/reference/tables/ACSCallAutomationIncomingOperations)<br>[ACSCallRecordingSummary](/azure/azure-monitor/reference/tables/acscallrecordingsummary)<br>[ACSRoomsIncomingOperations](/azure/azure-monitor/reference/tables/acsroomsincomingoperations) | | Confidential Ledgers | [CCFApplicationLogs](/azure/azure-monitor/reference/tables/CCFApplicationLogs) |
+ | Data Manager for Energy | [OEPDataplaneLogs](/azure/azure-monitor/reference/tables/OEPDataplaneLogs) |
| Dedicated SQL Pool | [SynapseSqlPoolSqlRequests](/azure/azure-monitor/reference/tables/synapsesqlpoolsqlrequests)<br>[SynapseSqlPoolRequestSteps](/azure/azure-monitor/reference/tables/synapsesqlpoolrequeststeps)<br>[SynapseSqlPoolExecRequests](/azure/azure-monitor/reference/tables/synapsesqlpoolexecrequests)<br>[SynapseSqlPoolDmsWorkers](/azure/azure-monitor/reference/tables/synapsesqlpooldmsworkers)<br>[SynapseSqlPoolWaits](/azure/azure-monitor/reference/tables/synapsesqlpoolwaits) | | Dev Center | [DevCenterDiagnosticLogs](/azure/azure-monitor/reference/tables/DevCenterDiagnosticLogs) | | Firewalls | [AZFWFlowTrace](/azure/azure-monitor/reference/tables/AZFWFlowTrace) |
azure-monitor Private Link Design https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/logs/private-link-design.md
Bundle the JavaScript code in your script so that the browser doesn't attempt to
If you're connecting to your Azure Monitor resources over a private link, traffic to these resources must go through the private endpoint that's configured on your network. To enable the private endpoint, update your DNS settings as explained in [Connect to a private endpoint](./private-link-configure.md#connect-to-a-private-endpoint). Some browsers use their own DNS settings instead of the ones you set. The browser might attempt to connect to Azure Monitor public endpoints and bypass the private link entirely. Verify that your browser settings don't override or cache old DNS settings. ### Querying limitation: externaldata operator
-The [`externaldata` operator](/azure/data-explorer/kusto/query/externaldata-operator?pivots=azuremonitor) isn't supported over a private link because it reads data from storage accounts but doesn't guarantee the storage is accessed privately.
+* The [`externaldata` operator](/azure/data-explorer/kusto/query/externaldata-operator?pivots=azuremonitor) isn't supported over a private link because it reads data from storage accounts but doesn't guarantee the storage is accessed privately.
+* The [Azure Data Explorer proxy (ADX proxy)](azure-monitor-data-explorer-proxy.md) allows log queries to query Azure Data Explorer. The ADX proxy isn't supported over a private link because it doesn't guarantee the targeted resource is accessed privately.
## Next steps - Learn how to [configure your private link](private-link-configure.md).
azure-monitor Snapshot Debugger Function App https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/snapshot-debugger/snapshot-debugger-function-app.md
Title: Enable Snapshot Debugger for .NET and .NET Core apps in Azure Functions | Microsoft Docs
-description: Enable Snapshot Debugger for .NET and .NET Core apps in Azure Functions
+description: Enable Snapshot Debugger for .NET and .NET Core apps in Azure Functions.
# Enable Snapshot Debugger for .NET and .NET Core apps in Azure Functions
-Snapshot Debugger currently works for ASP.NET and ASP.NET Core apps that are running on Azure Functions on Windows Service Plans.
+Snapshot Debugger currently works for ASP.NET and ASP.NET Core apps that are running on Azure Functions on Windows service plans.
-We recommend that you run your application on the Basic service tier or higher when using Snapshot Debugger.
+We recommend that you run your application on the Basic service tier or higher when you use Snapshot Debugger.
For most applications, the Free and Shared service tiers don't have enough memory or disk space to save snapshots.
-## Prerequisites
+## Prerequisite
-* [Enable Application Insights monitoring in your Function App](../../azure-functions/configure-monitoring.md#add-to-an-existing-function-app)
+[Enable Application Insights monitoring in your Functions app](../../azure-functions/configure-monitoring.md#add-to-an-existing-function-app)
## Enable Snapshot Debugger
-To enable Snapshot Debugger in your Function app, add the `snapshotConfiguration` property to your *host.json* file and redeploy your function. For example:
+To enable Snapshot Debugger in your Functions app, add the `snapshotConfiguration` property to your *host.json* file and redeploy your function. For example:
```json {
To enable Snapshot Debugger in your Function app, add the `snapshotConfiguration
} ```
-Snapshot Debugger is pre-installed as part of the Azure Functions runtime and is disabled by default. Since it's included in the runtime, you don't need to add extra NuGet packages or application settings.
+Snapshot Debugger is preinstalled as part of the Azure Functions runtime and is disabled by default. Because it's included in the runtime, you don't need to add extra NuGet packages or application settings.
-In the simple .NET Core Function app example below, `.csproj`, `{Your}Function.cs`, and `host.json` has Snapshot Debugger enabled:
+In the simple .NET Core Function app example that follows, `.csproj`, `{Your}Function.cs`, and `host.json` have Snapshot Debugger enabled:
-***`Project.csproj`***
+`Project.csproj`
```xml <Project Sdk="Microsoft.NET.Sdk">
namespace SnapshotCollectorAzureFunction
## Enable Snapshot Debugger for other clouds
-Currently the only regions that require endpoint modifications are [Azure Government](../../azure-government/compare-azure-government-global-azure.md#application-insights) and [Azure China](/azure/china/resources-developer-guide).
+Currently, the only regions that require endpoint modifications are [Azure Government](../../azure-government/compare-azure-government-global-azure.md#application-insights) and [Azure China](/azure/china/resources-developer-guide).
-Below is an example of the `host.json` updated with the US Government Cloud agent endpoint:
+The following example shows the `host.json` updated with the US Government Cloud agent endpoint:
```json {
Below is an example of the `host.json` updated with the US Government Cloud agen
} ```
-Below are the supported overrides of the Snapshot Debugger agent endpoint:
+Here are the supported overrides of the Snapshot Debugger agent endpoint:
|Property | US Government Cloud | China Cloud | |||-|
Below are the supported overrides of the Snapshot Debugger agent endpoint:
## Disable Snapshot Debugger
-To disable Snapshot Debugger in your Function app, update your `host.json` file by setting the `snapshotConfiguration.isEnabled` property to `false`.
+To disable Snapshot Debugger in your Functions app, update your `host.json` file by setting the `snapshotConfiguration.isEnabled` property to `false`.
```json {
We recommend that you have Snapshot Debugger enabled on all your apps to ease di
## Next steps
-* Generate traffic to your application that can trigger an exception. Then, wait 10 to 15 minutes for snapshots to be sent to the Application Insights instance.
+* Generate traffic to your application that can trigger an exception. Then wait 10 to 15 minutes for snapshots to be sent to the Application Insights instance.
* [View snapshots](snapshot-debugger-data.md?toc=/azure/azure-monitor/toc.json#view-snapshots-in-the-portal) in the Azure portal.
-* Customize Snapshot Debugger configuration based on your use-case on your Function app. For more information, see [snapshot configuration in host.json](../../azure-functions/functions-host-json.md#applicationinsightssnapshotconfiguration).
+* Customize Snapshot Debugger configuration based on your use case on your Functions app. For more information, see [Snapshot configuration in host.json](../../azure-functions/functions-host-json.md#applicationinsightssnapshotconfiguration).
* For help with troubleshooting Snapshot Debugger issues, see [Snapshot Debugger troubleshooting](snapshot-debugger-troubleshoot.md).
azure-monitor Snapshot Debugger Upgrade https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/snapshot-debugger/snapshot-debugger-upgrade.md
Title: Upgrading Azure Application Insights Snapshot Debugger
-description: How to upgrade Snapshot Debugger for .NET apps to the latest version on Azure App Services, or via Nuget packages
+ Title: Upgrade Application Insights Snapshot Debugger
+description: Learn how to upgrade the Snapshot Debugger for .NET apps to the latest version on Azure App Services or via NuGet packages.
Last updated 08/18/2022
-# Upgrading the Snapshot Debugger
+# Upgrade the Snapshot Debugger
-To provide the best possible security for your data, Microsoft is moving away from TLS 1.0 and TLS 1.1, which have been shown to be vulnerable to determined attackers. If you're using an older version of the site extension, it will require an upgrade to continue working. This document outlines the steps needed to upgrade your Snapshot debugger to the latest version.
+To provide the best possible security for your data, Microsoft is moving away from TLS 1.0 and TLS 1.1 because these protocols are vulnerable to determined attackers. If you're using an older version of the site extension, it requires an upgrade to continue working. This article outlines the steps needed to upgrade your instance of Snapshot Debugger to the latest version.
-You can follow two primary upgrade paths, depending on how you enabled the Snapshot Debugger:
+Depending on how you enabled the Snapshot Debugger, you can follow two primary upgrade paths:
* Via site extension * Via an SDK/NuGet added to your application This article discusses both upgrade paths.
-## Upgrading the site extension
+## Upgrade the site extension
> [!IMPORTANT]
-> Older versions of Application Insights used a private site extension called *Application Insights extension for Azure App Service*. The current Application Insights experience is enabled by setting App Settings to light up a pre-installed site extension.
-> To avoid conflicts, which may cause your site to stop working, it is important to delete the private site extension first. See step 4 below.
+> Older versions of Application Insights used a private site extension called *Application Insights extension for Azure App Service*. The current Application Insights experience is enabled by setting App Settings to light up a preinstalled site extension.
+> To avoid conflicts, which might cause your site to stop working, delete the private site extension first. See step 4 in the following procedure.
-If you enabled the Snapshot debugger using the site extension, you can upgrade using the following procedure:
+If you enabled the Snapshot Debugger by using the site extension, you can upgrade by following these steps:
1. Sign in to the Azure portal.
-1. Go to to your resource that has Application Insights and Snapshot debugger enabled. For example, for a Web App, go to to the App Service resource:
+1. Go to your resource that has Application Insights and Snapshot Debugger enabled. For example, for a web app, go to the Azure App Service resource.
- :::image type="content" source="./media/snapshot-debugger-upgrade/app-service-resource.png" alt-text="Screenshot of individual App Service resource named DiagService01.":::
+ :::image type="content" source="./media/snapshot-debugger-upgrade/app-service-resource.png" alt-text="Screenshot that shows an individual App Service resource named DiagService01.":::
-1. After you've navigated to your resource, click on the **Extensions** pane and wait for the list of extensions to populate:
+1. After you've moved to your resource, select the **Extensions** pane. Wait for the list of extensions to populate.
- :::image type="content" source="./media/snapshot-debugger-upgrade/application-insights-site-extension-to-be-deleted.png" alt-text="Screenshot of App Service Extensions showing Application Insights extension for Azure App Service installed.":::
+ :::image type="content" source="./media/snapshot-debugger-upgrade/application-insights-site-extension-to-be-deleted.png" alt-text="Screenshot that shows App Service Extensions showing the Application Insights extension for Azure App Service installed.":::
-1. If any version of *Application Insights extension for Azure App Service* is installed, select it and click **Delete**. Confirm **Yes** to delete the extension and wait for the delete to complete before moving to the next step.
+1. If any version of **Application Insights extension for Azure App Service** is installed, select it and select **Delete**. Confirm **Yes** to delete the extension. Wait for the delete process to finish before you move to the next step.
- :::image type="content" source="./media/snapshot-debugger-upgrade/application-insights-site-extension-delete.png" alt-text="Screenshot of App Service Extensions showing Application Insights extension for Azure App Service with the Delete button highlighted.":::
+ :::image type="content" source="./media/snapshot-debugger-upgrade/application-insights-site-extension-delete.png" alt-text="Screenshot that shows App Service Extensions showing Application Insights extension for Azure App Service with the Delete button.":::
-1. Go to the **Overview** pane of your resource and select **Application Insights**:
+1. Go to the **Overview** pane of your resource and select **Application Insights**.
- :::image type="content" source="./media/snapshot-debugger-upgrade/application-insights-button.png" alt-text="Screenshot of three buttons. Center button with name Application Insights is selected.":::
+ :::image type="content" source="./media/snapshot-debugger-upgrade/application-insights-button.png" alt-text="Screenshot that shows selecting the Application Insights button.":::
-1. If this is the first time you've viewed the Application Insights pane for this App Service, you'll be prompted to turn on Application Insights. Select **Turn on Application Insights**.
+1. If this is the first time you've viewed the **Application Insights** pane for this app service, you're prompted to turn on Application Insights. Select **Turn on Application Insights**.
- :::image type="content" source="./media/snapshot-debugger-upgrade/turn-on-application-insights.png" alt-text="Screenshot of the first-time experience for the Application Insights pane with the Turn on Application Insights button highlighted.":::
+ :::image type="content" source="./media/snapshot-debugger-upgrade/turn-on-application-insights.png" alt-text="Screenshot that shows the Turn on Application Insights button.":::
-1. In the Application Insights settings pane, switch the Snapshot Debugger setting toggles to **On** and select **Apply**.
+1. On the **Application Insights settings** pane, switch the Snapshot Debugger setting toggles to **On** and select **Apply**.
- If you decide to change *any* Application Insights settings, the **Apply** button on the bottom of the pane will be activated.
+ If you decide to change *any* Application Insights settings, the **Apply** button is activated.
- :::image type="content" source="./media/snapshot-debugger-upgrade/view-application-insights-data.png" alt-text="Screenshot of Application Insights App Service Configuration page with Apply button highlighted in red.":::
+ :::image type="content" source="./media/snapshot-debugger-upgrade/view-application-insights-data.png" alt-text="Screenshot that shows Application Insights App Service Configuration page with the Apply button highlighted.":::
-1. After you click **Apply**, you'll be asked to confirm the changes.
+1. After you select **Apply**, you're asked to confirm the changes.
> [!NOTE]
- > The site will be restarted as part of the upgrade process.
+ > The site restarts as part of the upgrade process.
- :::image type="content" source="./media/snapshot-debugger-upgrade/apply-monitoring-settings.png" alt-text="Screenshot of App Service's apply monitoring prompt.":::
+ :::image type="content" source="./media/snapshot-debugger-upgrade/apply-monitoring-settings.png" alt-text="Screenshot that shows the App Service Apply monitoring settings prompt.":::
-1. Click **Yes** to apply the changes and wait for the process to complete.
+1. Select **Yes** to apply the changes and wait for the process to finish.
-The site has now been upgraded and is ready to use.
+The site is now upgraded and is ready to use.
-## Upgrading Snapshot Debugger using SDK/Nuget
+## Upgrade Snapshot Debugger by using SDK/NuGet
-If the application is using a version of `Microsoft.ApplicationInsights.SnapshotCollector` below version 1.3.1, it will need to be upgraded to a [newer version](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector) to continue working.
+If the application is using a version of `Microsoft.ApplicationInsights.SnapshotCollector` earlier than version 1.3.1, you must upgrade it to a [newer version](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector) to continue working.
azure-monitor Snapshot Debugger Vm https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/snapshot-debugger/snapshot-debugger-vm.md
Title: Enable Snapshot Debugger for .NET apps in Azure Service Fabric, Cloud Service, and Virtual Machines | Microsoft Docs
-description: Enable Snapshot Debugger for .NET apps in Azure Service Fabric, Cloud Service, and Virtual Machines
+ Title: Enable Snapshot Debugger for .NET apps in Azure Service Fabric, Cloud Services, and Virtual Machines | Microsoft Docs
+description: Enable Snapshot Debugger for .NET apps in Azure Service Fabric, Azure Cloud Services, and Azure Virtual Machines.
Last updated 03/21/2023
-# Enable Snapshot Debugger for .NET apps in Azure Service Fabric, Cloud Service, and Virtual Machines
+# Enable Snapshot Debugger for .NET apps in Azure Service Fabric, Cloud Services, and Virtual Machines
-If your ASP.NET or ASP.NET Core application runs in App Service and requires a customized Snapshot Debugger configuration, or a preview version of .NET Core, start with the [Enable Snapshot Debugger for App Services how-to guide](snapshot-debugger-app-service.md).
+If your ASP.NET or ASP.NET Core application runs in Azure App Service and requires a customized Snapshot Debugger configuration, or a preview version of .NET Core, start with [Enable Snapshot Debugger for .NET apps in Azure App Service](snapshot-debugger-app-service.md).
-If your application runs in Azure Service Fabric, Cloud Service, Virtual Machines, or on-premises machines, you can skip enabling Snapshot Debugger on App Services and jump into following this guide.
+If your application runs in Azure Service Fabric, Azure Cloud Services, Azure Virtual Machines, or on-premises machines, you can skip enabling Snapshot Debugger on App Service and follow the guidance in this article.
## Before you begin - [Enable Application Insights in your web app](../app/asp-net.md).- - Include the [Microsoft.ApplicationInsights.SnapshotCollector](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector) NuGet package version 1.3.5 or above in your app. ## Configure snapshot collection for ASP.NET applications
The following example shows a configuration equivalent to the default configurat
</TelemetryProcessors> ```
-Snapshots are collected _only_ on exceptions reported to Application Insights. In some cases (for example, older versions of the .NET platform), you may need to [configure exception collection](../app/asp-net-exceptions.md#exceptions) to see exceptions with snapshots in the portal.
+Snapshots are collected _only_ on exceptions reported to Application Insights. In some cases (for example, older versions of the .NET platform), you might need to [configure exception collection](../app/asp-net-exceptions.md#exceptions) to see exceptions with snapshots in the portal.
-## Configure snapshot collection for applications using ASP.NET Core LTS or above
+## Configure snapshot collection for apps by using ASP.NET Core LTS or above
### Prerequisites
If needed, customize the Snapshot Debugger configuration by adding a `SnapshotCo
## Configure snapshot collection for other .NET applications
-Snapshots are collected only on exceptions that are reported to Application Insights. You may need to modify your code to report them. The exception handling code depends on the structure of your application, but an example is below:
+Snapshots are collected only on exceptions that are reported to Application Insights. You might need to modify your code to report them. The exception handling code depends on the structure of your application. Here's an example:
```csharp TelemetryClient _telemetryClient = new TelemetryClient();
void ExampleRequest()
## Next steps -- Generate traffic to your application that can trigger an exception. Then, wait 10 to 15 minutes for snapshots to be sent to the Application Insights instance.
+- Generate traffic to your application that can trigger an exception. Then wait 10 to 15 minutes for snapshots to be sent to the Application Insights instance.
- See [snapshots](snapshot-debugger-data.md?toc=/azure/azure-monitor/toc.json#view-snapshots-in-the-portal) in the Azure portal. - For help with troubleshooting Snapshot Debugger issues, see [Snapshot Debugger troubleshooting](snapshot-debugger-troubleshoot.md).
azure-monitor Snapshot Debugger https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-monitor/snapshot-debugger/snapshot-debugger.md
Title: Azure Application Insights Snapshot Debugger for .NET apps
-description: Debug snapshots are automatically collected when exceptions are thrown in production .NET apps
+ Title: Application Insights Snapshot Debugger for .NET apps
+description: Debug snapshots are automatically collected when exceptions are thrown in production .NET apps.
Last updated 04/14/2023
# Debug snapshots on exceptions in .NET apps
-When an exception occurs, you can automatically collect a debug snapshot from your live web application. The debug snapshot shows the state of source code and variables at the moment the exception was thrown. The Snapshot Debugger in [Azure Application Insights](../app/app-insights-overview.md):
+When an exception occurs, you can automatically collect a debug snapshot from your live web application. The debug snapshot shows the state of source code and variables at the moment the exception was thrown.
+
+The Snapshot Debugger in [Application Insights](../app/app-insights-overview.md):
- Monitors system-generated logs from your web app. - Collects snapshots on your top-throwing exceptions. - Provides information you need to diagnose issues in production.
-To use the Snapshot Debugger, you simply:
-1. Include the [Snapshot collector NuGet package](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector) in your application
-1. Configure collection parameters in [`ApplicationInsights.config`](../app/configuration-with-applicationinsights-config.md).
+To use the Snapshot Debugger, you:
+
+- Include the [Snapshot Collector NuGet package](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector) in your application.
+- Configure collection parameters in [`ApplicationInsights.config`](../app/configuration-with-applicationinsights-config.md).
## How snapshots work
-The Snapshot Debugger is implemented as an [Application Insights Telemetry Processor](../app/configuration-with-applicationinsights-config.md#telemetry-processors-aspnet). When your application runs, the Snapshot Debugger Telemetry Processor is added to your application's system-generated logs pipeline.
-Each time your application calls [TrackException](../app/asp-net-exceptions.md#exceptions), the Snapshot Debugger computes a Problem ID from the type of exception being thrown and the throwing method.
-Each time your application calls `TrackException`, a counter is incremented for the appropriate Problem ID. When the counter reaches the `ThresholdForSnapshotting` value, the Problem ID is added to a Collection Plan.
+The Snapshot Debugger is implemented as an [Application Insights telemetry processor](../app/configuration-with-applicationinsights-config.md#telemetry-processors-aspnet). When your application runs, the Snapshot Debugger telemetry processor is added to your application's system-generated logs pipeline.
+
+Each time your application calls [TrackException](../app/asp-net-exceptions.md#exceptions), the Snapshot Debugger computes a problem ID from the type of exception being thrown and the throwing method.
+Each time your application calls `TrackException`, a counter is incremented for the appropriate problem ID. When the counter reaches the `ThresholdForSnapshotting` value, the problem ID is added to a collection plan.
+
+The Snapshot Debugger also monitors exceptions as they're thrown by subscribing to the [AppDomain.CurrentDomain.FirstChanceException](/dotnet/api/system.appdomain.firstchanceexception) event. When that event fires, the problem ID of the exception is computed and compared against the problem IDs in the collection plan.
-The Snapshot Debugger also monitors exceptions as they're thrown by subscribing to the [AppDomain.CurrentDomain.FirstChanceException](/dotnet/api/system.appdomain.firstchanceexception) event. When that event fires, the Problem ID of the exception is computed and compared against the Problem IDs in the Collection Plan.
-If there's a match, then a snapshot of the running process is created. The snapshot is assigned a unique identifier and the exception is stamped with that identifier. After the `FirstChanceException` handler returns, the thrown exception is processed as normal. Eventually, the exception reaches the `TrackException` method again where it, along with the snapshot identifier, is reported to Application Insights.
+If there's a match, a snapshot of the running process is created. The snapshot is assigned a unique identifier and the exception is stamped with that identifier. After the `FirstChanceException` handler returns, the thrown exception is processed as normal. Eventually, the exception reaches the `TrackException` method again. It's reported to Application Insights, along with the snapshot identifier.
The main process continues to run and serve traffic to users with little interruption. Meanwhile, the snapshot is handed off to the Snapshot Uploader process. The Snapshot Uploader creates a minidump and uploads it to Application Insights along with any relevant symbol (*.pdb*) files.
-> [!TIP]
-> * A process snapshot is a suspended clone of the running process.
-> * Creating the snapshot takes about 10 to 20 milliseconds.
-> * The default value for `ThresholdForSnapshotting` is 1. This is also the minimum value. Therefore, your app has to trigger the same exception **twice** before a snapshot is created.
-> * Set `IsEnabledInDeveloperMode` to true if you want to generate snapshots while debugging in Visual Studio.
-> * The snapshot creation rate is limited by the `SnapshotsPerTenMinutesLimit` setting. By default, the limit is one snapshot every ten minutes.
-> * No more than 50 snapshots per day may be uploaded.
+Snapshot creation tips:
+ * A process snapshot is a suspended clone of the running process.
+ * Creating the snapshot takes about 10 milliseconds to 20 milliseconds.
+ * The default value for `ThresholdForSnapshotting` is 1. This value is also the minimum. Your app has to trigger the same exception *twice* before a snapshot is created.
+ * Set `IsEnabledInDeveloperMode` to `true` if you want to generate snapshots while you debug in Visual Studio.
+ * The snapshot creation rate is limited by the `SnapshotsPerTenMinutesLimit` setting. By default, the limit is one snapshot every 10 minutes.
+ * No more than 50 snapshots per day can be uploaded.
+## Supported applications and environments
-## Supported applications and environments
+This section lists the applications and environments that are supported.
### Applications
Snapshot collection is available for:
- .NET and ASP.NET applications running .NET [LTS](https://dotnet.microsoft.com/platform/support/policy/dotnet-core) and newer versions on Windows. - .NET [LTS](https://dotnet.microsoft.com/platform/support/policy/dotnet-core) (and newer versions) applications on Windows.
-.NET Core versions prior to LTS are out of support and not recommended.
+.NET Core versions prior to LTS are out of support and we don't recommend their use.
### Environments The following environments are supported: * [Azure App Service](snapshot-debugger-app-service.md?toc=/azure/azure-monitor/toc.json)
-* [Azure Function](snapshot-debugger-function-app.md?toc=/azure/azure-monitor/toc.json)
+* [Azure Functions](snapshot-debugger-function-app.md?toc=/azure/azure-monitor/toc.json)
* [Azure Cloud Services](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json) running OS family 4 or later
-* [Azure Service Fabric services](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json) running on Windows Server 2012 R2 or later
-* [Azure Virtual Machines and Virtual Machine Scale Sets](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json) running Windows Server 2012 R2 or later
+* [Azure Service Fabric](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json) running on Windows Server 2012 R2 or later
+* [Azure Virtual Machines and Azure Virtual Machine Scale Sets](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json) running Windows Server 2012 R2 or later
* [On-premises virtual or physical machines](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json) running Windows Server 2012 R2 or later or Windows 8.1 or later > [!NOTE]
-> Client applications (for example, WPF, Windows Forms or UWP) aren't supported.
+> Client applications (for example, WPF, Windows Forms, or UWP) aren't supported.
-If you've enabled Snapshot Debugger but aren't seeing snapshots, check the [Troubleshooting guide](snapshot-debugger-troubleshoot.md).
+If you enabled the Snapshot Debugger but you aren't seeing snapshots, see the [Troubleshooting guide](snapshot-debugger-troubleshoot.md).
## Required permissions
-Access to snapshots is protected by Azure role-based access control (Azure RBAC). To inspect a snapshot, you must first be added to the [Application Insights Snapshot Debugger](../../role-based-access-control/role-assignments-portal.md) role. Subscription owners can assign this role to individual users or groups for the target **Application Insights Snapshot**.
+Access to snapshots is protected by Azure role-based access control. To inspect a snapshot, you must first be added to the [Application Insights Snapshot Debugger](../../role-based-access-control/role-assignments-portal.md) role. Subscription owners can assign this role to individual users or groups for the target **Application Insights Snapshot**.
-For detailed steps, see [Assign Azure roles using the Azure portal](../../role-based-access-control/role-assignments-portal.md).
+For more information, see [Assign Azure roles by using the Azure portal](../../role-based-access-control/role-assignments-portal.md).
> [!IMPORTANT]
-> Snapshots may contain personal data or other sensitive information in variable and parameter values. Snapshot data is stored in the same region as your App Insights resource.
+> Snapshots might contain personal data or other sensitive information in variable and parameter values. Snapshot data is stored in the same region as your Application Insights resource.
## Limitations
+This section discusses limitations for the Snapshot Debugger.
+ ### Data retention Debug snapshots are stored for 15 days. The default data retention policy is set on a per-application basis. If you need to increase this value, you can request an increase by opening a support case in the Azure portal. For each Application Insights instance, a maximum number of 50 snapshots are allowed per day.
Debug snapshots are stored for 15 days. The default data retention policy is set
### Publish symbols The Snapshot Debugger requires symbol files on the production server to decode variables and to provide a debugging experience in Visual Studio.
-Version 15.2 (or above) of Visual Studio 2017 publishes symbols for release builds by default when it publishes to App Service. In prior versions, you need to add the following line to your publish profile `.pubxml` file so that symbols are published in release mode:
+
+Version 15.2 (or above) of Visual Studio 2017 publishes symbols for release builds by default when it publishes to App Service. In prior versions, you must add the following line to your publish profile `.pubxml` file so that symbols are published in release mode:
```xml <ExcludeGeneratedDebugSymbol>False</ExcludeGeneratedDebugSymbol> ```
-For Azure Compute and other types, make sure that the symbol files are in the same folder of the main application .dll (typically, `wwwroot/bin`) or are available on the current path.
+For Azure Compute and other types, make sure that the symbol files are in the same folder of the main application .dll (typically, `wwwroot/bin`). Or they must be available on the current path.
-> [!NOTE]
-> For more information on the different symbol options that are available, see the [Visual Studio documentation](/visualstudio/ide/reference/advanced-build-settings-dialog-box-csharp). For best results, we recommend that you use "Full", "Portable" or "Embedded".
+For more information on the different symbol options that are available, see the [Visual Studio documentation](/visualstudio/ide/reference/advanced-build-settings-dialog-box-csharp). For best results, we recommend that you use *Full*, *Portable*, or *Embedded*.
### Optimized builds In some cases, local variables can't be viewed in release builds because of optimizations that are applied by the JIT compiler.
-However, in Azure App Services, the Snapshot Collector can deoptimize throwing methods that are part of its Collection Plan.
+
+However, in App Service, the Snapshot Collector can deoptimize throwing methods that are part of its collection plan.
> [!TIP]
-> Install the Application Insights Site Extension in your App Service to get de-optimization support.
+> Install the Application Insights Site extension in your instance of App Service to get deoptimization support.
-## Release notes for `Microsoft.ApplicationInsights.SnapshotCollector`
+## Release notes for Microsoft.ApplicationInsights.SnapshotCollector
-This article contains the releases notes for the Microsoft.ApplicationInsights.SnapshotCollector NuGet package for .NET applications, which is used by the Application Insights Snapshot Debugger.
+This article contains the release notes for the `Microsoft.ApplicationInsights.SnapshotCollector` NuGet package for .NET applications, which is used by the Application Insights Snapshot Debugger.
[Learn](./snapshot-debugger.md) more about the Application Insights Snapshot Debugger for .NET applications.
-For bug reports and feedback, [open an issue on GitHub](https://github.com/microsoft/ApplicationInsights-SnapshotCollector)
+For bug reports and feedback, [open an issue on GitHub](https://github.com/microsoft/ApplicationInsights-SnapshotCollector).
[!INCLUDE [azure-monitor-log-analytics-rebrand](../../../includes/azure-monitor-instrumentation-key-deprecation.md)] ### [1.4.4](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.4.4) A point release to address user-reported bugs.+ #### Bug fixes-- Fix [Exception during native component extraction when using a single file application.](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/21)
+Fixed [Exception during native component extraction when using a single file application.](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/21)
+ #### Changes - Lowered PDB scan failure messages from Error to Warning.-- Update msdia140.dll.
+- Updated msdia140.dll.
- Avoid making a service connection if the debugger is disabled via site extension settings. ### [1.4.3](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.4.3) A point release to address user-reported bugs.+ #### Bug fixes-- Fix [Hide the IMDS dependency from dependency tracker.](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/17)-- Fix [ArgumentException: telemetryProcessorTypedoes not implement ITelemetryProcessor.](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/19)
-<br>Snapshot Collector used via SDK is not supported when Interop feature is enabled. [See more not supported scenarios.](snapshot-debugger-troubleshoot.md#not-supported-scenarios)
+- Fixed [Hide the IMDS dependency from dependency tracker.](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/17).
+- Fixed [ArgumentException: telemetryProcessorTypedoes not implement ITelemetryProcessor.](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/19).
+<br>Snapshot Collector used via SDK isn't supported when the Interop feature is enabled. See [More not supported scenarios](snapshot-debugger-troubleshoot.md#not-supported-scenarios).
### [1.4.2](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.4.2) A point release to address a user-reported bug.+ #### Bug fixes-- Fix [ArgumentException: Delegates must be of the same type.](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/16)
+Fixed [ArgumentException: Delegates must be of the same type](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/16).
### [1.4.1](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.4.1) A point release to revert a breaking change introduced in 1.4.0.+ #### Bug fixes-- Fix [Method not found in WebJobs](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/15)
+Fixed [Method not found in WebJobs](https://github.com/microsoft/ApplicationInsights-SnapshotCollector/issues/15).
### [1.4.0](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.4.0)
-Address multiple improvements and added support for Azure Active Directory (Azure AD) authentication for Application Insights ingestion.
+Addressed multiple improvements and added support for Azure Active Directory (Azure AD) authentication for Application Insights ingestion.
+ #### Changes-- Snapshot Collector package size reduced by 60%. From 10.34 MB to 4.11 MB.-- Target netstandard2.0 only in Snapshot Collector.-- Bump Application Insights SDK dependency to 2.15.0.-- Add back MinidumpWithThreadInfo when writing dumps.-- Add CompatibilityVersion to improve synchronization between Snapshot Collector agent and uploader on breaking changes.-- Change SnapshotUploader LogFile naming algorithm to avoid excessive file I/O in App Service.-- Add pid, role name, and process start time to uploaded blob metadata.-- Use System.Diagnostics.Process where possible in Snapshot Collector and Snapshot Uploader.
+- Reduced Snapshot Collector package size by 60% from 10.34 MB to 4.11 MB.
+- Targeted netstandard2.0 only in Snapshot Collector.
+- Bumped Application Insights SDK dependency to 2.15.0.
+- Added back `MinidumpWithThreadInfo` when writing dumps.
+- Added `CompatibilityVersion` to improve synchronization between the Snapshot Collector agent and the Snapshot Uploader on breaking changes.
+- Changed `SnapshotUploader` LogFile naming algorithm to avoid excessive file I/O in App Service.
+- Added pid, role name, and process start time to uploaded blob metadata.
+- Used `System.Diagnostics.Process` where possible in Snapshot Collector and Snapshot Uploader.
+ #### New features-- Add Azure Active Directory authentication to SnapshotCollector. Learn more about Azure AD authentication in Application Insights [here](../app/azure-ad-authentication.md).
+Added Azure AD authentication to `SnapshotCollector`. To learn more about Azure AD authentication in Application Insights, see [Azure AD authentication for Application Insights](../app/azure-ad-authentication.md).
### [1.3.7.5](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.7.5) A point release to backport a fix from 1.4.0-pre.+ #### Bug fixes-- Fix [ObjectDisposedException on shutdown](https://github.com/microsoft/ApplicationInsights-dotnet/issues/2097).
+Fixed [ObjectDisposedException on shutdown](https://github.com/microsoft/ApplicationInsights-dotnet/issues/2097).
### [1.3.7.4](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.7.4)
-A point release to address a problem discovered in testing Azure App Service's codeless attach scenario.
+A point release to address a problem discovered in testing the App Service codeless attach scenario.
+ #### Changes-- The netcoreapp3.0 target now depends on Microsoft.ApplicationInsights.AspNetCore >= 2.1.1 (previously >= 2.1.2).
+The `netcoreapp3.0` target now depends on `Microsoft.ApplicationInsights.AspNetCore` >= 2.1.1 (previously >= 2.1.2).
### [1.3.7.3](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.7.3) A point release to address a couple of high-impact issues.+ #### Bug fixes-- Fixed PDB discovery in the wwwroot/bin folder, which was broken when we changed the symbol search algorithm in 1.3.6.-- Fixed noisy ExtractWasCalledMultipleTimesException in telemetry.
+- Fixed PDB discovery in the *wwwroot/bin* folder, which was broken when we changed the symbol search algorithm in 1.3.6.
+- Fixed noisy `ExtractWasCalledMultipleTimesException` in telemetry.
### [1.3.7](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.7) #### Changes-- The netcoreapp2.0 target of SnapshotCollector depends on Microsoft.ApplicationInsights.AspNetCore >= 2.1.1 (again). This reverts behavior to how it was before 1.3.5. We tried to upgrade it in 1.3.6, but it broke some Azure App Service scenarios.
+The `netcoreapp2.0` target of `SnapshotCollector` depends on `Microsoft.ApplicationInsights.AspNetCore` >= 2.1.1 (again). This change reverts behavior to how it was before 1.3.5. We tried to upgrade it in 1.3.6, but it broke some App Service scenarios.
+ #### New features-- Snapshot Collector reads and parses the ConnectionString from the APPLICATIONINSIGHTS_CONNECTION_STRING environment variable or from the TelemetryConfiguration. Primarily, this is used to set the endpoint for connecting to the Snapshot service. For more information, see the [Connection strings documentation](../app/sdk-connection-string.md).
+Snapshot Collector reads and parses the `ConnectionString` from the APPLICATIONINSIGHTS_CONNECTION_STRING environment variable or from the `TelemetryConfiguration`. Primarily, it's used to set the endpoint for connecting to the Snapshot service. For more information, see the [Connection strings documentation](../app/sdk-connection-string.md).
+ #### Bug fixes-- Switched to using HttpClient for all targets except net45 because WebRequest was failing in some environments due to an incompatible SecurityProtocol (requires TLS 1.2).
+Switched to using `HttpClient` for all targets except `net45` because `WebRequest` was failing in some environments because of an incompatible `SecurityProtocol` (requires TLS 1.2).
### [1.3.6](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.6) #### Changes-- SnapshotCollector now depends on Microsoft.ApplicationInsights >= 2.5.1 for all target frameworks. This may be a breaking change if your application depends on an older version of the Microsoft.ApplicationInsights SDK.-- Remove support for TLS 1.0 and 1.1 in Snapshot Uploader.-- Period of PDB scans now defaults 24 hours instead of 15 minutes. Configurable via PdbRescanInterval on SnapshotCollectorConfiguration.-- PDB scan searches top-level folders only, instead of recursive. This may be a breaking change if your symbols are in subfolders of the binary folder.
+- `SnapshotCollector` now depends on `Microsoft.ApplicationInsights` >= 2.5.1 for all target frameworks. This requirement might be a breaking change if your application depends on an older version of the Microsoft.ApplicationInsights SDK.
+- Removed support for TLS 1.0 and 1.1 in Snapshot Uploader.
+- Period of PDB scans now defaults 24 hours instead of 15 minutes. Configurable via `PdbRescanInterval` on `SnapshotCollectorConfiguration`.
+- PDB scan searches top-level folders only, instead of recursive. This change might be a breaking change if your symbols are in subfolders of the binary folder.
+ #### New features-- Log rotation in SnapshotUploader to avoid filling the logs folder with old files.
+- Log rotation in `SnapshotUploader` to avoid filling the logs folder with old files.
- Deoptimization support (via ReJIT on attach) for .NET Core 3.0 applications.-- Add symbols to NuGet package.-- Set additional metadata when uploading minidumps.-- Added an Initialized property to SnapshotCollectorTelemetryProcessor. It's a CancellationToken, which will be canceled when the Snapshot Collector is completely initialized and connected to the service endpoint.-- Snapshots can now be captured for exceptions in dynamically generated methods. For example, the compiled expression trees generated by Entity Framework queries.
+- Added symbols to NuGet package.
+- Set more metadata when you upload minidumps.
+- Added an `Initialized` property to `SnapshotCollectorTelemetryProcessor`. It's a `CancellationToken`, which is canceled when the Snapshot Collector is completely initialized and connected to the service endpoint.
+- Snapshots can now be captured for exceptions in dynamically generated methods. An example is the compiled expression trees generated by Entity Framework queries.
+ #### Bug fixes-- AmbiguousMatchException loading Snapshot Collector due to Status Monitor.-- GetSnapshotCollector extension method now searches all TelemetrySinks.
+- `AmbiguousMatchException` loading Snapshot Collector due to Status Monitor.
+- `GetSnapshotCollector` extension method now searches all `TelemetrySinks`.
- Don't start the Snapshot Uploader on unsupported platforms.-- Handle InvalidOperationException when deoptimizing dynamic methods (for example, Entity Framework)
+- Handle `InvalidOperationException` when you're deoptimizing dynamic methods (for example, Entity Framework).
### [1.3.5](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.5)-- Add support for Sovereign clouds (Older versions won't work in sovereign clouds)-- Adding snapshot collector made easier by using AddSnapshotCollector(). More information can be found [here](./snapshot-debugger-app-service.md).-- Use FISMA MD5 setting for verifying blob blocks. This avoids the default .NET MD5 crypto algorithm, which is unavailable when the OS is set to FIPS-compliant mode.-- Ignore .NET Framework frames when deoptimizing function calls. This behavior can be controlled by the DeoptimizeIgnoredModules configuration setting.-- Add `DeoptimizeMethodCount` configuration setting that allows deoptimization of more than one function call. More information here
+- Added support for sovereign clouds (older versions won't work in sovereign clouds).
+- Adding Snapshot Collector made easier by using `AddSnapshotCollector()`. For more information, see [Enable Snapshot Debugger for .NET apps in Azure App Service](./snapshot-debugger-app-service.md).
+- Use the FISMA MD5 setting for verifying blob blocks. This setting avoids the default .NET MD5 crypto algorithm, which is unavailable when the OS is set to FIPS-compliant mode.
+- Ignore .NET Framework frames when deoptimizing function calls. This behavior can be controlled by the `DeoptimizeIgnoredModules` configuration setting.
+- Added the `DeoptimizeMethodCount` configuration setting that allows deoptimization of more than one function call.
### [1.3.4](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.4)-- Allow structured Instrumentation Keys.-- Increase SnapshotUploader robustness - continue startup even if old uploader logs can't be moved.-- Re-enabled reporting additional telemetry when SnapshotUploader.exe exits immediately (was disabled in 1.3.3).-- Simplify internal telemetry.-- _Experimental feature_: Snappoint collection plans: Add "snapshotOnFirstOccurence". More information available [here](https://gist.github.com/alexaloni/5b4d069d17de0dabe384ea30e3f21dfe).
+- Allowed structured instrumentation keys.
+- Increased Snapshot Uploader robustness. Continue startup even if old uploader logs can't be moved.
+- Reenabled reporting more telemetry when *SnapshotUploader.exe* exits immediately (was disabled in 1.3.3).
+- Simplified internal telemetry.
+- **Experimental feature:** Snappoint collection plans: Add `snapshotOnFirstOccurence`. For more information, see [this GitHub article](https://gist.github.com/alexaloni/5b4d069d17de0dabe384ea30e3f21dfe).
### [1.3.3](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.3)-- Fixed bug that was causing SnapshotUploader.exe to stop responding and not upload snapshots for .NET Core apps.
+Fixed bug that was causing *SnapshotUploader.exe* to stop responding and not upload snapshots for .NET Core apps.
### [1.3.2](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.2)-- _Experimental feature_: Snappoint collection plans. More information available [here](https://gist.github.com/alexaloni/5b4d069d17de0dabe384ea30e3f21dfe).-- SnapshotUploader.exe will exit when the runtime unloads the AppDomain from which SnapshotCollector is loaded, instead of waiting for the process to exit. This improves the collector reliability when hosted in IIS.-- Add configuration to allow multiple SnapshotCollector instances that are using the same Instrumentation Key to share the same SnapshotUploader process: ShareUploaderProcess (defaults to `true`).-- Report additional telemetry when SnapshotUploader.exe exits immediately.-- Reduced the number of support files SnapshotUploader.exe needs to write to disk.
+- **Experimental feature:** Snappoint collection plans. For more information, see [this GitHub article](https://gist.github.com/alexaloni/5b4d069d17de0dabe384ea30e3f21dfe).
+- *SnapshotUploader.exe* exits when the runtime unloads the `AppDomain` from which `SnapshotCollector` is loaded, instead of waiting for the process to exit. This action improves the collector reliability when hosted in IIS.
+- Added configuration to allow multiple `SnapshotCollector` instances that are using the same instrumentation key to share the same `SnapshotUploader` process: `ShareUploaderProcess` (defaults to `true`).
+- Reported more telemetry when *SnapshotUploader.exe* exits immediately.
+- Reduced the number of support files *SnapshotUploader.exe* needs to write to disk.
### [1.3.1](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.1)-- Remove support for collecting snapshots with the RtlCloneUserProcess API and only support PssCaptureSnapshots API.-- Increase the default limit on how many snapshots can be captured in 10 minutes from 1 to 3.-- Allow SnapshotUploader.exe to negotiate TLS 1.1 and 1.2-- Report additional telemetry when SnapshotUploader logs a warning or an error-- Stop taking snapshots when the backend service reports the daily quota was reached (50 snapshots per day)-- Add extra check in SnapshotUploader.exe to not allow two instances to run in the same time.
+- Removed support for collecting snapshots with the RtlCloneUserProcess API and only support PssCaptureSnapshots API.
+- Increased the default limit on how many snapshots can be captured in 10 minutes from one to three.
+- Allow *SnapshotUploader.exe* to negotiate TLS 1.1 and 1.2.
+- Reported more telemetry when `SnapshotUploader` logs a warning or an error.
+- Stop taking snapshots when the back-end service reports the daily quota was reached (50 snapshots per day).
+- Added extra check in *SnapshotUploader.exe* to not allow two instances to run in the same time.
### [1.3.0](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.3.0) #### Changes-- For applications targeting .NET Framework, Snapshot Collector now depends on Microsoft.ApplicationInsights version 2.3.0 or above.
+- For applications that target .NET Framework, Snapshot Collector now depends on Microsoft.ApplicationInsights version 2.3.0 or above.
It used to be 2.2.0 or above.
-We believe this won't be an issue for most applications, but let us know if this change prevents you from using the latest Snapshot Collector.
+We believe this change won't be an issue for most applications. Let us know if this change prevents you from using the latest Snapshot Collector.
- Use exponential back-off delays in the Snapshot Uploader when retrying failed uploads.-- Use ServerTelemetryChannel (if available) for more reliable reporting of telemetry.-- Use 'SdkInternalOperationsMonitor' on the initial connection to the Snapshot Debugger service so that it's ignored by dependency tracking.-- Improve telemetry around initial connection to the Snapshot Debugger service.-- Report additional telemetry for:
- - Azure App Service version.
+- Use `ServerTelemetryChannel` (if available) for more reliable reporting of telemetry.
+- Use `SdkInternalOperationsMonitor` on the initial connection to the Snapshot Debugger service so that it's ignored by dependency tracking.
+- Improved telemetry around initial connection to Snapshot Debugger.
+- Report more telemetry for the:
+ - App Service version.
- Azure compute instances. - Containers.
- - Azure Function app.
+ - Azure Functions app.
+ #### Bug fixes - When the problem counter reset interval is set to 24 days, interpret that as 24 hours. - Fixed a bug where the Snapshot Uploader would stop processing new snapshots if there was an exception while disposing a snapshot. ### [1.2.3](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.2.3)-- Fix strong-name signing with Snapshot Uploader binaries.
+Fixed strong-name signing with Snapshot Uploader binaries.
### [1.2.2](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.2.2) #### Changes-- The files needed for SnapshotUploader(64).exe are now embedded as resources in the main DLL. That means the SnapshotCollectorFiles folder is no longer created, simplifying build and deployment and reducing clutter in Solution Explorer. Take care when upgrading to review the changes in your `.csproj` file. The `Microsoft.ApplicationInsights.SnapshotCollector.targets` file is no longer needed.-- Telemetry is logged to your Application Insights resource even if ProvideAnonymousTelemetry is set to false. This is so we can implement a health check feature in the Azure portal. ProvideAnonymousTelemetry affects only the telemetry sent to Microsoft for product support and improvement.-- When the TempFolder or ShadowCopyFolder are redirected to environment variables, keep the collector idle until those environment variables are set.-- For applications that connect to the Internet via a proxy server, Snapshot Collector will now autodetect any proxy settings and pass them on to SnapshotUploader.exe.-- Lower the priority of the SnapshotUplaoder process (where possible). This priority can be overridden via the IsLowPrioirtySnapshotUploader option.-- Added a GetSnapshotCollector extension method on TelemetryConfiguration for scenarios where you want to configure the Snapshot Collector programmatically.
+- The files needed for *SnapshotUploader(64).exe* are now embedded as resources in the main DLL. That means the `SnapshotCollectorFiles` folder is no longer created, which simplifies build and deployment and reduces clutter in Solution Explorer. Take care when you upgrade to review the changes in your `.csproj` file. The `Microsoft.ApplicationInsights.SnapshotCollector.targets` file is no longer needed.
+- Telemetry is logged to your Application Insights resource even if `ProvideAnonymousTelemetry` is set to false. This change is so that we can implement a health check feature in the Azure portal. `ProvideAnonymousTelemetry` affects only the telemetry sent to Microsoft for product support and improvement.
+- When `TempFolder` or `ShadowCopyFolder` are redirected to environment variables, keep the collector idle until those environment variables are set.
+- For applications that connect to the internet via a proxy server, Snapshot Collector now autodetects any proxy settings and passes them on to *SnapshotUploader.exe*.
+- Lower the priority of the `SnapshotUploader` process (where possible). This priority can be overridden via the `IsLowPrioirtySnapshotUploader` option.
+- Added a `GetSnapshotCollector` extension method on `TelemetryConfiguration` for scenarios where you want to configure the Snapshot Collector programmatically.
- Set the Application Insights SDK version (instead of the application version) in customer-facing telemetry. - Send the first heartbeat event after two minutes.+ #### Bug fixes-- Fix NullReferenceException when exceptions have null or immutable Data dictionaries.
+- Fixed `NullReferenceException` when exceptions have null or immutable Data dictionaries.
- In the uploader, retry PDB matching a few times if we get a sharing violation. - Fix duplicate telemetry when more than one thread calls into the telemetry pipeline at startup. ### [1.2.1](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.2.1) #### Changes - XML Doc comment files are now included in the NuGet package.-- Added an ExcludeFromSnapshotting extension method on `System.Exception` for scenarios where you know you have a noisy exception and want to avoid creating snapshots for it.-- Added an IsEnabledWhenProfiling configuration property, defaults to true. This is a change from previous versions where snapshot creation was temporarily disabled if the Application Insights Profiler was performing a detailed collection. The old behavior can be recovered by setting this property to false.
+- Added an `ExcludeFromSnapshotting` extension method on `System.Exception` for scenarios where you know you have a noisy exception and want to avoid creating snapshots for it.
+- Added an `IsEnabledWhenProfiling` configuration property that defaults to true. This is a change from previous versions where snapshot creation was temporarily disabled if the Application Insights Profiler was performing a detailed collection. The old behavior can be recovered by setting this property to `false`.
+ #### Bug fixes-- Sign SnapshotUploader64.exe properly.
+- Sign *SnapshotUploader64.exe* properly.
- Protect against double-initialization of the telemetry processor. - Prevent double logging of telemetry in apps with multiple pipelines.-- Fix a bug with the expiration time of a collection plan, which could prevent snapshots after 24 hours.
+- Fixed a bug with the expiration time of a collection plan, which could prevent snapshots after 24 hours.
### [1.2.0](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.2.0)
-The biggest change in this version (hence the move to a new minor version number) is a rewrite of the snapshot creation and handling pipeline. In previous versions, this functionality was implemented in native code (ProductionBreakpoints*.dll and SnapshotHolder*.exe). The new implementation is all managed code with P/Invokes. For this first version using the new pipeline, we haven't strayed far from the original behavior. The new implementation allows for better error reporting and sets us up for future improvements.
+The biggest change in this version (hence the move to a new minor version number) is a rewrite of the snapshot creation and handling pipeline. In previous versions, this functionality was implemented in native code (*ProductionBreakpoints*.dll* and *SnapshotHolder*.exe*). The new implementation is all managed code with P/Invokes.
+
+For this first version using the new pipeline, we haven't strayed far from the original behavior. The new implementation allows for better error reporting and sets us up for future improvements.
#### Other changes in this version-- MinidumpUploader.exe has been renamed to SnapshotUploader.exe (or SnapshotUploader64.exe).
+- *MinidumpUploader.exe* has been renamed to *SnapshotUploader.exe* (or *SnapshotUploader64.exe*).
- Added timing telemetry to DeOptimize/ReOptimize requests. - Added gzip compression for minidump uploads. - Fixed a problem where PDBs were locked preventing site upgrade.-- Log the original folder name (SnapshotCollectorFiles) when shadow-copying.-- Adjust memory limits for 64-bit processes to prevent site restarts due to OOM.-- Fix an issue where snapshots were still collected even after disabling.
+- Log the original folder name (*SnapshotCollectorFiles*) when shadow-copying.
+- Adjusted memory limits for 64-bit processes to prevent site restarts due to OOM.
+- Fixed an issue where snapshots were still collected even after disabling.
- Log heartbeat events to customer's AI resource.-- Improve snapshot speed by removing "Source" from Problem ID.
+- Improved snapshot speed by removing "Source" from the problem ID.
### [1.1.2](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.1.2) #### Changes-- Augmented usage telemetry-- Detect and report .NET version and OS-- Detect and report additional Azure Environments (Cloud Service, Service Fabric)-- Record and report exception metrics (number of 1st chance exceptions and number of TrackException calls) in Heartbeat telemetry.
+- Augmented usage telemetry.
+- Detect and report .NET version and OS.
+- Detect and report more Azure environments (Azure Cloud Services, Azure Service Fabric).
+- Record and report exception metrics (number of first-chance exceptions and the number of `TrackException` calls) in Heartbeat telemetry.
#### Bug fixes-- Correct handling of SqlException where the inner exception (Win32Exception) isn't thrown.-- Trim trailing spaces on symbol folders, which caused an incorrect parse of command-line arguments to the MinidumpUploader.-- Prevent infinite retry of failed connections to the Snapshot Debugger agent's endpoint.
+- Correct handling of `SqlException` where the inner exception (Win32Exception) isn't thrown.
+- Trimmed trailing spaces on symbol folders, which caused an incorrect parse of command-line arguments to the `MinidumpUploader`.
+- Prevented infinite retry of failed connections to the Snapshot Debugger agent's endpoint.
### [1.1.0](https://www.nuget.org/packages/Microsoft.ApplicationInsights.SnapshotCollector/1.1.0) #### Changes - Added host memory protection. This feature reduces the impact on the host machine's memory.-- Improve the Azure portal snapshot viewing experience.
+- Improved the Azure portal snapshot viewing experience.
## Next steps
-Enable Application Insights Snapshot Debugger for your application:
+Enable the Application Insights Snapshot Debugger for your application:
* [Azure App Service](snapshot-debugger-app-service.md?toc=/azure/azure-monitor/toc.json)
-* [Azure Function](snapshot-debugger-function-app.md?toc=/azure/azure-monitor/toc.json)
+* [Azure Functions](snapshot-debugger-function-app.md?toc=/azure/azure-monitor/toc.json)
* [Azure Cloud Services](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json)
-* [Azure Service Fabric services](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json)
+* [Azure Service Fabric](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json)
* [Azure Virtual Machines and Virtual Machine Scale Sets](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json) * [On-premises virtual or physical machines](snapshot-debugger-vm.md?toc=/azure/azure-monitor/toc.json)
Beyond Application Insights Snapshot Debugger:
* [Set snappoints in your code](/visualstudio/debugger/debug-live-azure-applications) to get snapshots without waiting for an exception. * [Diagnose exceptions in your web apps](../app/asp-net-exceptions.md) explains how to make more exceptions visible to Application Insights.
-* [Smart Detection](../alerts/proactive-diagnostics.md) automatically discovers performance anomalies.
+* [Smart detection](../alerts/proactive-diagnostics.md) automatically discovers performance anomalies.
azure-resource-manager Concepts View Definition https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/concepts-view-definition.md
Title: Overview of view definition description: Describes the concept of creating view definition for Azure Managed Applications. -- Last updated 08/25/2022
azure-resource-manager Create Ui Definition Collection Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-ui-definition-collection-functions.md
Title: Create UI definition collection functions description: Describes the functions to use when working with collections, like arrays and objects.-- Last updated 07/13/2020-- + # CreateUiDefinition collection functions These functions can be used with collections, like JSON strings, arrays and objects.
azure-resource-manager Create Ui Definition Conversion Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-ui-definition-conversion-functions.md
Title: Create UI definition conversion functions description: Describes the functions to use when converting values between data types and encodings.-- Last updated 07/13/2020-- + # CreateUiDefinition conversion functions These functions can be used to convert values between JSON data types and encodings.
azure-resource-manager Create Ui Definition Date Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-ui-definition-date-functions.md
Title: Create UI definition date functions description: Describes the functions to use when working with date values.-- Last updated 07/13/2020-- + # CreateUiDefinition date functions The functions to use when working with date values.
azure-resource-manager Create Ui Definition Logical Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-ui-definition-logical-functions.md
Title: Create UI definition logical functions description: Describes the functions to perform logical operations.-- Last updated 07/13/2020-- + # CreateUiDefinition logical functions These functions can be used in conditional expressions. Some functions may not support all JSON data types.
azure-resource-manager Create Ui Definition Math Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-ui-definition-math-functions.md
Title: Create UI definition math functions description: Describes the functions to use when performing math operations.-- Last updated 07/13/2020-- + # CreateUiDefinition math functions The functions enable you to perform math operations.
azure-resource-manager Create Ui Definition Referencing Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-ui-definition-referencing-functions.md
Title: Create UI definition referencing functions description: Describes the functions to use when constructing UI definitions for Azure portal that reference other objects.- Last updated 07/13/2020-- + # CreateUiDefinition referencing functions The functions to use when referencing outputs from the properties or context of a CreateUiDefinition file.
azure-resource-manager Create Ui Definition String Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-ui-definition-string-functions.md
Title: Create UI definition string functions description: Describes the string functions to use when constructing UI definitions for Azure Managed Applications-- Last updated 07/13/2020-- + # CreateUiDefinition string functions These functions to use with JSON strings.
The following example returns `"CONTOSO"`:
## Next steps * For an introduction to Azure Resource Manager, see [Azure Resource Manager overview](../management/overview.md).-
azure-resource-manager Create Uidefinition Elements https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-uidefinition-elements.md
Title: Create UI definition elements description: Describes the elements to use when constructing UI definitions for Azure portal.- Last updated 10/27/2020-- + # CreateUiDefinition elements This article describes the schema and properties for all supported elements of a CreateUiDefinition.
azure-resource-manager Create Uidefinition Functions https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-uidefinition-functions.md
Title: Create UI definition functions description: Describes the functions to use when constructing UI definitions for Azure Managed Applications-- Last updated 07/13/2020-- + # CreateUiDefinition functions This article provides an overview of the supported functions for CreateUiDefinition.
azure-resource-manager Create Uidefinition Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/create-uidefinition-overview.md
Title: CreateUiDefinition.json file for portal pane description: Describes how to create user interface definitions for the Azure portal. Used when defining Azure Managed Applications.-- Last updated 03/26/2021-- + # CreateUiDefinition.json for Azure managed application's create experience This document introduces the core concepts of the **createUiDefinition.json** file. The Azure portal uses this file to define the user interface when creating a managed application.
The basics config lets you customize the basics step.
For `description`, provide a markdown-enabled string that describes your resource. Multi-line format and links are supported.
-The `subscription` and `resourceGroup` elements enable you to specify more validations. The syntax for specifying validations is identical to the custom validation for [text box](microsoft-common-textbox.md). You can also specify `permission` validations on the subscription or resource group.
+The `subscription` and `resourceGroup` elements enable you to specify more validations. The syntax for specifying validations is identical to the custom validation for [text box](microsoft-common-textbox.md). You can also specify `permission` validations on the subscription or resource group.
-The subscription control accepts a list of resource provider namespaces. For example, you can specify **Microsoft.Compute**. It shows an error message when the user selects a subscription that doesn't support the resource provider. The error occurs when the resource provider isn't registered on that subscription, and the user doesn't have permission to register the resource provider.
+The subscription control accepts a list of resource provider namespaces. For example, you can specify **Microsoft.Compute**. It shows an error message when the user selects a subscription that doesn't support the resource provider. The error occurs when the resource provider isn't registered on that subscription, and the user doesn't have permission to register the resource provider.
-The resource group control has an option for `allowExisting`. When `true`, the users can select resource groups that already have resources. This flag is most applicable to solution templates, where default behavior mandates users must select a new or empty resource group. In most other scenarios, specifying this property isn't necessary.
+The resource group control has an option for `allowExisting`. When `true`, the users can select resource groups that already have resources. This flag is most applicable to solution templates, where default behavior mandates users must select a new or empty resource group. In most other scenarios, specifying this property isn't necessary.
-For `location`, specify the properties for the location control you wish to override. Any properties not overridden are set to their default values. `resourceTypes` accepts an array of strings containing fully qualified resource type names. The location options are restricted to only regions that support the resource types. `allowedValues` accepts an array of region strings. Only those regions appear in the dropdown. You can set both `allowedValues` and `resourceTypes`. The result is the intersection of both lists. Lastly, the `visible` property can be used to conditionally or completely disable the location dropdown. 
+For `location`, specify the properties for the location control you wish to override. Any properties not overridden are set to their default values. `resourceTypes` accepts an array of strings containing fully qualified resource type names. The location options are restricted to only regions that support the resource types. `allowedValues` accepts an array of region strings. Only those regions appear in the dropdown. You can set both `allowedValues` and `resourceTypes`. The result is the intersection of both lists. Lastly, the `visible` property can be used to conditionally or completely disable the location dropdown. 
## Basics
To filter the available locations to only those locations that support the resou
"resourceTypes": ["Microsoft.Compute/disks"], "basics": [ ...
-```
+```
## Functions
azure-resource-manager Deploy Marketplace App Quickstart https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/deploy-marketplace-app-quickstart.md
Title: Deploy an Azure Marketplace managed application description: Describes how to deploy an Azure Marketplace managed application using Azure portal.-- Last updated 04/25/2023
To get a managed application from the Azure portal, use the following steps.
:::image type="content" source="media/deploy-marketplace-app-quickstart/portal-setup.png" alt-text="Screenshot that shows the form's Setup your portal tab to deploy the managed application.":::
- - **Website name**: Enter a name that meets the criteria specified on the form, like _demotrainingsite_. Your website name should be globally unique across Azure.
+ - **Website name**: Enter a name that meets the criteria specified on the form, like _demotrainingsite_. Your website name should be globally unique across Azure.
- **Organization name**: Enter your organization's name. - **Contact email addresses**: Enter at least one valid email address.
To get a managed application from the Azure portal, use the following steps.
:::image type="content" source="media/deploy-marketplace-app-quickstart/portal-setup-login.png" alt-text="Screenshot that shows the form's Setup your login type tab to deploy the managed application."::: - **Login type**: For this example, select **Mobile**.
- - **Org admin's mobile number**: Enter a valid mobile phone number including the country/region code, in the format _+1 1234567890_. The phone number is used to sign in to the training site.
+ - **Org admin's mobile number**: Enter a valid mobile phone number including the country/region code, in the format _+1 1234567890_. The phone number is used to sign in to the training site.
1. Select **Next: Review + create**. 1. After **Validation passed** is displayed, verify the information is correct.
To get a managed application from the Azure portal, use the following steps.
1. Select **Create**.
-The deployment begins and because many resources are created, the Azure deployment takes about 20 minutes to finish. You can verify the Azure deployments before the website becomes available.
+The deployment begins and because many resources are created, the Azure deployment takes about 20 minutes to finish. You can verify the Azure deployments before the website becomes available.
## Verify the managed application deployment
After the managed application deployment is finished, you can verify the resourc
:::image type="content" source="media/deploy-marketplace-app-quickstart/mrg-apps.png" alt-text="Screenshot of the managed resource group that that highlights the deployments and list of deployed resources.":::
-1. To review the publisher's permissions in the managed resource group, select **Access Control (IAM)** > **Role assignments**.
+1. To review the publisher's permissions in the managed resource group, select **Access Control (IAM)** > **Role assignments**.
You can also verify the **Deny assignments**.
After the deployment is completed, from the managed resource group, you can go t
:::image type="content" source="media/deploy-marketplace-app-quickstart/app-service.png" alt-text="Screenshot of the App Service with the website link highlighted.":::
-The site might respond with a page that the deployment is still processing.
+The site might respond with a page that the deployment is still processing.
:::image type="content" source="media/deploy-marketplace-app-quickstart/deployment-message.png" alt-text="Screenshot that shows the website deployment is in progress.":::
When your website is available, a default sign-in page is displayed. You can sig
When you're finished with the managed application, you can delete the resource groups and that removes all the Azure resources you created. For example, in this quickstart you created the resource groups _demo-marketplace-app_ and a managed resource group with the prefix _mrg-microsoft-community-training_.
-When you delete the **demo-marketplace-app** resource group, the managed application, managed resource group, and all the Azure resources are deleted.
+When you delete the **demo-marketplace-app** resource group, the managed application, managed resource group, and all the Azure resources are deleted.
1. Go to the **demo-marketplace-app** resource group and **Delete resource group**.
azure-resource-manager Deploy Service Catalog Quickstart https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/deploy-service-catalog-quickstart.md
Title: Deploy a service catalog managed application description: Describes how to deploy a service catalog's managed application for an Azure Managed Application using Azure PowerShell, Azure CLI, or Azure portal.-- Last updated 03/21/2023
azure-resource-manager Existing Vnet Integration https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/existing-vnet-integration.md
Title: Deploy to existing virtual network description: Describes how to enable users of your managed application to select an existing virtual network. The virtual network can be outside of the managed application.-- Last updated 05/11/2020-- # Use existing virtual network with Azure Managed Applications
azure-resource-manager Microsoft Common Checkbox https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-checkbox.md
Title: CheckBox UI element description: Describes the Microsoft.Common.CheckBox UI element for Azure portal. Enables users to select to check or uncheck an option.-- Last updated 07/09/2020-- + # Microsoft.Common.CheckBox UI element The CheckBox control lets users check or uncheck an option. The control returns **true** when the control is checked or **false** when not checked.
azure-resource-manager Microsoft Common Dropdown https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-dropdown.md
Title: DropDown UI element description: Describes the Microsoft.Common.DropDown UI element for Azure portal. The element is used to select from the available options when deploying a managed application.-- Last updated 01/27/2023-- # Microsoft.Common.DropDown UI element
azure-resource-manager Microsoft Common Editablegrid https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-editablegrid.md
Title: EditableGrid UI element description: Describes the Microsoft.Common.EditableGrid UI element for Azure portal. Enables users to gather tabular input.- Last updated 08/24/2020- # Microsoft.Common.EditableGrid UI element
azure-resource-manager Microsoft Common Fileupload https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-fileupload.md
Title: FileUpload UI element description: Describes the Microsoft.Common.FileUpload UI element for Azure portal. Enables users need to upload files when deploying a managed application.-- Last updated 09/05/2018-- + # Microsoft.Common.FileUpload UI element A control that allows a user to specify one or more files to upload.
azure-resource-manager Microsoft Common Infobox https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-infobox.md
Title: InfoBox UI element description: Describes the Microsoft.Common.InfoBox UI element for Azure portal. Use to add text or warnings when deploying managed application.-- Last updated 06/15/2018-- # Microsoft.Common.InfoBox UI element
azure-resource-manager Microsoft Common Optionsgroup https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-optionsgroup.md
Title: OptionsGroup UI element description: Describes the Microsoft.Common.OptionsGroup UI element for Azure portal. Enables users to select from available options when deploying a managed application.-- Last updated 07/09/2020-- + # Microsoft.Common.OptionsGroup UI element The OptionsGroup control lets users select one option from two or more choices. A user can select only one option.
azure-resource-manager Microsoft Common Passwordbox https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-passwordbox.md
Title: PasswordBox UI element description: Describes the Microsoft.Common.PasswordBox UI element for Azure portal. Enables users to provide a secret value when deploying managed applications.-- Last updated 06/27/2018-- + # Microsoft.Common.PasswordBox UI element A control that can be used to provide and confirm a password.
azure-resource-manager Microsoft Common Section https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-section.md
Title: Section UI element description: Describes the Microsoft.Common.Section UI element for Azure portal. Use to group elements in the portal for deploying managed applications.-- Last updated 06/27/2018-- + # Microsoft.Common.Section UI element A control that groups one or more elements under a heading.
azure-resource-manager Microsoft Common Serviceprincipalselector https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-serviceprincipalselector.md
Title: ServicePrincipalSelector UI element description: Describes the Microsoft.Common.ServicePrincipalSelector UI element for Azure portal. Provides a control to choose an application and a textbox to input a password or certificate thumbprint.- Last updated 11/17/2020- # Microsoft.Common.ServicePrincipalSelector UI element
When **Create new** or an existing application is selected from the control the
## Next steps - For an introduction to creating UI definitions, see [Getting started with CreateUiDefinition](create-uidefinition-overview.md).-- For a description of common properties in UI elements, see [CreateUiDefinition elements](create-uidefinition-elements.md).
+- For a description of common properties in UI elements, see [CreateUiDefinition elements](create-uidefinition-elements.md).
azure-resource-manager Microsoft Common Slider https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-slider.md
Title: Slider UI element description: Describes the Microsoft.Common.Slider UI element for Azure portal. Enables users to set a value from a range of options.-- Last updated 07/10/2020-- + # Microsoft.Common.Slider UI element The Slider control lets users select from a range of allowed values.
azure-resource-manager Microsoft Common Tagsbyresource https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-tagsbyresource.md
Title: TagsByResource UI element description: Describes the Microsoft.Common.TagsByResource UI element for Azure portal. Use to apply tags to a resource during deployment.-- Last updated 11/11/2019-- # Microsoft.Common.TagsByResource UI element
azure-resource-manager Microsoft Common Textblock https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-textblock.md
Title: TextBlock UI element description: Describes the Microsoft.Common.TextBlock UI element for Azure portal. Use to add text to the interface.-- Last updated 06/27/2018-- # Microsoft.Common.TextBlock UI element
azure-resource-manager Microsoft Common Textbox https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-common-textbox.md
Title: TextBox UI element description: Describes the Microsoft.Common.TextBox UI element for Azure portal that's used for adding unformatted text.-- Last updated 08/23/2022
azure-resource-manager Microsoft Compute Credentialscombo https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-compute-credentialscombo.md
Title: CredentialsCombo UI element description: Describes the Microsoft.Compute.CredentialsCombo UI element for Azure portal.-- Last updated 08/01/2022
azure-resource-manager Microsoft Compute Sizeselector https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-compute-sizeselector.md
Title: SizeSelector UI element description: Describes the Microsoft.Compute.SizeSelector UI element for Azure portal. Use for selecting the size of a virtual machine.-- Last updated 06/27/2018-- + # Microsoft.Compute.SizeSelector UI element A control for selecting a size for one or more virtual machine instances.
azure-resource-manager Microsoft Compute Usernametextbox https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-compute-usernametextbox.md
Title: UserNameTextBox UI element description: Describes the Microsoft.Compute.UserNameTextBox UI element for Azure portal. Enables users to provide Windows or Linux user names.-- Last updated 06/27/2018-- + # Microsoft.Compute.UserNameTextBox UI element A text box control with built-in validation for Windows and Linux user names.
azure-resource-manager Microsoft Keyvault Keyvaultcertificateselector https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-keyvault-keyvaultcertificateselector.md
Title: KeyVaultCertificateSelector UI element description: Describes the Microsoft.KeyVault.KeyVaultCertificateSelector UI element for Azure portal.- Last updated 10/27/2020-- + # Microsoft.KeyVault.KeyVaultCertificateSelector UI element A control for selecting a key vault certificate.
azure-resource-manager Microsoft Managedidentity Identityselector https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-managedidentity-identityselector.md
Title: IdentitySelector UI element description: Describes the Microsoft.ManagedIdentity.IdentitySelector UI element for Azure portal. Use to assign managed identities to a resource.-- Last updated 02/06/2020-- # Microsoft.ManagedIdentity.IdentitySelector UI element
The selected identities are displayed in the table. The user can add or delete i
- Use **defaultValue.systemAssignedIdentity** to set an initial value for the system assigned identity options control. The default value is **Off**. The following values are allowed: - **On** ΓÇô A system assigned identity is assigned to the resource. - **Off** ΓÇô A system assigned identity isn't assigned to the resource.
- - **OnOnly** ΓÇô A system assigned identity is assigned to the resource. Users can't edit this value during deployment.
+ - **OnOnly** ΓÇô A system assigned identity is assigned to the resource. Users can't edit this value during deployment.
- **OffOnly** ΓÇô A system assigned identity isn't assigned to the resource. Users can't edit this value during deployment. - If **options.hideSystemAssignedIdentity** is set to **true**, the UI to configure the system assigned identity isn't displayed. The default value for this option is **false**.
The selected identities are displayed in the table. The user can add or delete i
## Next steps - For an introduction to creating UI definitions, see [Getting started with CreateUiDefinition](create-uidefinition-overview.md).-- For a description of common properties in UI elements, see [CreateUiDefinition elements](create-uidefinition-elements.md).
+- For a description of common properties in UI elements, see [CreateUiDefinition elements](create-uidefinition-elements.md).
azure-resource-manager Microsoft Network Publicipaddresscombo https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-network-publicipaddresscombo.md
Title: PublicIpAddressCombo UI element description: Describes the Microsoft.Network.PublicIpAddressCombo UI element for Azure portal.-- Last updated 06/28/2018-- + # Microsoft.Network.PublicIpAddressCombo UI element A group of controls for selecting a new or existing public IP address.
azure-resource-manager Microsoft Network Virtualnetworkcombo https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-network-virtualnetworkcombo.md
Title: VirtualNetworkCombo UI element description: Describes the Microsoft.Network.VirtualNetworkCombo UI element for Azure portal.-- Last updated 06/28/2018-- + # Microsoft.Network.VirtualNetworkCombo UI element A group of controls for selecting a new or existing virtual network.
azure-resource-manager Microsoft Solutions Armapicontrol https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-solutions-armapicontrol.md
Title: ArmApiControl UI element description: Describes the Microsoft.Solutions.ArmApiControl UI element for Azure portal that's used to call API operations.-- Last updated 08/23/2022
azure-resource-manager Microsoft Solutions Resourceselector https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-solutions-resourceselector.md
Title: ResourceSelector UI element description: Describes the Microsoft.Solutions.ResourceSelector UI element for Azure portal. Used for getting a list of existing resources.-- Last updated 08/16/2022
azure-resource-manager Microsoft Storage Multistorageaccountcombo https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-storage-multistorageaccountcombo.md
Title: MultiStorageAccountCombo UI element description: Describes the Microsoft.Storage.MultiStorageAccountCombo UI element for Azure portal.-- Last updated 06/28/2018-- + # Microsoft.Storage.MultiStorageAccountCombo UI element A group of controls for creating several storage accounts with names that start with a common prefix.
azure-resource-manager Microsoft Storage Storageaccountselector https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-storage-storageaccountselector.md
Title: StorageAccountSelector UI element description: Describes the Microsoft.Storage.StorageAccountSelector UI element for Azure portal.-- Last updated 03/17/2023
azure-resource-manager Microsoft Storage Storageblobselector https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/microsoft-storage-storageblobselector.md
Title: StorageBlobSelector UI element description: Describes the Microsoft.Storage.StorageBlobSelector UI element for Azure portal.- Last updated 10/27/2020-- + # Microsoft.Storage.StorageBlobSelector UI element A control for selecting a blob from an Azure storage account.
azure-resource-manager Monitor Managed Application Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/monitor-managed-application-portal.md
Title: Use Azure portal to monitor a managed app description: Shows how to use the Azure portal to monitor availability and alerts for a managed application.-- Last updated 10/04/2018- + # Monitor a deployed instance of a managed application After you've deployed a managed application to your Azure subscription, you may want to check the status of the application. This article shows options in the Azure portal for checking the status. You can monitor the availability of the resources in your managed application. You can also set up and view alerts.
You can create alerts for your managed application instance or the resources in
## Next steps * For managed application examples, see [Sample projects for Azure managed applications](sample-projects.md).
-* To deploy a managed application, see [Deploy service catalog app through Azure portal](deploy-service-catalog-quickstart.md).
+* To deploy a managed application, see [Deploy service catalog app through Azure portal](deploy-service-catalog-quickstart.md).
azure-resource-manager Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/overview.md
Title: Overview of Azure Managed Applications description: Describes the concepts for Azure Managed Applications that provide cloud solutions that are easy for customers to deploy and operate.-- Last updated 08/19/2022
azure-resource-manager Policy Reference https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/policy-reference.md
Title: Built-in policy definitions for Azure Managed Applications
description: Lists Azure Policy built-in policy definitions for Azure Managed Applications. These built-in policy definitions provide common approaches to managing your Azure resources. Last updated 02/21/2023 -- + # Azure Policy built-in definitions for Azure Managed Applications This page is an index of [Azure Policy](../../governance/policy/overview.md) built-in policy
azure-resource-manager Publish Managed Identity https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/publish-managed-identity.md
Title: Managed app with Managed Identity
-description: Configure Managed Application with Managed Identity for linking to existing resources, managing Azure resources, and providing operational identity for Activity Log.
+ Title: Managed app with managed identity
+description: Configure an Azure Managed Application with managed identity for linking to existing resources, managing Azure resources, and providing operational identity for Activity Log.
-- Previously updated : 05/13/2019 Last updated : 05/01/2023
-# Azure Managed Application with Managed Identity
+
+# Azure Managed Application with managed identity
> [!NOTE]
-> Managed Identity support for Managed Applications is currently in preview. Please use the 2018-09-01-preview api version to utilize Managed Identity.
+> Managed identity support for Azure Managed Applications is currently in preview. Please use the 2018-09-01-preview api version to utilize managed identity.
-Learn how to configure a Managed Application to contain a Managed Identity. Managed Identity can be used to allow the customer to grant the Managed Application access to additional existing resources. The identity is managed by the Azure platform and does not require you to provision or rotate any secrets. For more about managed identities in Azure Active Directory (AAD), see [Managed identities for Azure resources](../../active-directory/managed-identities-azure-resources/overview.md).
+Learn how to configure a managed application to contain a managed identity. A managed identity can be used to allow the customer to grant the managed application access to existing resources. The identity is managed by the Azure platform and doesn't require you to provision or rotate any secrets. For more about managed identities in Azure Active Directory (Azure AD), see [Managed identities for Azure resources](../../active-directory/managed-identities-azure-resources/overview.md).
Your application can be granted two types of identities: -- A **system-assigned identity** is tied to your application and is deleted if your app is deleted. An app can only have one system-assigned identity.-- A **user-assigned identity** is a standalone Azure resource that can be assigned to your app. An app can have multiple user-assigned identities.
+- A **system-assigned managed identity** is tied to your application and is deleted if your app is deleted. An app can only have one system-assigned managed identity.
+- A **user-assigned managed identity** is a standalone Azure resource that can be assigned to your app. An app can have multiple user-assigned managed identities.
-## How to use Managed Identity
+## How to use managed identity
-Managed Identity enables many scenarios for Managed Applications. Some common scenarios that can be solved are:
+Managed identity enables many scenarios for managed applications. Some common scenarios that can be solved are:
-- Deploying a Managed Application linked to existing Azure resources. An example is deploying an Azure virtual machine (VM) within the Managed Application that is attached to an [existing network interface](../../virtual-network/virtual-network-network-interface-vm.md).-- Granting the Managed Application and publisher access to Azure resources outside the **managed resource group**.-- Providing an operational identity of Managed Applications for Activity Log and other services within Azure.
+- Deploying a managed application linked to existing Azure resources. An example is deploying an Azure virtual machine (VM) within the managed application that is attached to an [existing network interface](../../virtual-network/virtual-network-network-interface-vm.md).
+- Granting the managed application and publisher access to Azure resources outside the managed resource group.
+- Providing an operational identity of managed applications for Activity Log and other services within Azure.
-## Adding Managed Identity
+## Adding managed identity
-Creating a Managed Application with a Managed Identity requires an additional property to be set on the Azure resource. The following example shows a sample **identity** property:
+Creating a managed application with a managed identity requires another property to be set on the Azure resource. The following example shows a sample **identity** property:
```json { "identity": {
- "type": "SystemAssigned, UserAssigned",
- "userAssignedIdentities": {
- "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/testRG/providers/Microsoft.ManagedIdentity/userassignedidentites/myuserassignedidentity": {}
- }
+ "type": "SystemAssigned, UserAssigned",
+ "userAssignedIdentities": {
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/testRG/providers/Microsoft.ManagedIdentity/userassignedidentites/myuserassignedidentity": {}
+ }
} ```
-There are two common ways to create a Managed Application with **identity**: [CreateUIDefinition.json](./create-uidefinition-overview.md) and [Azure Resource Manager templates](../templates/syntax.md). For simple single create scenarios, CreateUIDefinition should be used to enable Managed Identity, because it provides a richer experience. However, when dealing with advanced or complex systems that require automated or multiple Managed Application deployments, templates can be used.
+There are two common ways to create a managed application with **identity**: [createUiDefinition.json](./create-uidefinition-overview.md) and [Azure Resource Manager templates](../templates/syntax.md). For simple single create scenarios, _createUiDefinition_ should be used to enable managed identity, because it provides a richer experience. However, when dealing with advanced or complex systems that require automated or multiple managed application deployments, templates can be used.
-### Using CreateUIDefinition
+### Using createUiDefinition
-A Managed Application can be configured with Managed Identity through the [CreateUIDefinition.json](./create-uidefinition-overview.md). In the [outputs section](./create-uidefinition-overview.md#outputs), the key `managedIdentity` can be used to override the identity property of the Managed Application template. The sample below will enable **system-assigned** identity on the Managed Application. More complex identity objects can be formed by using CreateUIDefinition elements to ask the consumer for inputs. These inputs can be used to construct Managed Applications with **user-assigned identity**.
+A managed application can be configured with managed identity through the [createUiDefinition.json](./create-uidefinition-overview.md). In the [outputs section](./create-uidefinition-overview.md#outputs), the key `managedIdentity` can be used to override the identity property of the managed application template. The following sample enables a system-assigned managed identity on the managed application. More complex identity objects can be formed by using _createUiDefinition_ elements to ask the consumer for inputs. These inputs can be used to construct managed applications with user-assigned managed identity.
```json "outputs": {
- "managedIdentity": { "Type": "SystemAssigned" }
+ "managedIdentity": { "Type": "SystemAssigned" }
} ```
-#### When to use CreateUIDefinition for Managed Identity
+#### When to use createUiDefinition for managed identity
-Below are some recommendations on when to use CreateUIDefinition for enabling Managed Identity on Managed Applications.
+The following are some recommendations on when to use _createUiDefinition_ to enable a managed identity on managed applications.
-- The Managed Application creation goes through the Azure portal or marketplace.-- The Managed Identity requires complex consumer input.-- The Managed Identity is needed on creation of the Managed Application.
+- The managed application creation goes through the Azure portal or Azure Marketplace.
+- The managed identity requires complex consumer input.
+- The managed identity is needed on creation of the managed application.
-#### Managed Identity CreateUIDefinition control
+#### Managed identity createUiDefinition control
-CreateUIDefinition supports a built-in [Managed Identity control](./microsoft-managedidentity-identityselector.md).
+The _createUiDefinition.json_ supports a built-in [managed identity control](./microsoft-managedidentity-identityselector.md).
```json {
CreateUIDefinition supports a built-in [Managed Identity control](./microsoft-ma
} ```
-![Managed Identity CreateUIDefinition](./media/publish-managed-identity/msi-cuid.png)
### Using Azure Resource Manager templates > [!NOTE]
-> Marketplace Managed Application templates are automatically generated for customers going through the Azure portal create experience.
-> For these scenarios, the `managedIdentity` output key on the CreateUIDefinition must be used to enabled identity.
+> Marketplace managed application templates are automatically generated for customers going through the Azure portal create experience.
+> For these scenarios, the `managedIdentity` output key on the _createUiDefinition_ must be used to enabled identity.
-The Managed Identity can also be enabled through Azure Resource Manager templates. The sample bellow will enable **system-assigned** identity on the Managed Application. More complex identity objects can be formed by using Azure Resource Manager template parameters to provide inputs. These inputs can be used to construct Managed Applications with **user-assigned identity**.
+The managed identity can also be enabled through Azure Resource Manager templates. The following sample enables a system-assigned managed identity on the managed application. More complex identity objects can be formed by using Azure Resource Manager template parameters to provide inputs. These inputs can be used to construct managed applications with user-assigned managed identity.
-#### When to use Azure Resource Manager templates for Managed Identity
+#### When to use Azure Resource Manager templates for managed identity
-Below are some recommendations on when to use Azure Resource Manager templates for enabling Managed Identity on Managed Applications.
+The following are some recommendations on when to use Azure Resource Manager templates for enabling managed identity on managed applications.
-- Managed Applications can be programmatically deployed based on a template.-- Custom role assignments for the Managed Identity are needed to provision the Managed Application.-- The Managed Application does not need the Azure portal and marketplace creation flow.
+- Managed applications can be programmatically deployed based on a template.
+- Custom role assignments for the managed identity are needed to provision the managed application.
+- The managed application doesn't need the Azure portal and Marketplace creation flow.
#### SystemAssigned template
-A basic Azure Resource Manager template that deploys a Managed Application with **system-assigned** identity.
+A basic Azure Resource Manager template that deploys a managed application with system-assigned managed identity.
```json "resources": [
- {
- "type": "Microsoft.Solutions/applications",
- "name": "[parameters('applicationName')]",
- "apiVersion": "2018-09-01-preview",
- "location": "[parameters('location')]",
- "identity": {
- "type": "SystemAssigned"
- },
- "properties": {
- "ManagedResourceGroupId": "[parameters('managedByResourceGroupId')]",
- "parameters": { }
- }
+ {
+ "type": "Microsoft.Solutions/applications",
+ "name": "[parameters('applicationName')]",
+ "apiVersion": "2018-09-01-preview",
+ "location": "[parameters('location')]",
+ "identity": {
+ "type": "SystemAssigned"
+ },
+ "properties": {
+ "ManagedResourceGroupId": "[parameters('managedByResourceGroupId')]",
+ "parameters": { }
}
+ }
] ``` ### UserAssigned template
-A basic Azure Resource Manager template that deploys a Managed Application with a **user-assigned identity**.
+A basic Azure Resource Manager template that deploys a managed application with a user-assigned managed identity.
```json "resources": [
- {
- "type": "Microsoft.ManagedIdentity/userAssignedIdentities",
- "name": "[parameters('managedIdentityName')]",
- "apiVersion": "2018-11-30",
- "location": "[parameters('location')]"
- },
- {
- "type": "Microsoft.Solutions/applications",
- "name": "[parameters('applicationName')]",
- "apiVersion": "2018-09-01-preview",
- "location": "[parameters('location')]",
- "identity": {
- "type": "UserAssigned",
- "userAssignedIdentities": {
- "[resourceID('Microsoft.ManagedIdentity/userAssignedIdentities/',parameters('managedIdentityName'))]": {}
- }
- },
- "properties": {
- "ManagedResourceGroupId": "[parameters('managedByResourceGroupId')]",
- "parameters": { }
+ {
+ "type": "Microsoft.ManagedIdentity/userAssignedIdentities",
+ "name": "[parameters('managedIdentityName')]",
+ "apiVersion": "2018-11-30",
+ "location": "[parameters('location')]"
+ },
+ {
+ "type": "Microsoft.Solutions/applications",
+ "name": "[parameters('applicationName')]",
+ "apiVersion": "2018-09-01-preview",
+ "location": "[parameters('location')]",
+ "identity": {
+ "type": "UserAssigned",
+ "userAssignedIdentities": {
+ "[resourceID('Microsoft.ManagedIdentity/userAssignedIdentities/',parameters('managedIdentityName'))]": {}
}
+ },
+ "properties": {
+ "ManagedResourceGroupId": "[parameters('managedByResourceGroupId')]",
+ "parameters": { }
}
+ }
] ``` ## Granting access to Azure resources
-Once a Managed Application is granted an identity, it can be granted access to existing Azure resources by creating a role assignment.
+Once a managed application is granted an identity, it can be granted access to existing Azure resources by creating a role assignment.
-To do so, search for and select the name of the Managed Application or **user-assigned identity**, and then select **Access control (IAM)**. For detailed steps, see [Assign Azure roles using the Azure portal](../../role-based-access-control/role-assignments-portal.md).
+To do so, search for and select the name of the managed application or user-assigned managed identity, and then select **Access control (IAM)**. For detailed steps, see [Assign Azure roles using the Azure portal](../../role-based-access-control/role-assignments-portal.md).
## Linking existing Azure resources > [!NOTE]
-> A **user-assigned identity** must be [configured](../../active-directory/managed-identities-azure-resources/how-to-manage-ua-identity-portal.md) before deploying the Managed Application. In addition, linked resource deployment of Managed Applications is only supported for the **marketplace** kind.
+> A user-assigned managed identity must be [configured](../../active-directory/managed-identities-azure-resources/how-manage-user-assigned-managed-identities.md) before deploying the managed application. In addition, linked resource deployment of managed applications is only supported for the _Marketplace_ kind.
-Managed Identity can also be used to deploy a Managed Application that requires access to existing resources during its deployment. When the Managed Application is provisioned by the customer, **user-assigned identities** can be added to provide additional authorizations to the **mainTemplate** deployment.
+Managed identity can also be used to deploy a managed application that requires access to existing resources during its deployment. When the customer provisions the managed application, user-assigned managed identities can be added to provide more authorizations to the _mainTemplate_ deployment.
-### Authoring the CreateUIDefinition with a linked resource
+### Authoring the createUiDefinition with a linked resource
-When linking the deployment of the Managed Application to existing resources, both the existing Azure resource and a **user-assigned identity** with the applicable role assignment on that resource must be provided.
+When linking the deployment of the managed application to existing resources, both the existing Azure resource and a user-assigned managed identity with the applicable role assignment on that resource must be provided.
- A sample CreateUIDefinition that requires two inputs: a network interface resource ID and a user assigned identity resource ID.
+ A sample _createUiDefinition.json_ that requires two inputs: a network interface resource ID and a user assigned managed identity resource ID.
```json {
- "$schema": "https://schema.management.azure.com/schemas/0.1.2-preview/CreateUIDefinition.MultiVm.json#",
- "handler": "Microsoft.Compute.MultiVm",
- "version": "0.1.2-preview",
- "parameters": {
- "basics": [
- {}
- ],
- "steps": [
- {
- "name": "managedApplicationSetting",
- "label": "Managed Application Settings",
- "subLabel": {
- "preValidation": "Managed Application Settings",
- "postValidation": "Done"
- },
- "bladeTitle": "Managed Application Settings",
- "elements": [
- {
- "name": "networkInterfaceId",
- "type": "Microsoft.Common.TextBox",
- "label": "network interface resource id",
- "defaultValue": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/testRG/providers/Microsoft.Network/networkInterfaces/existingnetworkinterface",
- "toolTip": "Must represent the identity as an Azure Resource Manager resource identifer format ex. /subscriptions/sub1/resourcegroups/myGroup/providers/Microsoft.Network/networkInterfaces/networkinterface1",
- "visible": true
- },
- {
- "name": "userAssignedId",
- "type": "Microsoft.Common.TextBox",
- "label": "user assigned identity resource id",
- "defaultValue": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/testRG/providers/Microsoft.ManagedIdentity/userassignedidentites/myuserassignedidentity",
- "toolTip": "Must represent the identity as an Azure Resource Manager resource identifer format ex. /subscriptions/sub1/resourcegroups/myGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1",
- "visible": true
- }
- ]
- }
- ],
- "outputs": {
- "existingNetworkInterfaceId": "[steps('managedApplicationSetting').networkInterfaceId]",
- "managedIdentity": "[parse(concat('{\"Type\":\"UserAssigned\",\"UserAssignedIdentities\":{',string(steps('managedApplicationSetting').userAssignedId),':{}}}'))]"
- }
+ "$schema": "https://schema.management.azure.com/schemas/0.1.2-preview/CreateUIDefinition.MultiVm.json#",
+ "handler": "Microsoft.Azure.CreateUIDef",
+ "version": "0.1.2-preview",
+ "parameters": {
+ "basics": [
+ {}
+ ],
+ "steps": [
+ {
+ "name": "managedApplicationSetting",
+ "label": "Managed Application Settings",
+ "subLabel": {
+ "preValidation": "Managed Application Settings",
+ "postValidation": "Done"
+ },
+ "bladeTitle": "Managed Application Settings",
+ "elements": [
+ {
+ "name": "networkInterfaceId",
+ "type": "Microsoft.Common.TextBox",
+ "label": "Network interface resource ID",
+ "defaultValue": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/testRG/providers/Microsoft.Network/networkInterfaces/existingnetworkinterface",
+ "toolTip": "Must represent the identity as an Azure Resource Manager resource identifer format ex. /subscriptions/sub1/resourcegroups/myGroup/providers/Microsoft.Network/networkInterfaces/networkinterface1",
+ "visible": true
+ },
+ {
+ "name": "userAssignedId",
+ "type": "Microsoft.Common.TextBox",
+ "label": "User-assigned managed identity resource ID",
+ "defaultValue": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/testRG/providers/Microsoft.ManagedIdentity/userassignedidentites/myuserassignedidentity",
+ "toolTip": "Must represent the identity as an Azure Resource Manager resource identifer format ex. /subscriptions/sub1/resourcegroups/myGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity1",
+ "visible": true
+ }
+ ]
+ }
+ ],
+ "outputs": {
+ "existingNetworkInterfaceId": "[steps('managedApplicationSetting').networkInterfaceId]",
+ "managedIdentity": "[parse(concat('{\"Type\":\"UserAssigned\",\"UserAssignedIdentities\":{',string(steps('managedApplicationSetting').userAssignedId),':{}}}'))]"
}
+ }
} ```
-This CreateUIDefinition.json generates a create user experience that has two fields. The first field allows the user to enter in the Azure resource ID for the resource being linked to the Managed Application deployment. The second is for a consumer to enter the **user-assigned identity** Azure resource ID, which has access to the linked Azure resource. The generated experience would look like:
+This _createUiDefinition.json_ generates a create user experience that has two fields. The first field allows the user to enter in the Azure resource ID for the resource being linked to the managed application deployment. The second is for a consumer to enter the user-assigned managed identity Azure resource ID, which has access to the linked Azure resource. The generated experience would look like:
-![Sample CreateUIDefinition with two inputs: a network interface resource ID and a user assigned identity resource ID](./media/publish-managed-identity/network-interface-cuid.png)
### Authoring the mainTemplate with a linked resource
-In addition to updating the CreateUIDefinition, the main template also needs to be updated to accept the passed in linked resource ID. The main template can be updated to accept the new output by adding a new parameter. Since the `managedIdentity` output overrides the value on the generated Managed Application template, it is not passed to the main template and should not be included in the parameters section.
+In addition to updating the _createUiDefinition_, the main template also needs to be updated to accept the passed in linked resource ID. The main template can be updated to accept the new output by adding a new parameter. Since the `managedIdentity` output overrides the value on the generated managed application template, it isn't passed to the main template and shouldn't be included in the parameters section.
-A sample main template that sets the network profile to an existing network interface provided by the CreateUIDefinition.
+A sample main template that sets the network profile to an existing network interface provided by the _createUiDefinition.json_.
```json {
- "$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
- "contentVersion": "1.0.0.0",
- "parameters": {
- "existingNetworkInterfaceId": { "type": "string" }
- },
- "variables": {
- },
- "resources": [
- {
- "apiVersion": "2016-04-30-preview",
- "type": "Microsoft.Compute/virtualMachines",
- "name": "myLinkedResourceVM",
- "location": "[resourceGroup().location]",
- "properties": {
- …,
- "networkProfile": {
- "networkInterfaces": [
- {
- "id": "[parameters('existingNetworkInterfaceId')]"
- }
- ]
- }
+ "$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
+ "contentVersion": "1.0.0.0",
+ "parameters": {
+ "existingNetworkInterfaceId": { "type": "string" }
+ },
+ "variables": {
+ },
+ "resources": [
+ {
+ "apiVersion": "2016-04-30-preview",
+ "type": "Microsoft.Compute/virtualMachines",
+ "name": "myLinkedResourceVM",
+ "location": "[resourceGroup().location]",
+ "properties": {
+ …,
+ "networkProfile": {
+ "networkInterfaces": [
+ {
+ "id": "[parameters('existingNetworkInterfaceId')]"
}
+ ]
}
- ]
+ }
+ }
+ ]
} ```
-### Consuming the Managed Application with a linked resource
+### Consuming the managed application with a linked resource
-Once the Managed Application package is created, the Managed Application can be consumed through the Azure portal. Before it can be consumed, there are several prerequisite steps.
+Once the managed application package is created, the managed application can be consumed through the Azure portal. Before it can be consumed, there are several prerequisite steps.
- An instance of the required linked Azure resource must be created.-- The **user-assigned identity** must be [created and given role assignments](../../active-directory/managed-identities-azure-resources/how-to-manage-ua-identity-portal.md) to the linked resource.-- The existing linked resource ID and the **user-assigned identity** ID are provided to the CreateUIDefinition.
+- The user-assigned managed identity must be [created and given role assignments](../../active-directory/managed-identities-azure-resources/how-to-manage-ua-identity-portal.md) to the linked resource.
+- The existing linked resource ID and the user-assigned managed identity ID are provided to the _createUiDefinition_.
-## Accessing the Managed Identity token
+## Accessing the managed identity token
-The token of the Managed Application can now be accessed through the `listTokens` api from the publisher tenant. An example request might look like:
+The token of the managed application can now be accessed through the `listTokens` api from the publisher tenant. An example request might look like:
```http POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Solutions/applications/{applicationName}/listTokens?api-version=2018-09-01-preview HTTP/1.1 {
- "authorizationAudience": "https://management.azure.com/",
- "userAssignedIdentities": [
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{userAssignedIdentityName}"
- ]
+ "authorizationAudience": "https://management.azure.com/",
+ "userAssignedIdentities": [
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{userAssignedIdentityName}"
+ ]
} ``` Request Body Parameters:
-Parameter | Required | Description
-||
-authorizationAudience | *no* | The App ID URI of the target resource. It also is the `aud` (audience) claim of the issued token. The default value is "https://management.azure.com/"
-userAssignedIdentities | *no* | The list of user-assigned managed identities to retrieve a token for. If not specified, `listTokens` will return the token for the system-assigned managed identity.
+| Parameter | Required | Description |
+| || |
+| `authorizationAudience` | _no_ | The App ID URI of the target resource. It also is the `aud` (audience) claim of the issued token. The default value is "https://management.azure.com/" |
+| `userAssignedIdentities` | _no_ | The list of user-assigned managed identities to retrieve a token for. If not specified, `listTokens` returns the token for the system-assigned managed identity. |
A sample response might look like:
HTTP/1.1 200 OK
Content-Type: application/json {
- "value": [
- {
- "access_token": "eyJ0eXAi…",
- "expires_in": "2…",
- "expires_on": "1557…",
- "not_before": "1557…",
- "authorizationAudience": "https://management.azure.com/",
- "resourceId": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Solutions/applications/{applicationName}",
- "token_type": "Bearer"
- }
- ]
+ "value": [
+ {
+ "access_token": "eyJ0eXAi…",
+ "expires_in": "2…",
+ "expires_on": "1557…",
+ "not_before": "1557…",
+ "authorizationAudience": "https://management.azure.com/",
+ "resourceId": "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Solutions/applications/{applicationName}",
+ "token_type": "Bearer"
+ }
+ ]
} ```
-The response will contain an array of tokens under the `value` property:
+The response contains an array of tokens under the `value` property:
-Parameter | Description
-|
-access_token | The requested access token.
-expires_in | The number of seconds the access token will be valid.
-expires_on | The timespan when the access token expires. This is represented as the number of seconds from epoch.
-not_before | The timespan when the access token takes effect. This is represented as the number of seconds from epoch.
-authorizationAudience | The `aud` (audience) the access token was request for. This is the same as what was provided in the `listTokens` request.
-resourceId | The Azure resource ID for the issued token. This is either the managed application ID or the user-assigned identity ID.
-token_type | The type of the token.
+| Parameter | Description |
+| | |
+| `access_token` | The requested access token. |
+| `expires_in` | The number of seconds the access token is valid. |
+| `expires_on` | The timespan when the access token expires. This value is represented as the number of seconds from epoch. |
+| `not_before` | The timespan when the access token takes effect. This value is represented as the number of seconds from epoch. |
+| `authorizationAudience` | The `aud` (audience) the access token was request for. This value is the same as what was provided in the `listTokens` request. |
+| `resourceId` | The Azure resource ID for the issued token. This value is either the managed application ID or the user-assigned managed identity ID. |
+| `token_type` | The type of the token. |
## Next steps > [!div class="nextstepaction"]
-> [How to configure a Managed Application with a Custom Provider](../custom-providers/overview.md)
+> [How to configure a managed application with a custom provider](../custom-providers/overview.md)
azure-resource-manager Publish Service Catalog App https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/publish-service-catalog-app.md
Title: Create and publish Azure Managed Application in service catalog description: Describes how to create and publish an Azure Managed Application in your service catalog using Azure PowerShell, Azure CLI, or Azure portal.-- Last updated 03/21/2023
azure-resource-manager Publish Service Catalog Bring Your Own Storage https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/publish-service-catalog-bring-your-own-storage.md
Title: Bring your own storage to create and publish an Azure Managed Application definition description: Describes how to bring your own storage to create and publish an Azure Managed Application definition in your service catalog.-- Last updated 03/21/2023
azure-resource-manager Reference Createuidefinition Artifact https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/reference-createuidefinition-artifact.md
Title: CreateUiDefinition artifact description: Shows how to create the createUiDefinition artifact for an Azure Managed Application. The file is named createUiDefinition.json. -- Last updated 07/11/2019
azure-resource-manager Reference Main Template Artifact https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/reference-main-template-artifact.md
Title: Template artifact reference description: Provides an example of the deployment template artifact for Azure Managed Applications. -- Last updated 07/11/2019
azure-resource-manager Reference View Definition Artifact https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/reference-view-definition-artifact.md
Title: View definition artifact reference description: Provides an example of view definition artifact for Azure Managed Applications. The file name is viewDefinition.json. -- Last updated 07/11/2019
azure-resource-manager Sample Projects https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/sample-projects.md
Title: Sample projects description: Provides a summary of sample projects that are available for Azure Managed Applications.- Last updated 09/04/2019- + # Sample projects for Azure managed applications The following table links to sample Azure managed applications in GitHub.
azure-resource-manager Test Createuidefinition https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/test-createuidefinition.md
Title: Test the UI definition file description: Describes how to test the user experience for creating your Azure Managed Application through the portal.- Last updated 06/04/2021- + # Test your portal interface for Azure Managed Applications After [creating the createUiDefinition.json file](create-uidefinition-overview.md) for your managed application, you need to test the user experience. To simplify testing, use a sandbox environment that loads your file in the portal. You don't need to actually deploy your managed application. The sandbox presents your user interface in the current, full-screen portal experience. The sandbox is the recommended way to preview the interface.
Now that you've verified your portal interface is working as expected, it's time
## Next steps
-After validating your portal interface, learn about making your [Azure managed application available in the Marketplace](../../marketplace/azure-app-offer-setup.md).
+After validating your portal interface, learn about making your [Azure managed application available in the Marketplace](../../marketplace/azure-app-offer-setup.md).
azure-resource-manager Tutorial Create Managed App With Custom Provider https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/tutorial-create-managed-app-with-custom-provider.md
Title: Tutorial - custom actions & resources description: This tutorial describes how to create an Azure Managed Application with an Azure Custom Provider. -- Last updated 06/20/2019
azure-resource-manager Update Managed Resources https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-resource-manager/managed-applications/update-managed-resources.md
Title: Update managed resources description: Describes how to work on resources in the managed resource group for an Azure managed application.-- Last updated 10/26/2017- # Work with resources in the managed resource group for Azure managed application
azure-video-indexer Release Notes https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-video-indexer/release-notes.md
To stay up-to-date with the most recent Azure Video Indexer developments, this a
### Resource Health support
-Azure Video Indexer is now integrated with Azure Resource Health enabling you to see the health and availability of each of your Azure Video Indexer resource. If needed, Azure Resource Health helps with diagnosing and solving problems. You can also set alerts to be notified whenever your resources are affected. For more information, see [Azure Resource Health overview](../service-health/resource-health-overview.md).
+Azure Video Indexer is now integrated with Azure Resource Health enabling you to see the health and availability of each of your Azure Video Indexer resources. Azure Resource Health also helps with diagnosing and solving problems and you can set alerts to be notified whenever your resources are affected. For more information, see [Azure Resource Health overview](../service-health/resource-health-overview.md).
### The animation character recognition model has been retired
azure-vmware Enable Public Ip Nsx Edge https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-vmware/enable-public-ip-nsx-edge.md
Title: Enable Public IP to the NSX-T Data Center Edge for Azure VMware Solution
+ Title: Enable Public IP on the NSX-T Data Center Edge for Azure VMware Solution
description: This article shows how to enable internet access for your Azure VMware Solution. Previously updated : 10/24/2022 Last updated : 5/1/2023
-# Enable Public IP to the NSX-T Data Center Edge for Azure VMware Solution
+# Enable Public IP on the NSX-T Data Center Edge for Azure VMware Solution
-In this article, you'll learn how to enable Public IP to the NSX-T Data Center Edge for your Azure VMware Solution.
+In this article, you'll learn how to enable Public IP on the NSX-T Data Center Edge for your Azure VMware Solution.
>[!TIP] >Before you enable Internet access to your Azure VMware Solution, review the [Internet connectivity design considerations](concepts-design-public-internet-access.md).
-Public IP to the NSX-T Data Center Edge is a feature in Azure VMware Solution that enables inbound and outbound internet access for your Azure VMware Solution environment.
+Public IP on the NSX-T Data Center Edge is a feature in Azure VMware Solution that enables inbound and outbound internet access for your Azure VMware Solution environment.
>[!IMPORTANT] >The use of Public IPv4 addresses can be consumed directly in Azure VMware Solution and charged based on the Public IPv4 prefix shown on [Pricing - Virtual Machine IP Address Options.](https://azure.microsoft.com/pricing/details/ip-addresses/).
With this capability, you have the following features:
- A cohesive and simplified experience for reserving and using a Public IP down to the NSX Edge. - The ability to receive up to 1000 or more Public IPs, enabling Internet access at scale. - Inbound and outbound internet access for your workload VMs.-- DDoS Security protection against network traffic in and out of the Internet.
+- DDoS Security protection against network traffic in and out of the internet.
- HCX Migration support over the Public Internet. >[!IMPORTANT]
With this capability, you have the following features:
## Reference architecture
-The architecture shows Internet access to and from your Azure VMware Solution private cloud using a Public IP directly to the NSX-T Data Center Edge.
+The architecture shows internet access to and from your Azure VMware Solution private cloud using a Public IP directly to the NSX-T Data Center Edge.
>[!IMPORTANT] >The use of Public IP down to the NSX-T Data Center Edge is not compatible with reverse DNS Lookup.
azure-vmware Tutorial Network Checklist https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/azure-vmware/tutorial-network-checklist.md
Title: Tutorial - Network planning checklist
description: Learn about the network requirements for network connectivity and network ports on Azure VMware Solution. Previously updated : 3/10/2023 Last updated : 5/1/2023 # Networking planning checklist for Azure VMware Solution
The subnets:
| Source | Destination | Protocol | Port | Description | | | -- | :: | ::| |
-| Private Cloud DNS server | On-Premises DNS Server | UDP | 53 | DNS Client - Forward requests from Private Cloud vCenter Server for any on-premises DNS queries (check DNS section below) |
+| Private Cloud DNS server | On-premises DNS Server | UDP | 53 | DNS Client - Forward requests from Private Cloud vCenter Server for any on-premises DNS queries (check DNS section below) |
| On-premises DNS Server | Private Cloud DNS server | UDP | 53 | DNS Client - Forward requests from on-premises services to Private Cloud DNS servers (check DNS section below) | | On-premises network | Private Cloud vCenter Server | TCP (HTTP) | 80 | vCenter Server requires port 80 for direct HTTP connections. Port 80 redirects requests to HTTPS port 443. This redirection helps if you use `http://server` instead of `https://server`. | | Private Cloud management network | On-premises Active Directory | TCP | 389/636 | These ports are open to allow communications for Azure VMware Solutions vCenter Server to communicate to any on-premises Active Directory/LDAP server(s). These port(s) are optional - for configuring on-premises AD as an identity source on the Private Cloud vCenter. Port 636 is recommended for security purposes. |
The subnets:
| On-premises network | HCX Cloud Manager | TCP (HTTPS) | 9443 | HCX Cloud Manager virtual appliance management interface for HCX system configuration. | | On-premises Admin Network | HCX Cloud Manager | SSH | 22 | Administrator SSH access to HCX Cloud Manager virtual appliance. | | HCX Manager | Interconnect (HCX-IX) | TCP (HTTPS) | 8123 | HCX Bulk Migration Control |
-| HCX Manager | Interconnect (HCX-IX), Network Extension (HCX-NE) | HTTP TCP (HTTPS) | 9443 | Send management instructions to the local HCX Interconnect using the REST API. |
+| HCX Manager | Interconnect (HCX-IX), Network Extension (HCX-NE) | TCP (HTTPS) | 9443 | Send management instructions to the local HCX Interconnect using the REST API. |
| Interconnect (HCX-IX)| L2C | TCP (HTTPS) | 443 | Send management instructions from Interconnect to L2C when L2C uses the same path as the Interconnect. | | HCX Manager, Interconnect (HCX-IX) | ESXi Hosts | TCP | 80,443,902 | Management and OVF deployment. | | Interconnect (HCX-IX), Network Extension (HCX-NE) at Source| Interconnect (HCX-IX), Network Extension (HCX-NE) at Destination| UDP | 4500 | Required for IPSEC<br> Internet key exchange (IKEv2) to encapsulate workloads for the bidirectional tunnel. Network Address Translation-Traversal (NAT-T) is also supported. |
The subnets:
There can be more items to consider when it comes to firewall rules, this is intended to give common rules for common scenarios. Note that when source and destination say "on-premises," this is only important if you have a firewall that inspects flows within your datacenter. If you do not have a firewall that inspects between on-premises components, you can ignore those rules as they would not be needed.
-[Full list of HCX port requirements](https://ports.esp.vmware.com/home/VMware-HCX)
+[Full list of VMware HCX port requirements](https://ports.esp.vmware.com/home/VMware-HCX)
## DHCP and DNS resolution considerations
batch Private Connectivity https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/batch/private-connectivity.md
For details on costs related to private endpoints, see [Azure Private Link prici
When creating a private endpoint with your Batch account, keep in mind the following: -- Private endpoint resources with the sub-resource **batchAccount** must be created in the same subscription as the Batch account.
+- Private endpoint resources can be created in different subscription as the Batch account, but the subscription must be registered with [**Microsoft.Batch** resource provider](../azure-resource-manager/management/resource-providers-and-types.md#register-resource-provider).
- Resource movement isn't supported for private endpoints with Batch accounts. - If a Batch account resource is moved to a different resource group or subscription, the private endpoints can still work, but the association to the Batch account breaks. If you delete the private endpoint resource, its associated private endpoint connection still exists in your Batch account. You can manually remove connection from your Batch account. - To delete the private connection, either delete the private endpoint resource, or delete the private connection in the Batch account (this action disconnects the related private endpoint resource).
batch Virtual File Mount https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/batch/virtual-file-mount.md
Title: Mount a virtual file system on a pool
-description: Learn how to mount a virtual file system on a Batch pool.
+description: Learn how to mount different kinds of virtual file systems on Batch pool nodes, and how to troubleshoot mounting issues.
ms.devlang: csharp Previously updated : 11/11/2021 Last updated : 04/28/2023 # Mount a virtual file system on a Batch pool
-Azure Batch supports mounting cloud storage or an external file system on Windows or Linux compute nodes in your Batch pools. When a compute node joins a pool, the virtual file system is mounted and treated as a local drive on that node.
+Azure Batch supports mounting cloud storage or an external file system on Windows or Linux compute nodes in Batch pools. When a compute node joins the pool, the virtual file system mounts and acts as a local drive on that node. This article shows you how to mount a virtual file system on a pool of compute nodes by using the [Batch Management Library for .NET](/dotnet/api/overview/azure/batch).
-You can mount file systems such as:
+Mounting the file system to the pool makes accessing data easier and more efficient than requiring tasks to get their own data from a large shared data set. Consider a scenario where multiple tasks need access to a common set of data, like rendering a movie. Each task renders one or more frames at once from the scene files. By mounting a drive that contains the scene files, it's easier for each compute node to access the shared data.
+
+Also, you can choose the underlying file system to meet performance, throughout, and input/output operations per second (IOPS) requirements. You can independently scale the file system based on the number of compute nodes that concurrently access the data.
+
+For example, you could use an [Avere vFXT](/azure/avere-vfxt/avere-vfxt-overview) distributed in-memory cache to support large movie-scale renders with thousands of concurrent render nodes that access on-premises source data. Or, for data that's already in cloud-based blob storage, you can use [BlobFuse](/azure/storage/blobs/storage-how-to-mount-container-linux) to mount the data as a local file system. BlobFuse is available only on Linux nodes except Ubuntu 22.04, but [Azure Files](/azure/storage/files/storage-files-introduction) provides a similar workflow and is available on both Windows and Linux.
+
+## Supported configurations
+
+You can mount the following types of file systems:
- Azure Files - Azure Blob storage-- Network File System (NFS) including an [Avere vFXT cache](../avere-vfxt/avere-vfxt-overview.md)
+- Network File System (NFS), including an [Avere vFXT cache](/azure/avere-vfxt/avere-vfxt-overview)
- Common Internet File System (CIFS)
-In this article, you'll learn how to mount a virtual file system on a pool of compute nodes using the [Batch Management Library for .NET](/dotnet/api/overview/azure/batch).
+Batch supports the following virtual file system types for node agents that are produced for their respective publisher and offer.
+
+| OS Type | Azure Files share | Azure Blob container | NFS mount | CIFS mount |
+||||||
+| Linux | :heavy_check_mark: | :heavy_check_mark:* | :heavy_check_mark: | :heavy_check_mark: |
+| Windows | :heavy_check_mark: | :x: | :x: | :x: |
+
+\*Azure Blob container isn't supported on Ubuntu 22.04.
> [!NOTE]
-> Mounting a virtual file system is only supported on Batch pools created on or after August 8, 2019. Batch pools created before that date will not support this feature.
+> Mounting a virtual file system isn't supported on Batch pools created before August 8, 2019.
-## Benefits of mounting on a pool
+## Networking requirements
+
+When you use virtual file mounts with Batch pools in a virtual network, keep the following requirements in mind, and ensure that no required traffic is blocked. For more information, see [Batch pools in a virtual network](batch-virtual-network.md).
-Mounting the file system to the pool, instead of letting tasks retrieve their own data from a large data set, makes it easier and more efficient for tasks to access the necessary data.
+- **Azure Files shares** require TCP port 445 to be open for traffic to and from the `storage` service tag. For more information, see [Use an Azure file share with Windows](/azure/storage/files/storage-how-to-use-files-windows#prerequisites).
-Consider a scenario with multiple tasks requiring access to a common set of data, like rendering a movie. Each task renders one or more frames at a time from the scene files. By mounting a drive that contains the scene files, it's easier for compute nodes to access shared data.
+- **Azure Blob containers** require TCP port 443 to be open for traffic to and from the `storage` service tag. Virtual machines (VMs) must have access to `https://packages.microsoft.com` to download the `blobfuse` and `gpg` packages. Depending on your configuration, you might need access to other URLs.
-Additionally, the underlying file system can be chosen and scaled independently based on the performance and scale (throughput and IOPS) required by the number of compute nodes concurrently accessing the data. For example, you can use an [Avere vFXT](../avere-vfxt/avere-vfxt-overview.md) distributed in-memory cache to support large motion picture-scale renders with thousands of concurrent render nodes, accessing source data that is on-premises. Instead, for data that already is in cloud-based Blob storage, [blobfuse](../storage/blobs/storage-how-to-mount-container-linux.md) can be used to mount this data as a local file system. Blobfuse is only available on Linux nodes (excluding Ubuntu 22.04), though [Azure Files](../storage/files/storage-files-introduction.md) provides a similar workflow and is available on both Windows and Linux.
+- **Network File System (NFS)** requires access to port 2049 by default. Your configuration might have other requirements. VMs must have access to the appropriate package manager to download the `nfs-common` (for Debian or Ubuntu) or `nfs-utils` (for CentOS) packages. The URL might vary based on your OS version. Depending on your configuration, you might also need access to other URLs.
+
+ Mounting Azure Blob or Azure Files through NFS might have more networking requirements. For example, your compute nodes might need to use the same virtual network subnet as the storage account.
-## Mount a virtual file system on a pool
+- **Common Internet File System (CIFS)** requires access to TCP port 445. VMs must have access to the appropriate package manager to download the `cifs-utils` package. The URL might vary based on your OS version.
+
+## Mounting configuration and implementation
Mounting a virtual file system on a pool makes the file system available to every compute node in the pool. Configuration for the file system happens when a compute node joins a pool, restarts, or is reimaged.
-To mount a file system on a pool, create a `MountConfiguration` object. Choose the object that fits your virtual file system: `AzureBlobFileSystemConfiguration`, `AzureFileShareConfiguration`, `NfsMountConfiguration`, or `CifsMountConfiguration`.
+To mount a file system on a pool, you create a [MountConfiguration](/dotnet/api/microsoft.azure.batch.mountconfiguration) object that matches your virtual file system: `AzureBlobFileSystemConfiguration`, `AzureFileShareConfiguration`, `NfsMountConfiguration`, or `CifsMountConfiguration`.
+
+All mount configuration objects need the following base parameters. Some mount configurations have specific parameters for the particular file system, which the [code examples](#example-mount-configurations) present in more detail.
+
+- **Account name or source** of the storage account.
+
+- **Relative mount path or source**, the location of the file system to mount on the compute node, relative to the standard *\\fsmounts* directory accessible via `AZ_BATCH_NODE_MOUNTS_DIR`.
+
+ The exact *\\fsmounts* directory location varies depending on node OS. For example, the location on an Ubuntu node maps to *mnt\batch\tasks\fsmounts*. On a CentOS node, the location maps to *mnt\resources\batch\tasks\fsmounts*.
+
+- **Mount options or BlobFuse options** that describe specific parameters for mounting a file system.
-All mount configuration objects need the following base parameters. Some mount configurations have parameters specific to the file system being used, which are discussed in more detail in the code examples.
+When you create the pool and the `MountConfiguration` object, you assign the object to the `MountConfigurationList` property. Mounting for the file system happens when a node joins the pool, restarts, or is reimaged.
-- **Account name or source**: To mount a virtual file share, you need the name of the storage account or its source.-- **Relative mount path or Source**: The location of the file system mounted on the compute node, relative to the standard `fsmounts` directory accessible on the node via `AZ_BATCH_NODE_MOUNTS_DIR`. The exact location varies depending on the operating system used on the node. For example, the physical location on an Ubuntu node is mapped to `mnt\batch\tasks\fsmounts`. On a CentOS node, the location is mapped to `mnt\resources\batch\tasks\fsmounts`.-- **Mount options or blobfuse options**: These options describe specific parameters for mounting a file system.
+The Batch agent implements mounting differently on Windows and Linux.
-Once the `MountConfiguration` object is created, assign the object to the `MountConfigurationList` property when you create the pool. Mounting for the file system happens when a node joins a pool, restarts, or is reimaged.
+- On Linux, Batch installs the package `cifs-utils`. Then, Batch issues the mount command.
-When the file system is mounted, an environment variable `AZ_BATCH_NODE_MOUNTS_DIR` is created which points to the location of the mounted file systems and log files, which are useful for troubleshooting and debugging. Log files are explained in more detail in the [Diagnose mount errors](#diagnose-mount-errors) section.
+- On Windows, Batch uses `cmdkey` to add your Batch account credentials. Then, Batch issues the mount command through `net use`. For example:
+
+ ```powershell
+ net use S: \\<storage-account-name>.file.core.windows.net\<fileshare> /u:AZURE\<storage-account-name> <storage-account-key>
+ ```
+
+Mounting the file system creates an environment variable `AZ_BATCH_NODE_MOUNTS_DIR`, which points to the location of the mounted file system and log files. You can use the log files for troubleshooting and debugging.
+
+## Mount an Azure Files share with PowerShell
+
+You can use [Azure PowerShell](/powershell/) to mount an Azure Files share on a Windows or Linux Batch pool. The following procedure walks you through configuring and mounting an Azure file share file system on a Batch pool.
> [!IMPORTANT]
-> The maximum number of mounted file systems on a pool is 10. See [Batch service quotas and limits](batch-quota-limit.md#other-limits) for details and other limits.
+> The maximum number of mounted file systems on a pool is 10. For details and other limits, see [Batch service quotas and limits](batch-quota-limit.md#other-limits).
-## Mount Azure file share with PowerShell
+### Prerequisites
-You can mount an Azure file share on a Batch pool using [Azure PowerShell](/powershell/) or [Azure Cloud Shell](../cloud-shell/overview.md).
+- An Azure account with an active subscription.
+- [Azure PowerShell](/powershell/azure/install-azure-powershell) installed, or use [Azure Cloud Shell](https://shell.azure.com) and select **PowerShell** for the interface.
+- An existing Batch account with a linked Azure Storage account that has a file share.
# [Windows](#tab/windows)
-1. Sign in to your Azure subscription.
+1. Sign in to your Azure subscription, replacing the placeholder with your subscription ID.
```powershell-interactive Connect-AzAccount -Subscription "<subscription-ID>" ```
-1. Get the context for your Batch account.
+1. Get the context for your Batch account. Replace the `<batch-account-name>` placeholder with your Batch account name.
```powershell-interactive $context = Get-AzBatchAccount -AccountName <batch-account-name> ```
-1. Create a Batch pool with the following settings. Replace the sample values with your own information as needed.
+1. Create a Batch pool with the following settings. Replace the `<storage-account-name>` , `<storage-account-key>`, and `<file-share-name>` placeholders with the values from the storage account that's linked to your Batch account. Replace the `<pool-name>` placeholder with the name you want for the pool.
+
+ The following script creates a pool with one Windows Server 2016 Datacenter, Standard_D2_V2 size node, and then mounts the Azure file share to the *S* drive of the node.
```powershell-interactive
- $fileShareConfig = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSAzureFileShareConfiguration" -ArgumentList @("<Storage-Account-name>", "https://<Storage-Account-name>.file.core.windows.net/batchfileshare1", "S", "Storage-Account-key")
+ $fileShareConfig = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSAzureFileShareConfiguration" -ArgumentList @("<storage-account-name>", "https://<storage-account-name>.file.core.windows.net/batchfileshare1", "S", "<storage-account-key>")
$mountConfig = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSMountConfiguration" -ArgumentList @($fileShareConfig)
You can mount an Azure file share on a Batch pool using [Azure PowerShell](/powe
$configuration = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSVirtualMachineConfiguration" -ArgumentList @($imageReference, "batch.node.windows amd64")
- New-AzBatchPool -Id "<Pool-Name>" -VirtualMachineSize "STANDARD_D2_V2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -MountConfiguration @($mountConfig) -BatchContext $context
+ New-AzBatchPool -Id "<pool-name>" -VirtualMachineSize "STANDARD_D2_V2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -MountConfiguration @($mountConfig) -BatchContext $context
```
-1. Access the mount files using your drive's direct path. For example:
+1. Connect to the node and check that the output file is correct.
- ```powershell-interactive
- cmd /c "more S:\folder1\out.txt & timeout /t 90 > NULL"
- ```
+### Access the mounted files
+
+Azure Batch tasks can access the mounted files by using the drive's direct path, for example:
-1. Check that the output file is correct.
+```powershell-interactive
+cmd /c "more S:\folder1\out.txt & timeout /t 90 > NULL"
+```
-1. If you're using Remote Desktop Protocol (RDP) or SSH, add credentials to access the `S` drive directly. The Azure Batch agent only grants access for Azure Batch tasks in Windows. When you connect to the node over RDP, your user account doesn't have automatic access to the mounting drive.
+The Azure Batch agent grants access only for Azure Batch tasks. If you use Remote Desktop Protocol (RDP) to connect to the node, your user account doesn't have automatic access to the mounting drive. When you connect to the node over RDP, you must add credentials for the storage account to access the *S* drive directly.
- Use `cmdkey` to add your credentials. Replace the sample values with your own information.
+Use `cmdkey` to add the credentials. Replace the `<storage-account-name>` and `<storage-account-key`> placeholders with your own information.
- ```powershell-interactive
- cmdkey /add:"<storage-account-name>.file.core.windows.net" /user:"Azure\<storage-account-name>" /pass:"<storage-account-key>"
- ```
+```powershell-interactive
+cmdkey /add:"<storage-account-name>.file.core.windows.net" /user:"Azure\<storage-account-name>" /pass:"<storage-account-key>"
+```
# [Linux](#tab/linux)
-1. Sign in to your Azure subscription.
+1. Sign in to your Azure subscription, replacing the placeholder with your subscription ID.
```powershell-interactive Connect-AzAccount -Subscription "<subscription-ID>" ```
-1. Get the context for your Batch account.
+1. Get the context for your Batch account, replacing the placeholder with your Batch account name.
```powershell-interactive $context = Get-AzBatchAccount -AccountName <batch-account-name> ```
-1. Create a Batch pool with the following settings. Replace the sample values with your own information as needed.
+1. Create a Batch pool with the following settings. Replace the `<storage-account-name>` , `<storage-account-key>`, and `<file-share-name>` placeholders with the values from the storage account that's linked to your Batch account. Replace the `<pool-name>` placeholder with the name you want for the pool.
+
+ The following script creates a pool with one Ubuntu 20.04, Standard_DS1_v2 size node, and then mounts the Azure file share to the *S* drive of the node.
```powershell-interactive
- $fileShareConfig = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSAzureFileShareConfiguration" -ArgumentList @("<Storage-Account-name>", https://<Storage-Account-name>.file.core.windows.net/batchfileshare1, "S", "<Storage-Account-key>", "-o vers=3.0,dir_mode=0777,file_mode=0777,sec=ntlmssp")
+ $fileShareConfig = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSAzureFileShareConfiguration" -ArgumentList @("<storage-account-name>", https://<storage-account-name>.file.core.windows.net/<file-share-name>, "S", "<storage-account-key>", "-o vers=3.0,dir_mode=0777,file_mode=0777,sec=ntlmssp")
$mountConfig = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSMountConfiguration" -ArgumentList @($fileShareConfig)
- $imageReference = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSImageReference" -ArgumentList @("ubuntuserver", "canonical", "20.04-lts", "latest")
+ $imageReference = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSImageReference" -ArgumentList @("0001-com-ubuntu-server-focal", "canonical", "20_04-lts", "latest")
$configuration = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSVirtualMachineConfiguration" -ArgumentList @($imageReference, "batch.node.ubuntu 20.04")
- New-AzBatchPool -Id "<Pool-Name>" -VirtualMachineSize "STANDARD_D2_V2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -MountConfiguration @($mountConfig) -BatchContext $Context
-
+ New-AzBatchPool -Id "<pool-name>" -VirtualMachineSize "Standard_DS1_v2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -MountConfiguration @($mountConfig) -BatchContext $Context
```
-1. Access the mount files using the environment variable `AZ_BATCH_NODE_MOUNTS_DIR`. For example:
+1. Connect to the node and check that the output file is correct.
- ```bash
- /bin/bash -c 'more $AZ_BATCH_NODE_MOUNTS_DIR/S/folder1/out.txt; sleep 20s'
- ```
+### Access the mounted files
- Optionally, you can also access the mount files using the direct path.
+You can access the mounted files by using the environment variable `AZ_BATCH_NODE_MOUNTS_DIR`. For example:
-1. Check that the output file is correct.
+```bash
+/bin/bash -c 'more $AZ_BATCH_NODE_MOUNTS_DIR/S/folder1/out.txt; sleep 20s'
+```
-1. If you're using RDP or SSH, you can manually access the `S` drive directly. Use the path `/mnt/batch/tasks/fsmounts/S`.
+Optionally, you can also access the mount files by using the direct path. If you use SSH to connect to the node, you can manually access the *S* drive directly. Use the path */mnt/batch/tasks/fsmounts/S*.
-### Troubleshoot PowerShell mounting
+## Troubleshoot mount issues
+
+If a mount configuration fails, the compute node fails and the node state is set to **Unusable**. To diagnose a mount configuration failure, inspect the [ComputeNodeError](/rest/api/batchservice/computenode/get#computenodeerror) property for details on the error.
+
+To get log files for debugging, you can use the [OutputFiles](batch-task-output-files.md#specify-output-files-for-task-output) API to upload the *\*.log* files. The *\*.log* files contain information about the file system mount at the `AZ_BATCH_NODE_MOUNTS_DIR` location. Mount log files have the format: *\<type>-\<mountDirOrDrive>.log* for each mount. For example, a CIFS mount at a mount directory named *test* has a mount log file named: *cifs-test.log*.
+
+### Investigate mounting errors
-When you mount an Azure file share to a Batch pool with PowerShell or Cloud Shell, you might receive the following error:
+If you get the following error when you try to mount an Azure file share to a Batch node, you can RDP or SSH to the node to check the related log files.
```output Mount Configuration Error | An error was encountered while configuring specified mount(s)
net use S: \\<storage-account-name>.file.core.windows.net\<fileshare> /u:AZURE\<
1. Connect to the node over RDP.
-1. Open the log file, `fshare-S.log`. The file path is `D:\batch\tasks\fsmounts`.
+1. Open the log file *fshare-S.log*, at *D:\batch\tasks\fsmounts*.
-1. Review the error messages. For example:
+1. Review the error messages, for example:
```output CMDKEY: Credential added successfully.
-
System error 86 has occurred. The specified network password is not correct. ```
-1. Troubleshoot the problem using the [Azure file shares troubleshooter](https://support.microsoft.com/help/4022301/troubleshooter-for-azure-files-shares).
+1. Troubleshoot the problem by using the [Azure file shares troubleshooter](https://support.microsoft.com/help/4022301/troubleshooter-for-azure-files-shares).
# [Linux](#tab/linux) 1. Connect to the node over SSH.
-1. Open the log file, `fshare-S.log`. The file path is `/mnt/batch/tasks/fsmounts`.
+1. Open the log file *fshare-S.log* at */mnt/batch/tasks/fsmounts*.
-1. Review the error messages. For example, `mount error(13): Permission denied`.
+1. Review the error messages, for example `mount error(13): Permission denied`.
-1. Troubleshoot the problem using [Troubleshoot Azure Files connectivity and access issues (SMB)](../storage/files/files-troubleshoot-smb-connectivity.md).
+1. Troubleshoot the problem by using [Troubleshoot Azure Files connectivity and access issues (SMB)](/azure/storage/files/files-troubleshoot-smb-connectivity).
-If you can't use RDP or SSH to check the log files on the node, check the Batch logs directly. Use this method for both Windows and Linux logs.
+If you can't use RDP or SSH to check the log files on the node, you can upload the logs to your Azure storage account. You can use this method for both Windows and Linux logs.
-1. Sign in to the [Azure portal](https://portal.azure.com).
+1. In the [Azure portal](https://portal.azure.com), search for and select the Batch account that has your pool.
-1. In the search bar, enter and select **Batch accounts**.
+1. On the Batch account page, select **Pools** from the left navigation.
-1. On the **Batch accounts** page, select the account with your Batch pool.
+1. On the **Pools** page, select the pool's name.
-1. On the Batch account page's menu, under **Features**, select **Pools**.
+1. On the pool's page, select **Nodes** from the left navigation.
-1. Select the pool's name.
+1. On the **Nodes** page, select the node's name.
-1. On the Batch pool page's menu, under **General**, select **Nodes**.
+1. On the node's page, select **Upload batch logs**.
-1. Select the node's name.
+1. On the **Upload batch logs** pane, select **Pick storage container**.
-1. On the **Overview** page for the node, select **Upload batch logs**.
+1. On the **Storage accounts** page, select a storage account.
-1. In the **Upload batch logs** pane, select your Azure Storage container. Then, select **Pick storage container**.
+1. On the **Containers** page, select or create a container to upload the files to, and select **Select**.
-1. Select and download the log files from the storage container.
+1. Select **Start upload**.
-1. Open `agent-debug.log`.
+1. When the upload completes, download the files and open *agent-debug.log*.
-1. Review the error messages. For example:
+1. Review the error messages, for example:
```output ..20210322T113107.448Z.00000000-0000-0000-0000-000000000000.ERROR.agent.mount.filesystems.basefilesystem.basefilesystem.py.run_cmd_persist_output_async.59.2912.MainThread.3580.Mount command failed with exit code: 2, output:
If you can't use RDP or SSH to check the log files on the node, check the Batch
The specified network password is not correct. ```
-1. Troubleshoot the problem using the [Azure file shares troubleshooter](https://support.microsoft.com/help/4022301/troubleshooter-for-azure-files-shares).
-
-If you're still unable to find the cause of the failure, you can [mount the file share manually with PowerShell](#manually-mount-file-share-with-powershell) instead.
+1. Troubleshoot the problem by using the [Azure file shares troubleshooter](https://support.microsoft.com/help/4022301/troubleshooter-for-azure-files-shares).
-### Manually mount file share with PowerShell
+### Manually mount a file share with PowerShell
-If you're unable to diagnose or fix mounting errors with PowerShell, you can mount the file share manually.
+If you can't diagnose or fix mounting errors, you can use PowerShell to mount the file share manually instead.
# [Windows](#tab/windows)
If you're unable to diagnose or fix mounting errors with PowerShell, you can mou
$configuration = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSVirtualMachineConfiguration" -ArgumentList @($imageReference, "batch.node.windows amd64")
- New-AzBatchPool -Id "<Pool-Name>" -VirtualMachineSize "STANDARD_D2_V2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -BatchContext $Context
+ New-AzBatchPool -Id "<pool-name>" -VirtualMachineSize "STANDARD_D2_V2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -BatchContext $Context
``` 1. Wait for the node to be in the **Idle** state.
-1. Sign in to the [Azure portal](https://portal.azure.com).
-
-1. In the search bar, enter and select **Storage accounts**.
-
-1. Select the name of the storage account with your file share.
+1. In the [Azure portal](https://portal.azure.com), search for and select the storage account that has your file share.
-1. On the storage account page's menu, under **Data storage**, select **File shares**.
+1. On the storage account page's menu, select **File shares** from the left navigation.
-1. On the **File shares** page, select the file share's name.
+1. On the **File shares** page, select the file share you want to mount.
-1. On the file share's **Overview** page, select **Connect**.
+1. On the file share's page, select **Connect**.
1. In the **Connect** pane, select the **Windows** tab.
-1. For **Drive letter**, enter the drive you want to use. The default is `Z`.
+1. For **Drive letter**, enter the drive you want to use. The default is *Z*.
1. For **Authentication method**, select how you want to connect to the file share.
-1. Copy the PowerShell command for mounting the file share.
+1. Select **Show Script**, and copy the PowerShell script for mounting the file share.
1. Connect to the node over RDP.
If you're unable to diagnose or fix mounting errors with PowerShell, you can mou
# [Linux](#tab/linux) - 1. Create a pool without a mounting configuration. For example: ```powershell-interactive
- $imageReference = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSImageReference" -ArgumentList @("ubuntuserver", "canonical", "20.04-lts", "latest")
+ $imageReference = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSImageReference" -ArgumentList @("0001-com-ubuntu-server-focal", "canonical", "20_04-lts", "latest")
$configuration = New-Object -TypeName "Microsoft.Azure.Commands.Batch.Models.PSVirtualMachineConfiguration" -ArgumentList @($imageReference, "batch.node.ubuntu 20.04")
- New-AzBatchPool -Id "<Pool-Name>" -VirtualMachineSize "STANDARD_D2_V2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -BatchContext $Context
+ New-AzBatchPool -Id "<pool-name>" -VirtualMachineSize "Standard_DS1_v2" -VirtualMachineConfiguration $configuration -TargetDedicatedComputeNodes 1 -BatchContext $Context
``` 1. Wait for the node to be in the **Idle** state.
-1. Sign in to the [Azure portal](https://portal.azure.com).
-
-1. In the search bar, enter and select **Storage accounts**.
+1. In the [Azure portal](https://portal.azure.com), search for and select the storage account that has your file share.
-1. Select the name of the storage account with your file share.
+1. On the storage account page's menu, select **File shares** from the left navigation.
-1. On the storage account page's menu, under **Data storage**, select **File shares**.
+1. On the **File shares** page, select the file share you want to mount.
-1. On the **File shares** page, select the file share's name.
-
-1. On the file share's **Overview** page, select **Connect**.
+1. On the file share's page, select **Connect**.
1. In the **Connect** pane, select the **Linux** tab. 1. Enter the **Mount point** you want to use.
-1. Copy the Linux command for mounting the file share.
+1. Copy the Linux script for mounting the file share.
1. Connect to the node over SSH.
If you're unable to diagnose or fix mounting errors with PowerShell, you can mou
1. Note any error messages in the output. Use this information to troubleshoot any networking-related issues. -
-## Examples
+## Example mount configurations
-The following code examples demonstrate mounting various file shares to a pool of compute nodes.
+The following code example configurations demonstrate mounting various file share systems to a pool of compute nodes.
### Azure Files share
-Azure Files is the standard Azure cloud file system offering. For information about the parameters in the code sample, see [Use an Azure Files share - SMB](../storage/files/storage-how-to-use-files-windows.md) or [Use an Azure Files share with - NFS](../storage/files/storage-files-how-to-create-nfs-shares.md).
+Azure Files is the standard Azure cloud file system offering. The following configuration mounts an Azure Files share named `<file-share-name>` to the *S* drive. For information about the parameters in the example, see [Mount SMB Azure file share on Windows](/azure/storage/files/storage-how-to-use-files-windows) or [Create an NFS Azure file share and mount it on a Linux VM using the Azure portal](/azure/storage/files/storage-files-how-to-create-nfs-shares).
```csharp new PoolAddParameter
new PoolAddParameter
{ AzureFileShareConfiguration = new AzureFileShareConfiguration {
- AccountName = "{storage-account-name}",
- AzureFileUrl = "https://{storage-account-name}.file.core.windows.net/{file-share-name}",
- AccountKey = "{storage-account-key}",
+ AccountName = "<storage-account-name>",
+ AzureFileUrl = "https://<storage-account-name>.file.core.windows.net/<file-share-name>",
+ AccountKey = "<storage-account-key>",
RelativeMountPath = "S", MountOptions = "-o vers=3.0,dir_mode=0777,file_mode=0777,sec=ntlmssp" },
new PoolAddParameter
### Azure Blob container
-Another option is to use Azure Blob storage via [blobfuse](../storage/blobs/storage-how-to-mount-container-linux.md). Mounting a blob file system requires an `AccountKey`, `SasKey`, or `Managed Identity` with access to your storage account.
+Another option is to use Azure Blob storage via [BlobFuse](/azure/storage/blobs/storage-how-to-mount-container-linux). Mounting a blob file system requires either an account key, shared access signature (SAS) key, or managed identity with access to your storage account.
-For information on getting these keys, see:
+For information on getting these keys or identity, see the following articles:
-- [Manage storage account access keys](../storage/common/storage-account-keys-manage.md)-- [Grant limited access to Azure Storage resources using shared access signatures (SAS)](../storage/common/storage-sas-overview.md)-- [Configure managed identities in Batch pools](managed-identity-pools.md).
+- [Manage storage account access keys](/azure/storage/common/storage-account-keys-manage)
+- [Grant limited access to Azure Storage resources using shared access signatures (SAS)](/azure/storage/common/storage-sas-overview)
+- [Configure managed identities in Batch pools](managed-identity-pools.md)
-For more information and tips on using blobfuse, see the [blobfuse project](https://github.com/Azure/azure-storage-fuse).
+ > [!TIP]
+ >If you use a managed identity, ensure that the identity has been [assigned to the pool](managed-identity-pools.md) so that it's available on the VM doing the mounting. The identity must also have the **Storage Blob Data Contributor** role.
-To get default access to the blobfuse mounted directory, run the task as an **Administrator**. Blobfuse mounts the directory at the user space, and at pool creation it's mounted as root. In Linux, all **Administrator** tasks are root. All options for the FUSE module are described in the [FUSE reference page](https://manpages.ubuntu.com/manpages/xenial/man8/mount.fuse.8.html).
-
-Review the [Troubleshoot FAQ](https://github.com/Azure/azure-storage-fuse/wiki/3.-Troubleshoot-FAQ) for more information and tips on using blobfuse. You can also review [GitHub issues in the blobfuse repository](https://github.com/Azure/azure-storage-fuse/issues) to check on current blobfuse issues and resolutions.
-
-> [!NOTE]
-> The example below shows `AccountKey`, `SasKey` and `IdentityReference`, but they are mutually exclusive; only one can be specified.
+The following configuration mounts a blob file system with BlobFuse options. For illustration purposes, the example shows `AccountKey`, `SasKey` and `IdentityReference`, but you can actually specify only one of these methods.
```csharp new PoolAddParameter
new PoolAddParameter
{ AzureBlobFileSystemConfiguration = new AzureBlobFileSystemConfiguration {
- AccountName = "StorageAccountName",
- ContainerName = "containerName",
- AccountKey = "StorageAccountKey",
- SasKey = "SasKey",
- IdentityReference = new ComputeNodeIdentityReference("/subscriptions/SUB/resourceGroups/RG/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity-name"),
- RelativeMountPath = "RelativeMountPath",
+ AccountName = "<storage-account-name>",
+ ContainerName = "<container-name>",
+ // Use only one of the following three lines:
+ AccountKey = "<storage-account-key>",
+ SasKey = "<sas-key>",
+ IdentityReference = new ComputeNodeIdentityReference("/subscriptions/<subscription>/resourceGroups/<resource-group>/providers/Microsoft.ManagedIdentity/userAssignedIdentities/<identity-name>"),
+ RelativeMountPath = "<relative-mount-path>",
BlobfuseOptions = "-o attr_timeout=240 -o entry_timeout=240 -o negative_timeout=120 " }, }
new PoolAddParameter
} ```
-> [!TIP]
->If using a managed identity, ensure that the identity has been [assigned to the pool](managed-identity-pools.md) so that it's available on the VM doing the mounting. The identity will need to have the `Storage Blob Data Contributor` role in order to function properly.
+To get default access to the BlobFuse mounted directory, run the task as an administrator. BlobFuse mounts the directory at the user space, and at pool creation mounts the directory as root. In Linux, all administrator tasks are root. The [FUSE reference page](https://manpages.ubuntu.com/manpages/xenial/man8/mount.fuse.8.html) describes all options for the FUSE module.
+
+For more information and tips on using BlobFuse, see the following references:
-### Network File System
+- [Blobfuse2 project](https://github.com/Azure/azure-storage-fuse)
+- [Blobfuse Troubleshoot FAQ](https://github.com/Azure/azure-storage-fuse/wiki/Blobfuse-Troubleshoot-FAQ)
+- [GitHub issues in the azure-storage-fuse repository](https://github.com/Azure/azure-storage-fuse/issues)
-Network File Systems (NFS) can be mounted to pool nodes, allowing traditional file systems to be accessed by Azure Batch. This setup can be a single NFS server deployed in the cloud, or an on-premises NFS server accessed over a virtual network. NFS mounts support [Avere vFXT](../avere-vfxt/avere-vfxt-overview.md). Avere vFXT is a distributed in-memory cache solution for data-intensive high-performance computing (HPC) tasks, and other standard NFS-compliant interfaces. For example, [NFS for Azure Blob](../storage/blobs/network-file-system-protocol-support.md) and [NFS for Azure Files](../storage/files/storage-files-how-to-mount-nfs-shares.md).
+### NFS
+
+You can mount NFS shares to pool nodes to allow Batch to access traditional file systems. The setup can be a single NFS server deployed in the cloud or an on-premises NFS server accessed over a virtual network. NFS mounts support [Avere vFXT](/azure/avere-vfxt/avere-vfxt-overview), a distributed in-memory cache for data-intensive high-performance computing (HPC) tasks. NFS mounts also support other standard NFS-compliant interfaces, such as [NFS for Azure Blob](/azure/storage/blobs/network-file-system-protocol-support) and [NFS for Azure Files](/azure/storage/files/storage-files-how-to-mount-nfs-shares).
+
+The following example shows a configuration for an NFS file system mount:
```csharp new PoolAddParameter
new PoolAddParameter
{ NfsMountConfiguration = new NFSMountConfiguration {
- Source = "source",
- RelativeMountPath = "RelativeMountPath",
+ Source = "<source>",
+ RelativeMountPath = "<relative-mount-path>",
MountOptions = "options ver=3.0" }, }
new PoolAddParameter
} ```
-### Common Internet File System
+### CIFS
-Mounting [Common Internet File Systems (CIFS)](/windows/desktop/fileio/microsoft-smb-protocol-and-cifs-protocol-overview) to pool nodes is another way to provide access to traditional file systems. CIFS is a file-sharing protocol that provides an open and cross-platform mechanism for requesting network server files and services. CIFS is based on the enhanced version of the [SMB protocol](/windows-server/storage/file-server/file-server-smb-overview), which is for internet and intranet file sharing.
+Mounting [CIFS](/windows/desktop/fileio/microsoft-smb-protocol-and-cifs-protocol-overview) to pool nodes is another way to provide access to traditional file systems. CIFS is a file-sharing protocol that provides an open and cross-platform mechanism for requesting network server files and services. CIFS is based on the enhanced version of the [SMB protocol](/windows-server/storage/file-server/file-server-smb-overview) for internet and intranet file sharing.
+
+The following example shows a configuration for a CIFS file mount.
```csharp new PoolAddParameter
new PoolAddParameter
{ CifsMountConfiguration = new CIFSMountConfiguration {
- Username = "StorageAccountName",
- RelativeMountPath = "cifsmountpoint",
- Source = "source",
- Password = "StorageAccountKey",
- MountOptions = "-o vers=3.0,dir_mode=0777,file_mode=0777,serverino,domain=MyDomain"
+ Username = "<storage-account-name>",
+ RelativeMountPath = "<relative-mount-path>",
+ Source = "<source>",
+ Password = "<storage-account-key>",
+ MountOptions = "-o vers=3.0,dir_mode=0777,file_mode=0777,serverino,domain=<domain-name>"
}, } } } ```
-## Diagnose mount errors
-
-If a mount configuration fails, the compute node in the pool will fail and the node state will be set to `unusable`. To diagnose a mount configuration failure, inspect the [`ComputeNodeError`](/rest/api/batchservice/computenode/get#computenodeerror) property for details on the error.
-
-To get the log files for debugging, use [OutputFiles](batch-task-output-files.md) to upload the `*.log` files. The `*.log` files contain information about the file system mount at the `AZ_BATCH_NODE_MOUNTS_DIR` location. Mount log files have the format: `<type>-<mountDirOrDrive>.log` for each mount. For example, a `cifs` mount at a mount directory named `test` will have a mount log file named: `cifs-test.log`.
-
-## Support matrix
-
-Azure Batch supports the following virtual file system types for node agents produced for their respective publisher and offer.
-
-| OS Type | Azure Files Share | Azure Blob container | NFS mount | CIFS mount |
-||||||
-| Linux | :heavy_check_mark: | :heavy_check_mark:* | :heavy_check_mark: | :heavy_check_mark: |
-| Windows | :heavy_check_mark: | :x: | :x: | :x: |
-
-_*Azure Blob container is **not** supported on Ubuntu 22.04_
-
-## Networking requirements
-
-When using virtual file mounts with [Azure Batch pools in a virtual network](batch-virtual-network.md), keep in mind the following requirements and ensure no required traffic is blocked.
--- **Azure File shares**:
- - Requires TCP port 445 to be open for traffic to/from the "storage" service tag. For more information, see [Use an Azure file share with Windows](../storage/files/storage-how-to-use-files-windows.md#prerequisites).
-- **Azure Blob containers**:
- - Requires TCP port 443 to be open for traffic to/from the "storage" service tag.
- - VMs must have access to https://packages.microsoft.com to download the blobfuse and gpg packages. Depending on your configuration, you might also need access to other URLs to download more packages.
-- **Network File System (NFS)**:
- - Requires access to port 2049 (by default; your configuration might have other requirements).
- - VMs must have access to the appropriate package manager to download the `nfs-common` (for Debian or Ubuntu) or `nfs-utils` (for CentOS) package. This URL might vary based on your OS version. Depending on your configuration, you might also need access to other URLs to download other packages.
- - Mounting Azure Blob or Azure Files through NFS might have more networking requirements. For example, you might need compute nodes that share the same subnet of a virtual network as the storage account.
-- **Common Internet File System (CIFS)**:
- - Requires access to TCP port 445.
- - VMs must have access to the appropriate package manager(s) to download the `cifs-utils` package. This URL might vary based on your OS version.
- ## Next steps -- Learn more about mounting an Azure Files share with [Windows](../storage/files/storage-how-to-use-files-windows.md) or [Linux](../storage/files/storage-how-to-use-files-linux.md).-- Learn about using and mounting [blobfuse](https://github.com/Azure/azure-storage-fuse) virtual file systems.-- See [Network File System overview](/windows-server/storage/nfs/nfs-overview) to learn about NFS and its applications.-- See [Microsoft SMB protocol and CIFS protocol overview](/windows/desktop/fileio/microsoft-smb-protocol-and-cifs-protocol-overview) to learn more about CIFS.
+- [Mount an Azure Files share with Windows](/azure/storage/files/storage-how-to-use-files-windows)
+- [Mount an Azure Files share with Linux](/azure/storage/files/storage-how-to-use-files-linux)
+- [Blobfuse2 - A Microsoft supported Azure Storage FUSE driver](https://github.com/Azure/azure-storage-fuse)
+- [Network File System overview](/windows-server/storage/nfs/nfs-overview)
+- [Microsoft SMB protocol and CIFS protocol overview](/windows/desktop/fileio/microsoft-smb-protocol-and-cifs-protocol-overview)
cognitive-services Speech Container Howto On Premises https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/cognitive-services/Speech-Service/speech-container-howto-on-premises.md
textToSpeech:
optimizeForTurboMode: true image: registry: mcr.microsoft.com
- repository: azure-cognitive-services/speechservices/speech-to-text
+ repository: azure-cognitive-services/speechservices/text-to-speech
tag: latest pullSecrets: - mcr # Or an existing secret
cognitive-services Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/cognitive-services/openai/overview.md
Previously updated : 03/21/2023 Last updated : 05/01/2023 recommendations: false keywords:
keywords:
# What is Azure OpenAI Service?
-Azure OpenAI Service provides REST API access to OpenAI's powerful language models including the GPT-3, Codex and Embeddings model series. These models can be easily adapted to your specific task including but not limited to content generation, summarization, semantic search, and natural language to code translation. Users can access the service through REST APIs, Python SDK, or our web-based interface in the Azure OpenAI Studio.
+Azure OpenAI Service provides REST API access to OpenAI's powerful language models including the GPT-3, Codex and Embeddings model series. In addition, the new GPT-4 and ChatGPT (gpt-35-turbo) model series are now available in preview. These models can be easily adapted to your specific task including but not limited to content generation, summarization, semantic search, and natural language to code translation. Users can access the service through REST APIs, Python SDK, or our web-based interface in the Azure OpenAI Studio.
### Features overview
container-registry Container Registry Image Lock https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/container-registry/container-registry-image-lock.md
az acr repository show \
``` ### Show the current image attributes+ To see the current attributes of a tag, run the following [az acr repository show][az-acr-repository-show] command: ```azurecli
az acr repository update \
--write-enabled false ```
+## Check image attributes for tag and its corresponding manifest.
+
+> [!NOTE]
+> * The changeable attributes of tags and manifest are managed separately. That is, setting attribute `deleteEnabled=false` for the tag won't set the same for the corresponding manifest.
+
+>* Query the attributes using the script below:
+
+```bash
+registry="myregistry"
+repo="myimage"
+tag="mytag"
+
+az login
+az acr repository show -n $registry --repository $repo
+az acr manifest show-metadata -r $registry -n "$repo:$tag"
+digest=$(az acr manifest show-metadata -r $registry -n "$repo:$tag" --query digest -o tsv)
+az acr manifest show-metadata -r $registry -n "$repo@$digest"
+```
+ ## Protect an image or repository from deletion ### Protect an image from deletion
cosmos-db How To Migrate Desktop Tool https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/cosmos-db/how-to-migrate-desktop-tool.md
+
+ Title: Migrate data using the desktop data migration tool
+
+description: Use the desktop data migration tool to migrate data from JSON, MongoDB, SQL Server, or Azure Table storage to Azure Cosmos DB.
++++++ Last updated : 05/01/2023++
+# Migrate data to Azure Cosmos DB using the desktop data migration tool
++
+The [Azure Cosmos DB desktop data migration tool](https://github.com/azurecosmosdb/data-migration-desktop-tool) is an open-source command-line application to import or export data from Azure Cosmos DB. The tool can migrate data to and from many sources and sinks including, but not limited to:
+
+- Azure Cosmos DB for NoSQL
+- Azure Cosmos DB for MongoDB
+- Azure Cosmos DB for Table
+- Azure Table storage
+- JSON
+- MongoDB
+- SQL Server
+
+> [!IMPORTANT]
+> For this guide, you will perform a data migration from JSON to Azure Cosmos DB for NoSQL.
+
+## Prerequisites
+
+- An existing Azure Cosmos DB for NoSQL account.
+ - If you have an Azure subscription, [create a new account](nosql/how-to-create-account.md?tabs=azure-portal).
+ - If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
+ - Alternatively, you can [try Azure Cosmos DB free](try-free.md) before you commit.
+- Latest version of [Azure CLI](/cli/azure/install-azure-cli).
+
+## Install the desktop data migration tool
+
+First, install the latest version of the desktop data migration tool from the GitHub repository.
+
+1. In your browser, navigate to the **Releases** section of the repository: [azurecosmosdb/data-migration-desktop-tool/releases](https://github.com/azurecosmosdb/data-migration-desktop-tool/releases).
+
+1. Download the latest compressed folder for your platform. There are compressed folders for the **win-x64**, **mac-x64**, and **linux-x64** platforms.
+
+1. Extract the files to an install location on your local machine.
+
+1. (Optional) Add the desktop data migration tool to the `PATH` environment variable of your local machine.
+
+## Prepare your migration target
+
+Next, create a target database and container on the Azure Cosmos DB for NoSQL account.
+
+### [Azure CLI](#tab/azure-cli)
+
+1. Open a new terminal. If you haven't already, [sign in to the Azure CLI](/cli/azure/authenticate-azure-cli).
+
+1. Create new shell variables for the Azure Cosmos DB account's name and resource group.
+
+ ```azurecli-interactive
+ # Variable for Azure Cosmos DB account name
+ accountName="<name-of-existing-account>"
+
+ # Variable for resource group name
+ resourceGroupName="<name-of-existing-resource-group>"
+ ```
+
+1. Create a new database using [`az cosmosdb sql database create`](/cli/azure/cosmosdb/sql/database#az-cosmosdb-sql-database-create). Name the new database `cosmicworks` and configure the database with 400 RU/s of shared throughput.
+
+ ```azurecli-interactive
+ az cosmosdb sql database create \
+ --resource-group $resourceGroupName \
+ --account-name $accountName \
+ --name cosmicworks \
+ --throughput 400
+ ```
+
+1. Use [`az cosmosdb sql container create`](/cli/azure/cosmosdb/sql/container#az-cosmosdb-sql-container-create) to create a new container named `products` within the `cosmicworks` database. Set the partition key path of the new container to `/category`.
+
+ ```azurecli-interactive
+ az cosmosdb sql container create \
+ --resource-group $resourceGroupName \
+ --account-name $accountName \
+ --database-name cosmicworks \
+ --name products \
+ --partition-key-path "/category"
+ ```
+
+1. Find the *primary connection string* from the list of keys for the account with [`az cosmosdb keys list`](/cli/azure/cosmosdb/keys#az-cosmosdb-keys-list).
+
+ ```azurecli-interactive
+ az cosmosdb keys list \
+ --resource-group $resourceGroupName \
+ --name $accountName \
+ --type connection-strings
+ ```
+
+1. Record the *primary connection string* value. You use this credential later when migrating data with the tool.
+
+### [Azure PowerShell](#tab/azure-powershell)
+
+1. Open a new terminal. If you haven't already, [sign in to the Azure CLI](/cli/azure/authenticate-azure-cli).
+
+1. Create new variables for the Azure Cosmos DB account's name and resource group.
+
+ ```azurepowershell-interactive
+ # Variable for Azure Cosmos DB account name
+ $ACCOUNT_NAME = "<name-of-existing-account>"
+
+ # Variable for resource group name
+ $RESOURCE_GROUP_NAME = "<name-of-existing-resource-group>"
+ ```
+
+1. Create a new database using [`New-AzCosmosDBSqlDatabase`](/powershell/module/az.cosmosdb/new-azcosmosdbsqldatabase). Name the new database `cosmicworks` and configure the database with 400 RU/s of shared throughput.
+
+ ```azurepowershell-interactive
+ $parameters = @{
+ ResourceGroupName = $RESOURCE_GROUP_NAME
+ AccountName = $ACCOUNT_NAME
+ Name = "cosmicworks"
+ Throughput = 400
+ }
+ New-AzCosmosDBSqlDatabase @parameters
+ ```
+
+1. Use [`New-AzCosmosDBSqlContainer`](/powershell/module/az.cosmosdb/new-azcosmosdbsqlcontainer) to create a new container named `products` within the `cosmicworks` database. Set the partition key path of the new container to `/category`.
+
+ ```azurepowershell-interactive
+ $parameters = @{
+ ResourceGroupName = $RESOURCE_GROUP_NAME
+ AccountName = $ACCOUNT_NAME
+ DatabaseName = "cosmicworks"
+ Name = "products"
+ PartitionKeyPath = "/category"
+ PartitionKeyKind = "Hash"
+ }
+ New-AzCosmosDBSqlContainer @parameters
+ ```
+
+1. Find the *primary connection string* from the list of keys for the account with [`Get-AzCosmosDBAccountKey`](/powershell/module/az.cosmosdb/get-azcosmosdbaccountkey).
+
+ ```azurepowershell-interactive
+ $parameters = @{
+ ResourceGroupName = $RESOURCE_GROUP_NAME
+ Name = $ACCOUNT_NAME
+ Type = "ConnectionStrings"
+ }
+ Get-AzCosmosDBAccountKey @parameters
+ ```
+
+1. Record the *primary connection string* value. You use this credential later when migrating data with the tool.
+++
+## Perform a migration operation
+
+Now, migrate data from a JSON array to the newly created Azure Cosmos DB for NoSQL container.
+
+1. Navigate to an empty directory on your local machine. Within that directory, create a new file named **migration-settings.json**.
+
+1. Within the JSON file, create a new empty JSON object:
+
+ ```json
+ {}
+ ```
+
+1. Create a new property named `Source` with the value `json`. Create another new property named `SourceSettings` with an empty object as the value.
+
+ ```json
+ {
+ "Source": "json",
+ "SourceSettings": {}
+ }
+ ```
+
+1. Within the `SourceSettings` object, create a new property named `FilePath` with the value set to this URI: [https://raw.githubusercontent.com/azure-samples/cosmos-db-migration-sample-data/main/nosql-data.json](https://github.com/azure-samples/cosmos-db-migration-sample-data/blob/main/nosql-data.json).
+
+ ```json
+ {
+ "Source": "json",
+ "SourceSettings": {
+ "FilePath": "https://raw.githubusercontent.com/azure-samples/cosmos-db-migration-sample-data/main/nosql-data.json"
+ }
+ }
+ ```
+
+1. Create another new property named `Sink` with the value `cosmos-nosql`. Also, create a property named `SinkSettings` with an empty object.
+
+ ```json
+ {
+ "Source": "json",
+ "SourceSettings": {
+ "FilePath": "https://raw.githubusercontent.com/azure-samples/cosmos-db-migration-sample-data/main/nosql-data.json"
+ },
+ "Sink": "cosmos-nosql",
+ "SinkSettings": {
+ }
+ }
+ ```
+
+1. Within `SinkSettings`, create a property named `ConnectionString` with the *primary connection string* you recorded earlier in this guide as its value.
+
+ ```json
+ {
+ "Source": "json",
+ "SourceSettings": {
+ "FilePath": "https://raw.githubusercontent.com/azure-samples/cosmos-db-migration-sample-data/main/nosql-data.json"
+ },
+ "Sink": "cosmos-nosql",
+ "SinkSettings": {
+ "ConnectionString": "<connection-string-for-existing-account>"
+ }
+ }
+ ```
+
+1. Add `Database`, `Container`, and `PartitionKeyPath` properties with `cosmicworks`, `products`, and `/category` as their values respectively.
+
+ ```json
+ {
+ "Source": "json",
+ "SourceSettings": {
+ "FilePath": "https://raw.githubusercontent.com/azure-samples/cosmos-db-migration-sample-data/main/nosql-data.json"
+ },
+ "Sink": "cosmos-nosql",
+ "SinkSettings": {
+ "ConnectionString": "<connection-string-for-existing-account>",
+ "Database": "cosmicworks",
+ "Container": "products",
+ "PartitionKeyPath": "/category"
+ }
+ }
+ ```
+
+1. **Save** the **migration-settings.json** file.
+
+1. Open a new terminal
+
+1. Run the desktop data migration tool using the `dmt` command.
+
+ ```terminal
+ dmt
+ ```
+
+ > [!NOTE]
+ > If you did not add the installation path to your `PATH` environment variable, you may need to specify the full path to the `dmt` executable.
+
+1. The tool asks for the path to the settings file. Enter the **migration-settings.json** filename here.
+
+ ```output
+ Path to settings file? (leave empty to skip):
+ ```
+
+1. The tool now outputs the sources and sinks used by the migration.
+
+ ```output
+ Using JSON Source
+ Using Cosmos-nosql Sink
+ ```
+
+## Next steps
+
+- Review [options for migrating data to Azure Cosmos DB](migration-choices.md).
cosmos-db Migration Choices https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/cosmos-db/migration-choices.md
If you need help with capacity planning, consider reading our [guide to estimati
|Migration type|Solution|Supported sources|Supported targets|Considerations| |||||| |Offline|[Intra-account container copy](intra-account-container-copy.md)|Azure Cosmos DB for NoSQL|Azure Cosmos DB for NoSQL|&bull; CLI-based; No set up needed. <br/>&bull; Supports large datasets.|
+|Offline|[Azure Cosmos DB desktop data migration tool](how-to-migrate-desktop-tool.md)|&bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB<br/>&bull;Azure Cosmos DB for Table<br/>&bull;Azure Table storage<br/>&bull;JSON Files<br/>&bull;MongoDB<br/>&bull;SQL Server<br/>|&bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB<br/>&bull;Azure Cosmos DB for Table<br/>&bull;Azure Table storage<br/>&bull;JSON Files<br/>&bull;MongoDB<br/>&bull;SQL Server<br/>|&bull; Command-line tool<br/>&bull; Open-source|
|Offline|[Azure Data Factory](../data-factory/connector-azure-cosmos-db.md)| &bull;JSON/CSV Files<br/>&bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB<br/>&bull;MongoDB <br/>&bull;SQL Server<br/>&bull;Table Storage<br/>&bull;Azure Blob Storage <br/> <br/>See the [Azure Data Factory](../data-factory/connector-overview.md) article for other supported sources.|&bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB<br/>&bull;JSON Files <br/><br/> See the [Azure Data Factory](../data-factory/connector-overview.md) article for other supported targets. |&bull; Easy to set up and supports multiple sources.<br/>&bull; Makes use of the Azure Cosmos DB bulk executor library. <br/>&bull; Suitable for large datasets. <br/>&bull; Lack of checkpointing - It means that if an issue occurs during the course of migration, you need to restart the whole migration process.<br/>&bull; Lack of a dead letter queue - It means that a few erroneous files can stop the entire migration process.| |Offline|[Azure Cosmos DB Spark connector](./nosql/quickstart-spark.md)|Azure Cosmos DB for NoSQL. <br/><br/>You can use other sources with additional connectors from the Spark ecosystem.| Azure Cosmos DB for NoSQL. <br/><br/>You can use other targets with additional connectors from the Spark ecosystem.| &bull; Makes use of the Azure Cosmos DB bulk executor library. <br/>&bull; Suitable for large datasets. <br/>&bull; Needs a custom Spark setup. <br/>&bull; Spark is sensitive to schema inconsistencies and this can be a problem during migration. | |Online|[Azure Cosmos DB Spark connector + Change Feed sample](https://github.com/Azure/azure-sdk-for-java/tree/main/sdk/cosmos/azure-cosmos-spark_3_2-12/Samples/DatabricksLiveContainerMigration)|Azure Cosmos DB for NoSQL. <br/><br/>Uses Azure Cosmos DB Change Feed to stream all historic data as well as live updates.| Azure Cosmos DB for NoSQL. <br/><br/>You can use other targets with additional connectors from the Spark ecosystem.| &bull; Makes use of the Azure Cosmos DB bulk executor library. <br/>&bull; Suitable for large datasets. <br/>&bull; Needs a custom Spark setup. <br/>&bull; Spark is sensitive to schema inconsistencies and this can be a problem during migration. |
A summary of migration pathways from your current solution to Azure Cosmso DB fo
|Migration type|Solution|Supported sources|Supported targets|Considerations| ||||||
+|Offline|[Azure Cosmos DB desktop data migration tool](how-to-migrate-desktop-tool.md)|&bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB<br/>&bull;Azure Cosmos DB for Table<br/>&bull;Azure Table storage<br/>&bull;JSON Files<br/>&bull;MongoDB<br/>&bull;SQL Server<br/>|&bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB<br/>&bull;Azure Cosmos DB for Table<br/>&bull;Azure Table storage<br/>&bull;JSON Files<br/>&bull;MongoDB<br/>&bull;SQL Server<br/>|&bull; Command-line tool<br/>&bull; Open-source|
|Online|[Azure Database Migration Service](../dms/tutorial-mongodb-cosmos-db-online.md)| MongoDB|Azure Cosmos DB for MongoDB |&bull; Makes use of the Azure Cosmos DB bulk executor library. <br/>&bull; Suitable for large datasets and takes care of replicating live changes. <br/>&bull; Works only with other MongoDB sources.| |Offline|[Azure Database Migration Service](../dms/tutorial-mongodb-cosmos-db-online.md)| MongoDB| Azure Cosmos DB for MongoDB| &bull; Makes use of the Azure Cosmos DB bulk executor library. <br/>&bull; Suitable for large datasets and takes care of replicating live changes. <br/>&bull; Works only with other MongoDB sources.| |Offline|[Azure Data Factory](../data-factory/connector-azure-cosmos-db-mongodb-api.md)| &bull;JSON/CSV Files<br/>&bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB <br/>&bull;MongoDB<br/>&bull;SQL Server<br/>&bull;Table Storage<br/>&bull;Azure Blob Storage <br/><br/> See the [Azure Data Factory](../data-factory/connector-overview.md) article for other supported sources. | &bull;Azure Cosmos DB for NoSQL<br/>&bull;Azure Cosmos DB for MongoDB <br/>&bull; JSON files <br/><br/> See the [Azure Data Factory](../data-factory/connector-overview.md) article for other supported targets.| &bull; Easy to set up and supports multiple sources. <br/>&bull; Makes use of the Azure Cosmos DB bulk executor library. <br/>&bull; Suitable for large datasets. <br/>&bull; Lack of checkpointing means that any issue during the course of migration would require a restart of the whole migration process.<br/>&bull; Lack of a dead letter queue would mean that a few erroneous files could stop the entire migration process. <br/>&bull; Needs custom code to increase read throughput for certain data sources.|
If you need help with capacity planning, consider reading our [guide to estimati
For APIs other than the API for NoSQL, API for MongoDB and the API for Cassandra, there are various tools supported by each of the API's existing ecosystems.
-**API for Gremlin**
+### API for Gremlin
* [Graph bulk executor library](gremlin/bulk-executor-dotnet.md) * [Gremlin Spark](https://github.com/Azure/azure-cosmosdb-spark/blob/2.4/samples/graphframes/main.scala)
+### API for Table
+
+* [Azure Cosmos DB desktop data migration tool](how-to-migrate-desktop-tool.md)
+ ## Next steps * Trying to do capacity planning for a migration to Azure Cosmos DB?
ddos-protection Ddos Protection Sku Comparison https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/ddos-protection/ddos-protection-sku-comparison.md
Previously updated : 03/20/2023 Last updated : 05/01/2023
The following table shows features and corresponding SKUs.
DDoS Network Protection and DDoS IP Protection have the following limitations: - PaaS services (multi-tenant), which includes Azure App Service Environment for Power Apps, Azure API Management in deployment modes other than those supported above, or Azure Virtual WAN aren't currently supported. -- Protecting a public IP resource attached to a Virtual Network Gateway or NAT Gateway isn't supported.
+- Protecting a public IP resource attached to a NAT Gateway isn't supported.
- Virtual machines in Classic/RDFE deployments aren't supported. - Scenarios in which a single VM is running behind a public IP isn't supported. - Protected resources that include public IP address prefix, or public IP created from public IP address prefix aren't supported. Azure Load Balancer with a public IP created from a public IP prefix is supported.
defender-for-cloud Alerts Reference https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/alerts-reference.md
VM_VbScriptHttpObjectAllocation| VBScript HTTP object allocation detected | High
**(Preview) Previously unseen parameter used in an API call**<br/> (API_UnseenParam) | A single IP was observed accessing one of the API endpoints using a previously unseen or out-of-bounds parameter in the request. Based on historical traffic patterns from the last 30 days, Defender for APIs learns a set of expected parameters associated with calls to an endpoint. The alert was triggered because an IP recently accessed an endpoint using a previously unseen parameter. | Impact | Medium **(Preview) Access from a Tor exit node to an API endpoint**<br/> (API_AccessFromTorExitNode) | An IP address from the Tor network accessed one of your API endpoints. Tor is a network that allows people to access the Internet while keeping their real IP hidden. Though there are legitimate uses, it is frequently used by attackers to hide their identity when they target people's systems online. | Pre-attack | Medium **(Preview) API Endpoint access from suspicious IP**<br/> (API_AccessFromSuspiciousIP) | An IP address accessing one of your API endpoints was identified by Microsoft Threat Intelligence as having a high probability of being a threat. While observing malicious Internet traffic, this IP came up as involved in attacking other online targets. | Pre-attack | High
-**(Preview) Suspicious User Agent detected**<br/> (API_AccessFromSuspiciousUserAgent) |
-The user agent of a request accessing one of your API endpoints contained anomalous values indicative of an attempt at remote code execution. This does not mean that any of your API endpoints have been breached, but it does suggest that an attempted attack is underway. | Execution | Medium
+**(Preview) Suspicious User Agent detected**<br/> (API_AccessFromSuspiciousUserAgent) | The user agent of a request accessing one of your API endpoints contained anomalous values indicative of an attempt at remote code execution. This does not mean that any of your API endpoints have been breached, but it does suggest that an attempted attack is underway. | Execution | Medium
## Next steps
defender-for-cloud Azure Devops Extension https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/azure-devops-extension.md
Title: Configure the Microsoft Security DevOps Azure DevOps extension description: Learn how to configure the Microsoft Security DevOps Azure DevOps extension. Previously updated : 01/24/2023 Last updated : 05/01/2023
The Microsoft Security DevOps uses the following Open Source tools:
| Name | Language | License | |--|--|--|
+| [AntiMalware](https://www.microsoft.com/windows/comprehensive-security) | AntiMalware protection in Windows from Windows Defender, that scans source code and breaks the build if malware has been found | Not Open Source |
| [Bandit](https://github.com/PyCQA/bandit) | Python | [Apache License 2.0](https://github.com/PyCQA/bandit/blob/master/LICENSE) | | [BinSkim](https://github.com/Microsoft/binskim) | Binary--Windows, ELF | [MIT License](https://github.com/microsoft/binskim/blob/main/LICENSE) |
-| [ESlint](https://github.com/eslint/eslint) | JavaScript | [MIT License](https://github.com/eslint/eslint/blob/main/LICENSE) |
| [Credscan](detect-exposed-secrets.md) | Credential Scanner (also known as CredScan) is a tool developed and maintained by Microsoft to identify credential leaks such as those in source code and configuration files <br> common types: default passwords, SQL connection strings, Certificates with private keys | Not Open Source |
+| [ESlint](https://github.com/eslint/eslint) | JavaScript | [MIT License](https://github.com/eslint/eslint/blob/main/LICENSE) |
| [Template Analyzer](https://github.com/Azure/template-analyzer) | ARM template, Bicep file | [MIT License](https://github.com/Azure/template-analyzer/blob/main/LICENSE.txt) | | [Terrascan](https://github.com/accurics/terrascan) | Terraform (HCL2), Kubernetes (JSON/YAML), Helm v3, Kustomize, Dockerfiles, Cloud Formation | [Apache License 2.0](https://github.com/accurics/terrascan/blob/master/LICENSE) | | [Trivy](https://github.com/aquasecurity/trivy) | container images, file systems, git repositories | [Apache License 2.0](https://github.com/aquasecurity/trivy/blob/main/LICENSE) |
defender-for-cloud Create Custom Recommendations https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/create-custom-recommendations.md
Security teams can use the readily available recommendations and regulatory stan
Microsoft Defender for Cloud provides the option of creating custom recommendations and standards for AWS and GCP using KQL queries. You can use a query editor to build and test queries over your data.
-There are three types of resources to create and manage custom recommendations:
+There are three elements involved when creating and managing custom recommendations:
-- **Recommendations** ΓÇô contains:
+- **Recommendation** ΓÇô contains:
- Recommendation details (name, description, severity, remediation logic, etc.) - Recommendation logic in KQL. - The standard it belongs to.
There are three types of resources to create and manage custom recommendations:
|Aspect|Details| |-|:-|
-|Required/Preferred Environmental Requirements| This preview includes only AWS and GCP recommendations. <br> This feature is part of the Defender CSPM bundle in the future. |
-| Required Roles & Permissions | Subscription Owner / Contributor |
+|Required/preferred environmental requirements| This preview includes only AWS and GCP recommendations. <br> This feature will be part of the Defender CSPM plan in the future. |
+| Required roles & permissions | Subscription Owner / Contributor |
|Clouds:| :::image type="icon" source="./media/icons/yes-icon.png"::: National (Azure Government, Azure China 21Vianet) Commercial clouds<br>:::image type="icon" source="./media/icons/no-icon.png"::: National (Azure Government, Azure China 21Vianet) | ## Create a custom recommendation
-1. In Microsoft Defender for Cloud, select Environment Settings.
+1. In Microsoft Defender for Cloud, select **Environment Settings**.
1. Select the relevant account / project.
-1. Select Standards.
+1. Select **Standards**.
-1. Select Create and then select Recommendation.
+1. Select **Create** and then select **Recommendation**.
:::image type="content" source="./media/create-custom-recommendations/select-create-recommendation.png" alt-text="Screenshot showing where to select Create and then Recommendation." lightbox="./media/create-custom-recommendations/select-create-recommendation.png":::
There are three types of resources to create and manage custom recommendations:
1. Select the relevant account / project.
-1. Select Standards
+1. Select Standards.
1. Select Add and then select Standard.
To create a new query using the query editor, select the 'open query editor' but
1. The last row should return all the original columns: "| project Id, Name, Environment, Identifiers, AdditionalData, Record, HealthStatus". >[!Note]
- >The Record field contains the data structure as it is returned from the AWS / GCP API. Use this field to define conditions which will determine if the resource is healthy or unhealthy. <br> You can access internal properties of Record filed using a dot notation. <br>
+ >The Record field contains the data structure as it is returned from the AWS / GCP API. Use this field to define conditions which will determine if the resource is healthy or unhealthy. <br> You can access internal properties of the Record field using a dot notation. <br>
For example: | extend EncryptionType = Record.Encryption.Type. #### Additional instructions
defender-for-cloud Defender For Resource Manager Introduction https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/defender-for-resource-manager-introduction.md
Title: Microsoft Defender for Resource Manager - the benefits and features description: Learn about the benefits and features of Microsoft Defender for Resource Manager Previously updated : 11/09/2021 Last updated : 05/01/2023 -- # Overview of Microsoft Defender for Resource Manager
The cloud management layer is a crucial service connected to all your cloud reso
Microsoft Defender for Resource Manager automatically monitors the resource management operations in your organization, whether they're performed through the Azure portal, Azure REST APIs, Azure CLI, or other Azure programmatic clients. Defender for Cloud runs advanced security analytics to detect threats and alerts you about suspicious activity.
->[!NOTE]
-> Some of these analytics are powered by [Microsoft Defender for Cloud Apps](/cloud-app-security/what-is-cloud-app-security) (formerly known as Microsoft Cloud App Security). To benefit from these analytics, you must activate a Defender for Cloud Apps license. If you have a Defender for Cloud Apps license, then these alerts are enabled by default. To disable the alerts:
->
-> 1. From Defender for Cloud's menu, open **Environment settings**.
-> 1. Select the subscription you want to change.
-> 1. Select **Integrations**.
-> 1. Clear **Allow Microsoft Defender for Cloud Apps to access my data**, and select **Save**.
-- ## Availability |Aspect|Details|
defender-for-cloud Github Action https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/github-action.md
Title: Configure the Microsoft Security DevOps GitHub action description: Learn how to configure the Microsoft Security DevOps GitHub action. Previously updated : 02/15/2023 Last updated : 05/01/2023
Security DevOps uses the following Open Source tools:
| Name | Language | License | |--|--|--|
+| [AntiMalware](https://www.microsoft.com/windows/comprehensive-security) | AntiMalware protection in Windows from Windows Defender, that scans source code and breaks the run if malware has been found | Not Open Source |
| [Bandit](https://github.com/PyCQA/bandit) | Python | [Apache License 2.0](https://github.com/PyCQA/bandit/blob/master/LICENSE) | | [BinSkim](https://github.com/Microsoft/binskim) | Binary--Windows, ELF | [MIT License](https://github.com/microsoft/binskim/blob/main/LICENSE) | | [ESlint](https://github.com/eslint/eslint) | JavaScript | [MIT License](https://github.com/eslint/eslint/blob/main/LICENSE) |
defender-for-cloud Other Threat Protections https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/other-threat-protections.md
Title: Other threat protections from Microsoft Defender for Cloud description: Learn about the threat protections available from Microsoft Defender for Cloud Previously updated : 01/24/2023 Last updated : 05/01/2023 # Other threat protections in Microsoft Defender for Cloud
Some network configurations restrict Defender for Cloud from generating alerts o
For a list of the Azure network layer alerts, see the [Reference table of alerts](alerts-reference.md#alerts-azurenetlayer).
-<a name="azure-mcas"></a>
-
-## Display recommendations in Microsoft Defender for Cloud Apps
-
-Microsoft Defender for Cloud Apps (formerly known as Microsoft Cloud App Security) is a cloud access security broker (CASB) that supports various deployment modes including log collection, API connectors, and reverse proxy. It provides rich visibility, control over data travel, and sophisticated analytics to identify and combat cyberthreats across all your Microsoft and third-party cloud services.
-
-Once Microsoft Defender for Cloud Apps has been enabled, you can then select the integration from within Defender for Cloud's settings. Your security recommendations from Defender for Cloud will appear in Defender for Cloud Apps with no other configuration needed.
-
-> [!NOTE]
-> Defender for Cloud stores security-related customer data in the same geo as its resource. If Microsoft hasn't yet deployed Defender for Cloud in the resource's geo, then it stores the data in the United States. When Microsoft Defender for Cloud Apps is enabled, this information is stored in accordance with the geo location rules of Microsoft Defender for Cloud Apps. For more information, see [Data storage for non-regional services](https://azuredatacentermap.azurewebsites.net/).
-- <a name="alerts-other"></a> ## Stream security alerts from other Microsoft services
defender-for-cloud Regulatory Compliance Dashboard https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/regulatory-compliance-dashboard.md
If you donΓÇÖt have an Azure subscription, create a [free account](https://azure
To step through the features covered in this tutorial: -- [Enable enhanced security features](defender-for-cloud-introduction.md). You can enable these for free for 30 days.-- You must be signed in with an account that has reader access to the policy compliance data. The **Global reader** for the subscription has access to the policy compliance data, but the **Security Reader** role doesn't. At a minimum, you'll need to have **Resource Policy Contributor** and **Security Admin** roles assigned.
+- [Enable enhanced security features](enable-enhanced-security.md). You can enable these for free for 30 days.
+- You must be signed in with an account that has reader access to the policy compliance data. The **Reader** role for the subscription has access to the policy compliance data, but the **Security Reader** role doesn't. At a minimum, you'll need to have **Resource Policy Contributor** and **Security Admin** roles assigned.
## Assess your regulatory compliance
defender-for-cloud Release Notes https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/release-notes.md
Title: Release notes for Microsoft Defender for Cloud description: A description of what's new and changed in Microsoft Defender for Cloud Previously updated : 04/27/2023 Last updated : 05/01/2023 # What's new in Microsoft Defender for Cloud?
You can see a list of all of the [alerts available for Resource Manager](alerts-
### Three alerts in the Defender for Resource Manager plan have been deprecated
-**Estimated date for change: March 2023**
- The following three alerts for the Defender for Resource Manager plan have been deprecated: - `Activity from a risky IP address (ARM.MCAS_ActivityFromAnonymousIPAddresses)`
Updates in January include:
### The Endpoint protection (Microsoft Defender for Endpoint) component is now accessed in the Settings and monitoring page
-In our continuing efforts to simplify your Defender for Cloud configuration experience, we moved the configuration for Endpoint protection (Microsoft Defender for Endpoint) component from the **Environment settings** > **Integrations** page to the **Environment settings** > **Defender plans** > **Settings and monitoring** page, where the other components are managed as well. There's no change to the functionality other than the location in the portal.
+To access Endpoint protection navigate to **Environment settings** > **Defender plans** > **Settings and monitoring**. From here you can set Endpoint protection to **On**. You can also see all of the other components that are managed.
Learn more about [enabling Microsoft Defender for Endpoint](integration-defender-for-endpoint.md) on your servers with Defender for Servers.
defender-for-cloud Support Matrix Cloud Environment https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/defender-for-cloud/support-matrix-cloud-environment.md
Title: Microsoft Defender for Cloud support across cloud types description: Review Defender for Cloud features and plans supported across different clouds -- Previously updated : 03/08/2023 Last updated : 05/01/2023 # Defender for Cloud support for commercial/government clouds
In the support table, **NA** indicates that the feature is not available.
[Agent/extension deployment](monitoring-components.md) | GA | GA | GA [Asset inventory](./asset-inventory.md) | GA | GA | GA [Azure Workbooks support](./custom-dashboards-azure-workbooks.md) | GA | GA | GA
-[Microsoft Defender for Cloud Apps integration](./other-threat-protections.md#display-recommendations-in-microsoft-defender-for-cloud-apps) | GA | GA | GA
**DEFENDER FOR CLOUD PLANS** | | | **[Agentless discovery for Kubernetes](concept-agentless-containers.md)** | Public preview | NA | NA **[Agentless vulnerability assessments for container images.](concept-agentless-containers.md)**<br/><br/> Including registry scanning (up to 20 unique images per billable resources) | Public preview | NA | NA
firewall Enable Top Ten And Flow Trace https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/firewall/enable-top-ten-and-flow-trace.md
To check the status of the AzResourceProvider registration, you can run the Azur
1. In the Diagnostic settings tab, select **Add diagnostic setting**. 2. Type a Diagnostic setting name.
-3. Select **Azure Firewall Fat Flow Log** under **Categories** and any other logs you want to be supported in the firewall.
+3. Select **Azure Firewall Flow Trace Log** under **Categories** and any other logs you want to be supported in the firewall.
4. In Destination details, select **Send to Log Analytics** workspace 1. Choose your desired Subscription and preconfigured Log Analytics workspace. 1. Enable **Resource specific**.
firewall Integrate With Nat Gateway https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/firewall/integrate-with-nat-gateway.md
ThereΓÇÖs no double NAT with this architecture. Azure Firewall instances send th
> [!NOTE] > Deploying NAT gateway with a [zone redundant firewall](deploy-availability-zone-powershell.md) is not recommended deployment option, as the NAT gateway does not support zonal deployment at this time. In order to use NAT gateway with Azure Firewall, a zonal Firewall deployment is required. >
-> In addition, Azure NAT Gateway integration is not currently supported in secured virtual hub network architectures. You must deploy using a hub virtual network architecture. For detailed guidance on integrating NAT gateway with Azure Firewall in a hub and spoke network architecture refer to the [NAT gateway and Azure Firewall integration tutorial](../virtual-network/nat-gateway/tutorial-hub-spoke-nat-firewall.md). For more information about Azure Firewall architecture options, see [What are the Azure Firewall Manager architecture options?](../firewall-manager/vhubs-and-vnets.md).
+> In addition, Azure NAT Gateway integration is not currently supported in secured virtual hub network (vWAN) architectures. You must deploy using a hub virtual network architecture. For detailed guidance on integrating NAT gateway with Azure Firewall in a hub and spoke network architecture refer to the [NAT gateway and Azure Firewall integration tutorial](../virtual-network/nat-gateway/tutorial-hub-spoke-nat-firewall.md). For more information about Azure Firewall architecture options, see [What are the Azure Firewall Manager architecture options?](../firewall-manager/vhubs-and-vnets.md).
## Associate a NAT gateway with an Azure Firewall subnet - Azure PowerShell
load-balancer Load Balancer Troubleshoot https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/load-balancer-troubleshoot.md
When the external clients to the backend VMs go through the load balancer, the I
Standard ILBs are **secure by default**. Basic ILBs allowed connecting to the internet via a *hidden* Public IP address called the default outbound access IP. This isn't recommended for production workloads as the IP address isn't static or locked down via network security groups that you own. If you recently moved from a Basic ILB to a Standard ILB, you should create a Public IP explicitly via [Outbound only](egress-only.md) configuration, which locks down the IP via network security groups. You can also use a [NAT Gateway](../virtual-network/nat-gateway/nat-overview.md) on your subnet. NAT Gateway is the recommended solution for outbound.
+## No inbound connectivity to Standard external Load Balancers (ELB)
+
+### Cause: Standard load balancers and standard public IP addresses are closed to inbound connections unless opened by Network Security Groups. NSGs are used to explicitly permit allowed traffic. If you don't have an NSG on a subnet or NIC of your virtual machine resource, traffic isn't allowed to reach this resource.
+
+**Resolution**
+In order to allow the ingress traffic, add a Network Security Group to the Subnet or interface for your virtual resource.
+ ## Can't change backend port for existing LB rule of a load balancer that has Virtual Machine Scale Set deployed in the backend pool. ### Cause: The backend port can't be modified for a load balancing rule that's used by a health probe for load balancer referenced by Virtual Machine Scale Set
load-balancer Manage Inbound Nat Rules https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/manage-inbound-nat-rules.md
Title: Manage inbound NAT rules for Azure Load Balancer
-description: In this article, you'll learn how to add and remove and inbound NAT rule in the Azure portal.
+description: In this article, you learn how to add and remove and inbound NAT rule using the Azure portal, PowerShell and CLI.
Previously updated : 03/15/2022- Last updated : 05/01/2023+
-# Manage inbound NAT rules for Azure Load Balancer using the Azure portal
+# Manage inbound NAT rules for Azure Load Balancer
An inbound NAT rule is used to forward traffic from a load balancer frontend to one or more instances in the backend pool.
There are two types of inbound NAT rule:
* Multiple virtual machines - An inbound NAT rule that targets multiple virtual machines in the backend pool of the load balancer
-In this article, you'll learn how to add and remove an inbound NAT rule for both types. You'll learn how to change the frontend port allocation in a multiple instance inbound NAT rule.
+In this article, you learn how to add and remove an inbound NAT rule for both types. You learn how to change the frontend port allocation in a multiple instance inbound NAT rule. You can choose from the Azure portal, PowerShell, or CLI examples.
[!INCLUDE [quickstarts-free-trial-note](../../includes/quickstarts-free-trial-note.md)] ## Prerequisites - A standard public load balancer in your subscription. For more information on creating an Azure Load Balancer, see [Quickstart: Create a public load balancer to load balance VMs using the Azure portal](quickstart-load-balancer-standard-public-portal.md). The load balancer name for the examples in this article is **myLoadBalancer**.-
+- If you choose to install and use PowerShell locally, this article requires the Azure PowerShell module version 5.4.1 or later. Run `Get-Module -ListAvailable Az` to find the installed version. If you need to upgrade, see [Install Azure PowerShell module](/powershell/azure/install-Az-ps). If you're running PowerShell locally, you also need to run `Connect-AzAccount` to create a connection with Azure.
[!INCLUDE [azure-cli-prepare-your-environment.md](~/articles/reusable-content/azure-cli/azure-cli-prepare-your-environment-no-header.md)] -- If you choose to install and use PowerShell locally, this article requires the Azure PowerShell module version 5.4.1 or later. Run `Get-Module -ListAvailable Az` to find the installed version. If you need to upgrade, see [Install Azure PowerShell module](/powershell/azure/install-Az-ps). If you're running PowerShell locally, you also need to run `Connect-AzAccount` to create a connection with Azure. ## Add a single VM inbound NAT rule
+Choose this option to configure a rule for a single VM. Select Azure portal, PowerShell, or CLI for instructions.
+ # [**Portal**](#tab/inbound-nat-rule-portal)
-In this example, you'll create an inbound NAT rule to forward port **500** to backend port **443**.
+In this example, you create an inbound NAT rule to forward port **500** to backend port **443**.
1. Sign in to the [Azure portal](https://portal.azure.com).
In this example, you'll create an inbound NAT rule to forward port **500** to ba
# [**PowerShell**](#tab/inbound-nat-rule-powershell)
-In this example, you'll create an inbound NAT rule to forward port **500** to backend port **443**.
- Use [Get-AzLoadBalancer](/powershell/module/az.network/get-azloadbalancer) to place the load balancer information into a variable. Use [Add-AzLoadBalancerInboundNatRuleConfig](/powershell/module/az.network/add-azloadbalancerinboundnatruleconfig) to create the inbound NAT rule.
$lb | Set-AzLoadBalancer
# [**CLI**](#tab/inbound-nat-rule-cli)
-In this example, you'll create an inbound NAT rule to forward port **500** to backend port **443**.
+
+In this example, you create an inbound NAT rule to forward port **500** to backend port **443**.
Use [az network lb inbound-nat-rule create](/cli/azure/network/lb/inbound-nat-rule#az-network-lb-inbound-nat-rule-create) to create the NAT rule.
Use [az network lb inbound-nat-rule create](/cli/azure/network/lb/inbound-nat-ru
--resource-group myResourceGroup \ --backend-pool-name myBackendPool \ --frontend-ip-name myFrontend \
- --frontend-port 500
+ --frontend-port-range-end 1000 \
+ --frontend-port-range-start 500
``` ## Add a multiple VMs inbound NAT rule
+Choose this option to configure a rule with a range of ports to a backend pool of virtual machines. Select Azure portal, PowerShell, or CLI for instructions.
# [**Portal**](#tab/inbound-nat-rule-portal)
-In this example, you'll create an inbound NAT rule to forward a range of ports starting at port 500 to backend port 443. The maximum number of machines in the backend pool is set by the parameter **Maximum number of machines in backend pool** with a value of **500**. This setting will limit the backend pool to **500** virtual machines.
+In this example, you create an inbound NAT rule to forward a range of ports starting at port 500 to backend port 443. The maximum number of machines in the backend pool is set by the parameter **Maximum number of machines in backend pool** with a value of **500**. This setting limits the backend pool to **500** virtual machines.
1. Sign in to the [Azure portal](https://portal.azure.com).
In this example, you'll create an inbound NAT rule to forward a range of ports s
# [**PowerShell**](#tab/inbound-nat-rule-powershell)
-In this example, you'll create an inbound NAT rule to forward a range of ports starting at port 500 to backend port 443. The maximum number of machines in the backend pool is set by the parameter `-FrontendPortRangeEnd` with a value of **1000**. This setting will limit the backend pool to **500** virtual machines.
+In this example, you create an inbound NAT rule to forward a range of ports starting at port 500 to backend port 443. The maximum number of machines in the backend pool is set by the parameter `-FrontendPortRangeEnd` with a value of **1000**. This setting limits the backend pool to **500** virtual machines.
Use [Get-AzLoadBalancer](/powershell/module/az.network/get-azloadbalancer) to place the load balancer information into a variable.
$lb | Set-AzLoadBalancer
# [**CLI**](#tab/inbound-nat-rule-cli)
-In this example, you'll create an inbound NAT rule to forward a range of ports starting at port 500 to backend port 443. The maximum number of machines in the backend pool is set by the parameter `--frontend-port-range-end` with a value of **1000**. This setting will limit the backend pool to **500** virtual machines.
+In this example, you create an inbound NAT rule to forward a range of ports starting at port 500 to backend port 443. The maximum number of machines in the backend pool is set by the parameter `--frontend-port-range-end` with a value of **1000**. This setting limits the backend pool to **500** virtual machines.
Use [az network lb inbound-nat-rule create](/cli/azure/network/lb/inbound-nat-rule#az-network-lb-inbound-nat-rule-create) to create the NAT rule.
Use [az network lb inbound-nat-rule create](/cli/azure/network/lb/inbound-nat-ru
# [**Portal**](#tab/inbound-nat-rule-portal)
-To accommodate more virtual machines in the backend pool in a multiple instance rule, change the frontend port allocation in the inbound NAT rule. In this example, you'll change the **Maximum number of machines in backend pool** from **500** to **1000**. This setting will increase the maximum number of machines in the backend pool to **1000**.
+To accommodate more virtual machines in the backend pool in a multiple instance rule, change the frontend port allocation in the inbound NAT rule. In this example, you change the **Maximum number of machines in backend pool** from **500** to **1000**. This setting increases the maximum number of machines in the backend pool to **1000**.
1. Sign in to the [Azure portal](https://portal.azure.com).
To accommodate more virtual machines in the backend pool in a multiple instance
# [**PowerShell**](#tab/inbound-nat-rule-powershell)
-To accommodate more virtual machines in the backend pool in a multiple instance rule, change the frontend port allocation in the inbound NAT rule. In this example, you'll change the parameter `-FrontendPortRangeEnd` to **1500**. This setting will increase the maximum number of machines in the backend pool to **1000**.
+To accommodate more virtual machines in the backend pool in a multiple instance rule, change the frontend port allocation in the inbound NAT rule. In this example, you change the parameter `-FrontendPortRangeEnd` to **1500**. This setting increases the maximum number of machines in the backend pool to **1000**.
Use [Get-AzLoadBalancer](/powershell/module/az.network/get-azloadbalancer) to place the load balancer information into a variable.
$lb | Set-AzLoadBalancerInboundNatRuleConfig @rule
# [**CLI**](#tab/inbound-nat-rule-cli)
-To accommodate more virtual machines in the backend pool, change the frontend port allocation in the inbound NAT rule. In this example, you'll change the parameter `--frontend-port-range-end` to **1500**. This setting will increase the maximum number of machines in the backend pool to **1000**
+To accommodate more virtual machines in the backend pool, change the frontend port allocation in the inbound NAT rule. In this example, you change the parameter `--frontend-port-range-end` to **1500**. This setting increases the maximum number of machines in the backend pool to **1000**
Use [az network lb inbound-nat-rule update](/cli/azure/network/lb/inbound-nat-rule#az-network-lb-inbound-nat-rule-update) to change the frontend port allocation.
Port mappings for the virtual machines in the backend pool can be viewed by usin
# [**Portal**](#tab/inbound-nat-rule-portal)
-In this example, you'll remove an inbound NAT rule.
+In this example, you remove an inbound NAT rule.
1. Sign in to the [Azure portal](https://portal.azure.com).
In this example, you'll remove an inbound NAT rule.
# [**PowerShell**](#tab/inbound-nat-rule-powershell)
-In this example, you'll remove an inbound NAT rule.
+In this example, you remove an inbound NAT rule.
Use [Get-AzLoadBalancer](/powershell/module/az.network/get-azloadbalancer) to place the load balancer information into a variable.
$lb | Set-AzLoadBalancer
# [**CLI**](#tab/inbound-nat-rule-cli)
-In this example, you'll remove an inbound NAT rule.
+In this example, you remove an inbound NAT rule.
Use [az network lb inbound-nat-rule delete](/cli/azure/network/lb/inbound-nat-rule#az-network-lb-inbound-nat-rule-delete) to remove the rule.
Use [az network lb inbound-nat-rule delete](/cli/azure/network/lb/inbound-nat-ru
## Next steps
-In this article, you learned how to manage inbound NAT rules for an Azure Load Balancer.
+In this article, you learned how to manage inbound NAT rules for an Azure Load Balancer using the Azure portal, PowerShell and CLI.
For more information about Azure Load Balancer, see: - [What is Azure Load Balancer?](load-balancer-overview.md)
load-balancer Quickstart Load Balancer Standard Internal Bicep https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/quickstart-load-balancer-standard-internal-bicep.md
Previously updated : 04/29/2022- Last updated : 05/01/2023+ # Quickstart: Create an internal load balancer to load balance VMs using Bicep
Multiple Azure resources have been defined in the Bicep file:
# [CLI](#tab/CLI) ```azurecli
- az group create --name exampleRG --location eastus
- az deployment group create --resource-group exampleRG --template-file main.bicep --parameters adminUsername=<admin-user>
+ az group create --name CreateIntLBQS-rg --location eastus
+ az deployment group create --resource-group CreateIntLBQS-rg --template-file main.bicep --parameters adminUsername=AzureAdmin
``` # [PowerShell](#tab/PowerShell) ```azurepowershell
- New-AzResourceGroup -Name exampleRG -Location eastus
- New-AzResourceGroupDeployment -ResourceGroupName exampleRG -TemplateFile ./main.bicep -adminUsername "<admin-user>"
+ New-AzResourceGroup -Name CreateIntLBQS-rg -Location eastus
+ New-AzResourceGroupDeployment -ResourceGroupName CreateIntLBQS-rg -TemplateFile ./main.bicep -adminUsername "<admin-user>"
```
Use the Azure portal, Azure CLI, or Azure PowerShell to list the deployed resour
# [CLI](#tab/CLI) ```azurecli-interactive
-az resource list --resource-group exampleRG
+az resource list --resource-group CreateIntLBQS-rg
``` # [PowerShell](#tab/PowerShell) ```azurepowershell-interactive
-Get-AzResource -ResourceGroupName exampleRG
+Get-AzResource -ResourceGroupName CreateIntLBQS-rg
```
When no longer needed, use the Azure portal, Azure CLI, or Azure PowerShell to d
# [CLI](#tab/CLI) ```azurecli-interactive
-az group delete --name exampleRG
+az group delete --name CreateIntLBQS-rg
``` # [PowerShell](#tab/PowerShell) ```azurepowershell-interactive
-Remove-AzResourceGroup -Name exampleRG
+Remove-AzResourceGroup -Name CreateIntLBQS-rg
```
load-balancer Quickstart Load Balancer Standard Internal Cli https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/quickstart-load-balancer-standard-internal-cli.md
description: This quickstart shows how to create an internal load balancer using
Previously updated : 03/23/2022 Last updated : 05/01/2023 -+ #Customer intent: I want to create a load balancer so that I can load balance internal traffic to VMs.
When you create an internal load balancer, a virtual network is configured as th
## Create the virtual network
-Before you deploy VMs and test your load balancer, create the supporting virtual network and subnet. The virtual network and subnet will contain the resources deployed later in this article.
+Before you deploy VMs and test your load balancer, create the supporting virtual network and subnet. The virtual network and subnet contain the resources deployed later in this article.
Create a virtual network by using [az network vnet create](/cli/azure/network/vnet#az-network-vnet-create).
Create a virtual network by using [az network vnet create](/cli/azure/network/vn
## Create an Azure Bastion host
-In this example, you'll create an Azure Bastion host. The Azure Bastion host is used later in this article to securely manage the virtual machines and test the load balancer deployment.
+In this example, you create an Azure Bastion host. The Azure Bastion host is used later in this article to securely manage the virtual machines and test the load balancer deployment.
### Create a bastion public IP address
Create an internal load balancer with [az network lb create](/cli/azure/network/
--sku Standard \ --vnet-name myVNet \ --subnet myBackendSubnet \
- --frontend-ip-name myFrontEnd \
- --backend-pool-name myBackEndPool
+ --backend-pool-name myBackEndPool \
+ --frontend-ip-name myFrontEnd
``` ### Create the health probe
load-balancer Quickstart Load Balancer Standard Internal Template https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/quickstart-load-balancer-standard-internal-template.md
Title: 'Quickstart: Create an internal load balancer - ARM template'
-description: This quickstart shows how to create an internal Azure load balancer using an Azure Resource Manager template (ARM template).
+description: This quickstart creates an internal Azure load balancer using an Azure Resource Manager template (ARM template).
Previously updated : 12/15/2022 Last updated : 05/01/2023
This quickstart describes how to use an Azure Resource Manager template (ARM tem
[!INCLUDE [About Azure Resource Manager](../../includes/resource-manager-quickstart-introduction.md)]
-If your environment meets the prerequisites and you're familiar with using ARM templates, select the **Deploy to Azure** button. The template will open in the Azure portal.
+If your environment meets the prerequisites and you're familiar with using ARM templates, select the **Deploy to Azure** button. The template opens in the Azure portal.
[![Deploy to Azure](../media/template-deployments/deploy-to-azure.svg)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-quickstart-templates%2Fmaster%2Fquickstarts%2Fmicrosoft.compute%2F2-vms-internal-load-balancer%2Fazuredeploy.json)
load-balancer Quickstart Load Balancer Standard Public Cli https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/quickstart-load-balancer-standard-public-cli.md
Last updated 03/16/2022 -+ #Customer intent: I want to create a load balancer so that I can load balance internet traffic to VMs.
load-balancer Quickstart Load Balancer Standard Public Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/quickstart-load-balancer-standard-public-portal.md
During the creation of the load balancer, you'll configure:
| Floating IP | Select **Disabled**. | | Outbound source network address translation (SNAT) | Leave the default of **(Recommended) Use outbound rules to provide backend pool members access to the internet.** |
-1. Select **Add**.
+1. Select **Save**.
1. Select the blue **Review + create** button at the bottom of the page.
load-balancer Quickstart Load Balancer Standard Public Powershell https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/quickstart-load-balancer-standard-public-powershell.md
description: This quickstart shows how to create a load balancer using Azure PowerShell. Previously updated : 03/17/2022 Last updated : 05/01/2023 -+ #Customer intent: I want to create a load balancer so that I can load balance internet traffic to VMs.
New-AzNetworkSecurityGroup @nsg
## Create virtual machines
-In this section, you'll create the two virtual machines for the backend pool of the load balancer.
+In this section, you create the two virtual machines for the backend pool of the load balancer.
* Create two network interfaces with [New-AzNetworkInterface](/powershell/module/az.network/new-aznetworkinterface)
$ns = @{
$nsg = Get-AzNetworkSecurityGroup @ns ## For loop with variable to create virtual machines for load balancer backend pool. ##
-for ($i=1; $i -le 2; $i++)
-{
+for ($i=1; $i -le 2; $i++){
+ ## Command to create network interface for VMs ## $nic = @{ Name = "myNicVM$i"
load-balancer Upgrade Basic Standard Virtual Machine Scale Sets https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/load-balancer/upgrade-basic-standard-virtual-machine-scale-sets.md
The PowerShell module performs the following functions:
>[!NOTE] > If the Virtual Machine Scale Set in the Load Balancer backend pool has Public IP Addresses in its network configuration, the Public IP Addresses will change during migration (the Public IPs must be removed prior to the migration, then added back post migration with a Standard SKU configuration)
+>[!NOTE]
+> If the Virtual Machine Scale Set behind the Load Balancer is a **Service Fabric Cluster**, migration with this script will take more time. In testing, a 5-node Bronze cluster was unavailable for about 30 minutes and a 5-node Silver cluster was unavailable for about 45 minutes. For Service Fabric clusters that require minimal / no connectivity downtime, adding a new nodetype with Standard Load Balancer and IP resources is a better solution.
+ ### Unsupported Scenarios - Basic Load Balancers with a Virtual Machine Scale Set backend pool member that is also a member of a backend pool on a different load balancer
PS C:\> Start-AzBasicLoadBalancerUpgrade -FailedMigrationRetryFilePathLB C:\Reco
## Common Questions
+### Will this migration cause downtime to my application?
+
+Yes, because the Basic Load Balancer needs to be removed before the new Standard Load Balancer can be created, there will be downtime to your application. See [How long does the Upgrade take?](#how-long-does-the-upgrade-take)
+ ### Will the module migrate my frontend IP address to the new Standard Load Balancer? Yes, for both public and internal load balancers, the module ensures that front end IP addresses are maintained. For public IPs, the IP is converted to a static IP prior to migration (if necessary). For internal front ends, the module attempts to reassign the same IP address freed up when the Basic Load Balancer was deleted; if the private IP isn't available the script fails (see [What happens if my upgrade fails mid-migration?](#what-happens-if-my-upgrade-fails-mid-migration)).
Yes, for both public and internal load balancers, the module ensures that front
The upgrade normally takes a few minutes for the script to finish. The following factors may lead to longer upgrade times: - Complexity of your load balancer configuration - Number of backend pool members-- Instance count of associated Virtual Machine Scale Sets.
+- Instance count of associated Virtual Machine Scale Sets
+- Service Fabric Cluster: Upgrades for Service Fabric Clusters take up to an hour in testing.
+ Keep the downtime in mind and plan for failover if necessary. ### Does the script migrate my backend pool members from my Basic Load Balancer to the newly created Standard Load Balancer?
machine-learning How To Troubleshoot Environments https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/machine-learning/how-to-troubleshoot-environments.md
If you've tried installing the command and are experiencing this issue, ensure t
**Troubleshooting steps** A rebuild may fix the issue if it's transient+
+### Image not found
+<!--issueDescription-->
+This issue can happen when the base image you specified can't be found.
+
+**Potential causes:**
+* You specified the image incorrectly
+* The image you specified doesn't exist in the registry you specified
+
+**Affected areas (symptoms):**
+* Failure in building environments from UI, SDK, and CLI.
+* Failure in running jobs because it will implicitly build the environment in the first step.
+<!--/issueDescription-->
+
+**Troubleshooting steps**
+* Ensure that the base image is spelled and formatted correctly
+* Ensure that the base image you're using exists in the registry you specified
+
+**Resources**
+* [Azure Machine Learning base images](https://github.com/Azure/AzureML-Containers)
mariadb Concepts Backup https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/mariadb/concepts-backup.md
Azure Database for MariaDB takes backups of the data files and the transaction
These backup files aren't user-exposed and can't be exported. These backups can only be used for restore operations in Azure Database for MariaDB. You can use [mysqldump](howto-migrate-dump-restore.md) to copy a database.
-The backup type and frequency is depending on the backend storage for the servers.
+The backup type and frequency is dependent on the backend storage for the servers.
### Backup type and frequency
migrate Prepare For Agentless Migration https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/migrate/prepare-for-agentless-migration.md
The preparation script executes the following changes based on the OS type of th
To edit the DHCP startup settings manually, run the following example in Windows PowerShell:
- ```
+ ```powershell
Get-Service -Name Dhcp Where-Object StartType -ne Automatic Set-Service -StartupType Automatic
The preparation script executes the following changes based on the OS type of th
An illustrative example for rebuilding initrd - Back up the existing initrd image-
- ```
+
+ ```bash
cd /boot sudo cp initrd-`uname -r`.img initrd-`uname -r`.img.bak
- ```
+ ```
- Rebuild the initrd with the hv_vmbus and hv_storvsc kernel modules:
- ```
+ ```bash
sudo mkinitrd --preload=hv_storvsc --preload=hv_vmbus -v -f initrd-`uname -r`.img `uname -r`
- ```
+ ```
Most new versions of Linux distributions have this included by default. If not included, install manually for all versions except those called out, using the aforementioned steps. 1. **Enable Azure Serial Console logging**
The preparation script executes the following changes based on the OS type of th
Modify the kernel boot line in GRUB or GRUB2 to include the following parameters, so that all console messages are sent to the first serial port. These messages can assist Azure support with debugging any issues.
- ```
+ ```config
console=ttyS0,115200n8 earlyprintk=ttyS0,115200 rootdelay=300 ``` We also recommend removing the following parameters if they exist.
- ```
+ ```config
rhgb quiet crashkernel=auto ``` [Refer to this article](../virtual-machines/linux/create-upload-generic.md#general-linux-system-requirements) for specific changes.
The preparation script executes the following changes based on the OS type of th
An illustrative example for RedHat servers
- ```console
- # sudo ln -s /etc/udev/rules.d/75-persistent-net-generator.rules
- # sudo rm -f /etc/udev/rules.d/70-persistent-net.rules
+ ```bash
+ sudo ln -s /etc/udev/rules.d/75-persistent-net-generator.rules
+ sudo rm -f /etc/udev/rules.d/70-persistent-net.rules
``` 1. Remove Network Manager if necessary. Network Manager can interfere with the Azure Linux agent for a few OS versions. It's recommended to make these changes for servers running RedHat and Ubuntu distributions.
The preparation script executes the following changes based on the OS type of th
An illustrative example for RedHat servers
- ```console
- # sudo rpm -e --nodeps NetworkManager
+ ```bash
+ sudo rpm -e --nodeps NetworkManager
``` 1. Backup existing NIC settings and create eth0 NIC configuration file with DHCP settings. To do this, the script will create or edit the /etc/sysconfig/network-scripts/ifcfg-eth0 file, and add the following text:
The preparation script executes the following changes based on the OS type of th
You can use the command to verify the service status of the Azure Linux Agent to make sure it's running. The service name might be **walinuxagent** or **waagent**. Once the hydration changes are done, the script will unmount all the partitions mounted, deactivate volume groups, and then flush the devices.
- ```
- $ vgchange -an <vg-name>
- $ blockdev ΓÇôflushbufs <disk-device-name>
+ ```bash
+ sudo vgchange -an <vg-name>
+ sudo lockdev ΓÇôflushbufs <disk-device-name>
``` [Learn more on the changes for Linux servers.](../virtual-machines/linux/create-upload-generic.md)
nat-gateway Manage Nat Gateway https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/manage-nat-gateway.md
+
+ Title: Manage a NAT gateway
+
+description: Learn how to create and remove a NAT gateway resource from a virtual network subnet. Add and remove public IP addresses and prefixes used for outbound connectivity.
++++ Last updated : 03/20/2023+++
+# Manage NAT gateway
+
+Learn how to create and remove a NAT gateway resource from a virtual network subnet. A NAT gateway enables outbound connectivity for resources in an Azure Virtual Network. You can change the public IP addresses and public IP address prefixes associated with the NAT gateway changed after deployment.
+
+This article explains how to manage the following aspects of NAT gateway:
+
+- Create a NAT gateway and associate it with an existing subnet.
+
+- Remove a NAT gateway from an existing subnet and delete the NAT gateway.
+
+- Add or remove a public IP address or public IP prefix.
+
+## Prerequisites
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+- An existing Azure Virtual Network with a subnet. For more information, see [Quickstart: Create a virtual network using the Azure portal](../virtual-network/quick-create-portal.md).
+
+ - The example virtual network that is used in this article is named *myVNet*.
+
+ - The example subnet is named *mySubnet*.
+
+ - The example NAT gateway is named *myNATgateway*.
+
+To use Azure PowerShell for this article, you need:
+
+- Azure PowerShell installed locally or Azure Cloud Shell.
+
+ If you choose to install and use PowerShell locally, this article requires the Azure PowerShell module version 5.4.1 or later. Run `Get-Module -ListAvailable Az` to find the installed version. If you need to upgrade, see [Install Azure PowerShell module](/powershell/azure/install-Az-ps).
+
+ If you run PowerShell locally, you also need to run `Connect-AzAccount` to create a connection with Azure.
+
+- Ensure that your `Az.Network` module is 4.3.0 or later. To verify the installed module, use the command `Get-InstalledModule -Name "Az.Network"`. If the module requires an update, use the command `Update-Module -Name Az.Network`.
+
+- Sign in to Azure PowerShell and select the subscription that you want to use. For more information, see [Sign in with Azure PowerShell](/powershell/azure/authenticate-azureps).
+
+To use Azure CLI for this article, you need:
+
+- Azure CLI version 2.31.0 or later. Azure Cloud Shell uses the latest version.
++
+## Create a NAT gateway and associate it with an existing subnet
+
+You can create a NAT gateway resource and add it to an existing subnet by using the Azure portal, Azure PowerShell, or the Azure CLI.
+
+# [**Azure portal**](#tab/manage-nat-portal)
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the Azure portal, enter *NAT gateway*. Select **NAT gateways** in the search results.
+
+1. Select **Create**.
+
+1. Enter the following information in the **Basics** tab of **Create network address translation (NAT) gateway**.
+
+ - Select your **Subscription**.
+ - Select your resource group or select **Create new** to create a new resource group.
+ - **NAT gateway name**. Enter *myNATgateway*.
+ - Select your **Region**. This example uses **East US 2**.
+ - Select an **Availability zone**. This example uses **No Zone**. For more information about NAT gateway availability, see [NAT gateway and availability zones](nat-availability-zones.md). |
+ - Select a **TCP idle timeout (minutes)**. This example uses the default of **4**.
+
+1. Select the **Outbound IP** tab, or select **Next: Outbound IP**.
+
+1. You can select an existing public IP address or prefix or both to associate with the NAT gateway and enable outbound connectivity.
+
+ - To create a new public IP for the NAT gateway, select **Create a new public IP address**. Enter *myPublicIP-NAT* in **Name**. Select **OK**.
+
+ - To create a new public IP prefix for the NAT gateway, select **Create a new public IP prefix**. Enter *myPublicIPPrefix-NAT* in **Name**. Select a **Prefix size**. Select **OK**.
+
+1. Select the **Subnet** tab, or select **Next: Subnet**.
+
+1. Select your virtual network. In this example, select **myVNet** in the dropdown list.
+
+1. Select the checkbox next to **mySubnet**.
+
+1. Select **Review + create**.
+
+1. Select **Create**.
+
+# [**PowerShell**](#tab/manage-nat-powershell)
+
+### Public IP address
+
+To create a NAT gateway with a public IP address, run the following PowerShell commands.
+
+Use the [New-AzPublicIpAddress](/powershell/module/az.network/new-azpublicipaddress) cmdlet to create a public IP address for the NAT gateway.
+
+```azurepowershell
+## Create public IP address for NAT gateway ##
+$ip = @{
+ Name = 'myPublicIP-NAT'
+ ResourceGroupName = 'myResourceGroup'
+ Location = 'eastus2'
+ Sku = 'Standard'
+ AllocationMethod = 'Static'
+}
+New-AzPublicIpAddress @ip
+```
+
+Use the [New-AzNatGateway](/powershell/module/az.network/new-aznatgateway) cmdlet to create a NAT gateway resource and associate the public IP address that you created. Use the [Set-AzVirtualNetworkSubnetConfig](/powershell/module/az.network/set-azvirtualnetworksubnetconfig) cmdlet to configure the NAT gateway for your virtual network subnet.
+
+```azurepowershell
+## Place the virtual network into a variable. ##
+$net = @{
+ Name = 'myVNet'
+ ResourceGroupName = 'myResourceGroup'
+}
+$vnet = Get-AzVirtualNetwork @net
+
+## Place the public IP address you created previously into a variable. ##
+$pip = @{
+ Name = 'myPublicIP-NAT'
+ ResourceGroupName = 'myResourceGroup'
+}
+$publicIP = Get-AzPublicIPAddress @pip
+
+## Create NAT gateway resource ##
+$nat = @{
+ ResourceGroupName = 'myResourceGroupNAT'
+ Name = 'myNATgateway'
+ IdleTimeoutInMinutes = '10'
+ Sku = 'Standard'
+ Location = 'eastus2'
+ PublicIpAddress = $publicIP
+}
+$natGateway = New-AzNatGateway @nat
+
+## Create the subnet configuration. ##
+$sub = @{
+ Name = 'mySubnet'
+ VirtualNetwork = $vnet
+ NatGateway = $natGateway
+ AddressPrefix = '10.0.2.0/24'
+}
+Set-AzVirtualNetworkSubnetConfig @sub
+
+## Save the configuration to the virtual network. ##
+$vnet | Set-AzVirtualNetwork
+```
+
+### Public IP prefix
+
+To create a NAT gateway with a public IP prefix, use these commands.
+
+Use the [New-AzPublicIpPrefix](/powershell/module/az.network/new-azpublicipprefix) cmdlet to create a public IP prefix for the NAT gateway.
+
+```azurepowershell
+## Create public IP prefix for NAT gateway ##
+$ip = @{
+ Name = 'myPublicIPPrefix-NAT'
+ ResourceGroupName = 'myResourceGroup'
+ Location = 'eastus2'
+ Sku = 'Standard'
+ PrefixLength ='29'
+}
+New-AzPublicIpPrefix @ip
+```
+
+Use the [New-AzNatGateway](/powershell/module/az.network/new-aznatgateway) cmdlet to create a NAT gateway resource and associate the public IP prefix you created. Use the [Set-AzVirtualNetworkSubnetConfig](/powershell/module/az.network/set-azvirtualnetworksubnetconfig) cmdlet to configure the NAT gateway for your virtual network subnet.
+
+```azurepowershell
+## Place the virtual network into a variable. ##
+$net = @{
+ Name = 'myVNet'
+ ResourceGroupName = 'myResourceGroup'
+}
+$vnet = Get-AzVirtualNetwork @net
+
+## Place the public IP prefix you created previously into a variable. ##
+$pip = @{
+ Name = 'myPublicIPPrefix-NAT'
+ ResourceGroupName = 'myResourceGroup'
+}
+$publicIPprefix = Get-AzPublicIPPrefix @pip
+
+## Create NAT gateway resource ##
+$nat = @{
+ ResourceGroupName = 'myResourceGroupNAT'
+ Name = 'myNATgateway'
+ IdleTimeoutInMinutes = '10'
+ Sku = 'Standard'
+ Location = 'eastus2'
+ PublicIpPrefix = $publicIPprefix
+}
+$natGateway = New-AzNatGateway @nat
+
+## Create the subnet configuration. ##
+$sub = @{
+ Name = 'mySubnet'
+ VirtualNetwork = $vnet
+ NatGateway = $natGateway
+}
+Set-AzVirtualNetworkSubnetConfig @sub
+
+## Save the configuration to the virtual network. ##
+$vnet | Set-AzVirtualNetwork
+```
+
+# [**Azure CLI**](#tab/manage-nat-cli)
+
+### Public IP address
+
+To create a NAT gateway with a public IP address, use the following commands.
+
+Use [az network public-ip create](/cli/azure/network/public-ip#az-network-public-ip-create) to create a public IP address for the NAT gateway.
+
+```azurecli
+az network public-ip create \
+ --resource-group myResourceGroup \
+ --location eastus2 \
+ --name myPublicIP-NAT \
+ --sku standard
+```
+
+Use [az network nat gateway create](/cli/azure/network/nat/gateway#az-network-nat-gateway-create) to create a NAT gateway resource and associate the public IP address that you created.
+
+```azurecli
+az network nat gateway create \
+ --resource-group myResourceGroup \
+ --name myNATgateway \
+ --public-ip-addresses myPublicIP-NAT \
+ --idle-timeout 10
+
+```
+
+Use [az network vnet subnet update](/cli/azure/network/vnet/subnet#az-network-vnet-subnet-update) to associate the NAT gateway with your virtual network subnet.
+
+```azurecli
+az network vnet subnet update \
+ --resource-group myResourceGroup \
+ --vnet-name myVNet \
+ --name mySubnet \
+ --nat-gateway myNATgateway
+```
+
+### Public IP prefix
+
+To create a NAT gateway with a public IP prefix, use the following commands.
+
+Use [az network public-ip prefix create](/cli/azure/network/public-ip/prefix#az-network-public-ip-prefix-create) to create a public IP prefix for the NAT gateway.
+
+```azurecli
+az network public-ip prefix create \
+ --length 29 \
+ --resource-group myResourceGroup \
+ --location eastus2 \
+ --name myPublicIPprefix-NAT
+```
+
+Use [az network nat gateway create](/cli/azure/network/nat/gateway#az-network-nat-gateway-create) to create a NAT gateway resource and associate the public IP prefix that you created.
+
+```azurecli
+az network nat gateway create \
+ --resource-group myResourceGroup \
+ --name myNATgateway \
+ --public-ip-prefixes myPublicIPprefix-NAT \
+ --idle-timeout 10
+
+```
+
+Use [az network vnet subnet update](/cli/azure/network/vnet/subnet#az-network-vnet-subnet-update) to associate the NAT gateway with your virtual network subnet.
+
+```azurecli
+az network vnet subnet update \
+ --resource-group myResourceGroup \
+ --vnet-name myVNet \
+ --name mySubnet \
+ --nat-gateway myNATgateway
+```
+++
+## Remove a NAT gateway from an existing subnet and delete the resource
+
+To remove a NAT gateway from an existing subnet, complete the following steps.
+
+# [**Azure portal**](#tab/manage-nat-portal)
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the Azure portal, enter *NAT gateway*. Select **NAT gateways** in the search results.
+
+1. Select **myNATgateway**.
+
+1. Under **Settings**, select **Subnets**.
+
+1. Select **Disassociate** to remove the NAT gateway from the configured subnet.
+
+You can now associate the NAT gateway with a different subnet or virtual network in your subscription. To delete the NAT gateway resource, complete the following steps.
+
+1. In the search box at the top of the Azure portal, enter *NAT gateway*. Select **NAT gateways** in the search results.
+
+1. Select **myNATgateway**.
+
+1. Select **Delete**.
+
+1. Select **Yes**.
+
+# [**PowerShell**](#tab/manage-nat-powershell)
+
+Removing the NAT gateway from a subnet by using Azure PowerShell isn't currently supported.
+
+# [**Azure CLI**](#tab/manage-nat-cli)
+
+Use [az network vnet subnet update](/cli/azure/network/vnet/subnet#az-network-vnet-subnet-update) to remove the NAT gateway from the subnet.
+
+```azurecli
+az network vnet subnet update \
+ΓÇéΓÇéΓÇéΓÇéΓÇéΓÇé--resource-group myResourceGroup \
+ΓÇéΓÇéΓÇéΓÇéΓÇéΓÇé--vnet-name myVNet \
+ΓÇéΓÇéΓÇéΓÇéΓÇéΓÇé--name mySubnet \
+ΓÇéΓÇéΓÇéΓÇéΓÇéΓÇé--remove natGateway
+```
+
+Use [az network nat gateway delete](/cli/azure/network/nat/gateway#az-network-nat-gateway-delete) to delete the NAT gateway resource.
+
+```azurecli
+az network nat gateway delete \
+ --name myNATgateway \
+ --resource-group myResourceGroup
+```
+++
+> [!NOTE]
+> When you delete a NAT gateway, the public IP address or prefix associated with it isn't deleted.
+
+## Add or remove a public IP address
+
+Complete the following steps to add or remove a public IP address from a NAT gateway.
+
+# [**Azure portal**](#tab/manage-nat-portal)
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the Azure portal, enter *Public IP address*. Select **Public IP addresses** in the search results.
+
+1. Select **Create**.
+
+1. Enter the following information in **Create public IP address**.
+
+ | Setting | Value |
+ | - | -- |
+ | Subscription | Select your subscription. |
+ | Resource group | Select your resource group. The example uses **myResourceGroup**. |
+ | Region | Select a region. This example uses **East US 2**. |
+ | Name | Enter *myPublicIP-NAT2*. |
+ | IP version | Select **IPv4**. |
+ | SKU | Select **Standard**. |
+ | Availability zone | Select the default of **Zone-redundant**. |
+ | Tier | Select **Regional**. |
+
+1. Select **Review + create** and then select **Create**.
+
+1. In the search box at the top of the Azure portal, enter *NAT gateway*. Select **NAT gateways** in the search results.
+
+1. Select **myNATgateway**.
+
+1. Under **Settings**, select **Outbound IP**.
+
+1. The IP addresses and prefixes associated with the NAT gateway are displayed. Next to **Public IP addresses**, select **Change**.
+
+1. Next to **Public IP addresses**, select the dropdown for IP addresses. Select the IP address that you created to add to the NAT gateway. To remove an address, unselect it.
+
+1. Select **OK**.
+
+1. Select **Save**.
+
+# [**PowerShell**](#tab/manage-nat-powershell)
+
+### Add public IP address
+
+To add a public IP address to the NAT gateway, add it to an array object along with the current IP addresses. The PowerShell cmdlets replace all the addresses.
+
+In this example, the existing IP address associated with the NAT gateway is named *myPublicIP-NAT*. Replace this value with an array that contains both myPublicIP-NAT and a new IP address. If you have multiple IP addresses already configured, you must also add them to the array.
+
+Use [New-AzPublicIpAddress](/powershell/module/az.network/new-azpublicipaddress) to create a new IP address for the NAT gateway.
+
+```azurepowershell
+## Create public IP address for NAT gateway ##
+$ip = @{
+ Name = 'myPublicIP-NAT2'
+ ResourceGroupName = 'myResourceGroup'
+ Location = 'eastus2'
+ Sku = 'Standard'
+ AllocationMethod = 'Static'
+}
+New-AzPublicIpAddress @ip
+```
+
+Use [Set-AzNatGateway](/powershell/module/az.network/set-aznatgateway) to add the public IP address to the NAT gateway.
+
+```azurepowershell
+## Place NAT gateway into a variable. ##
+$ng = @{
+ Name = 'myNATgateway'
+ ResourceGroupName = 'myResourceGroup'
+}
+$nat = Get-AzNatGateway @ng
+
+## Place the existing public IP address associated with the NAT gateway into a variable. ##
+$ip = @{
+ Name = 'myPublicIP-NAT'
+ ResourceGroupName = 'myResourceGroup'
+}
+$publicIP1 = Get-AzPublicIPaddress @ip
+
+## Place the public IP address you created previously into a variable. ##
+$ip = @{
+ Name = 'myPublicIP-NAT2'
+ ResourceGroupName = 'myResourceGroup'
+}
+$publicIP2 = Get-AzPublicIPaddress @ip
+
+## Place the public IP address variables into an array. ##
+$pipArray = $publicIP1,$publicIP2
+
+## Add the IP address to the NAT gateway. ##
+$nt = @{
+ NatGateway = $nat
+ PublicIpAddress = $pipArray
+}
+Set-AzNatGateway @nt
+```
+
+### Remove public IP address
+
+To remove a public IP from a NAT gateway, create an array object that *doesn't* contain the IP address you want to remove. For example, you have a NAT gateway configured with two public IP addresses. You want to remove one of the IP addresses. The IP addresses associated with the NAT gateway are named myPublicIP-NAT and myPublicIP-NAT2. To remove myPublicIP-NAT2, create an array object for the PowerShell command that contains *only* myPublicIP-NAT. When you apply the command, the array is reapplied to the NAT gateway, and myPublicIP-NAT is the only associated public IP address.
+
+Use [Set-AzNatGateway](/powershell/module/az.network/set-aznatgateway) to remove a public IP address from the NAT gateway.
+
+```azurepowershell
+## Place NAT gateway into a variable. ##
+$ng = @{
+ Name = 'myNATgateway'
+ ResourceGroupName = 'myResourceGroup'
+}
+$nat = Get-AzNatGateway @ng
+
+## Place the existing public IP prefix associated with the NAT gateway into a variable. ##
+$ip = @{
+ Name = 'myPublicIP-NAT'
+ ResourceGroupName = 'myResourceGroup'
+}
+$prefixIP1 = Get-AzPublicIPAddress @ip
+
+## Place the secondary public IP address into a variable. ##
+$ip = @{
+ Name = 'myPublicIP-NAT2'
+ ResourceGroupName = 'myResourceGroup'
+}
+$publicIP2 = Get-AzPublicIPAddress @ip
+
+## Place ONLY the public IP you wish to keep in the array. ##
+$pipArray = $publicIP1
+
+## Add the IP address prefix to the NAT gateway. ##
+$nt = @{
+ NatGateway = $nat
+ PublicIpAddress = $pipArray
+}
+Set-AzNatGateway @nt
+```
+
+# [**Azure CLI**](#tab/manage-nat-cli)
+
+### Add public IP address
+
+In this example, the existing public IP address associated with the NAT gateway is named *myPublicIP-NAT*.
+
+Use [az network public-ip create](/cli/azure/network/public-ip#az-network-public-ip-create) to create a new IP address for the NAT gateway.
+
+```azurecli
+az network public-ip create \
+ --resource-group myResourceGroup \
+ --location eastus2 \
+ --name myPublicIP-NAT2 \
+ --sku standard
+```
+
+Use [az network nat gateway update](/cli/azure/network/nat/gateway#az-network-nat-gateway-update) to add the public IP address that you created to the NAT gateway. The Azure CLI command replaces the values. It doesn't add a new value. To add the new IP address to the NAT gateway, you must also include any other IP addresses associated to the NAT gateway.
+
+```azurecli
+az network nat gateway update \
+ --name myNATgateway \
+ --resource-group myResourceGroup \
+ --public-ip-addresses myPublicIP-NAT myPublicIP-NAT2
+```
+
+### Remove public IP address
+
+Use [az network nat gateway update](/cli/azure/network/nat/gateway#az-network-nat-gateway-update) to remove a public IP address from the NAT gateway. The Azure CLI command replaces the values. It doesn't remove a value. To remove a public IP address, include any IP address in the command that you want to keep. Omit the value that you want to remove. For example, you have a NAT gateway configured with two public IP addresses. You want to remove one of the IP addresses. The IP addresses associated with the NAT gateway are named myPublicIP-NAT and myPublicIP-NAT2. To remove myPublicIP-NAT2, omit the name of the IP address from the command. The command reapplies the IP addresses listed in the command to the NAT gateway. It removes any IP address not listed.
+
+```azurecli
+az network nat gateway update \
+ --name myNATgateway \
+ --resource-group myResourceGroup \
+ --public-ip-addresses myPublicIP-NAT
+```
+++
+## Add or remove a public IP prefix
+
+Complete the following steps to add or remove a public IP prefix from a NAT gateway.
+
+# [**Azure portal**](#tab/manage-nat-portal)
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the Azure portal, enter *Public IP prefix*. Select **Public IP Prefixes** in the search results.
+
+1. Select **Create**.
+
+1. Enter the following information in the **Basics** tab of **Create a public IP prefix**.
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select your resource group. This example uses **myResourceGroup**. |
+ | **Instance details** | |
+ | Name | Enter *myPublicIPPrefix-NAT*. |
+ | Region | Select your region. This example uses **East US 2**. |
+ | IP version | Select **IPv4**. |
+ | Prefix ownership | Select **Microsoft owned**. |
+ | Prefix size | Select a prefix size. This example uses **/28 (16 addresses)**. |
+
+1. Select **Review + create**, then select **Create**.
+
+1. In the search box at the top of the Azure portal, enter *NAT gateway*. Select **NAT gateways** in the search results.
+
+1. Select **myNATgateway**.
+
+1. Under **Settings**, select **Outbound IP**.
+
+1. The page displays the IP addresses and prefixes associated with the NAT gateway. Next to **Public IP prefixes**, select **Change**.
+
+1. Next to **Public IP Prefixes**, select the dropdown box. Select the IP address prefix that you created to add the prefix to the NAT gateway. To remove a prefix, unselect it.
+
+1. Select **OK**.
+
+1. Select **Save**.
+
+# [**PowerShell**](#tab/manage-nat-powershell)
+
+### Add public IP prefix
+
+To add a public IP prefix to the NAT gateway, add it to an array object along with the current IP prefixes. The PowerShell cmdlets replace all the IP prefixes.
+
+In this example, the existing public IP prefix associated with the NAT gateway is named *myPublicIPprefix-NAT*. Replace this value with an array that contains both myPublicIPprefix-NAT and a new IP address prefix. If you have multiple IP prefixes already configured, you must also add them to the array.
+
+Use [New-AzPublicIpPrefix](/powershell/module/az.network/new-azpublicipprefix) to create a new public IP prefix for the NAT gateway.
+
+```azurepowershell
+## Create public IP prefix for NAT gateway ##
+$ip = @{
+ Name = 'myPublicIPPrefix-NAT2'
+ ResourceGroupName = 'myResourceGroup'
+ Location = 'eastus2'
+ Sku = 'Standard'
+ PrefixLength = '29'
+}
+New-AzPublicIpPrefix @ip
+```
+
+Use [Set-AzNatGateway](/powershell/module/az.network/set-aznatgateway) to add the public IP prefix to the NAT gateway.
+
+```azurepowershell
+## Place NAT gateway into a variable. ##
+$ng = @{
+ Name = 'myNATgateway'
+ ResourceGroupName = 'myResourceGroup'
+}
+$nat = Get-AzNatGateway @ng
+
+## Place the existing public IP prefix associated with the NAT gateway into a variable. ##
+$ip = @{
+ Name = 'myPublicIPprefix-NAT'
+ ResourceGroupName = 'myResourceGroup'
+}
+$prefixIP1 = Get-AzPublicIPPrefix @ip
+
+## Place the public IP prefix you created previously into a variable. ##
+$ip = @{
+ Name = 'myPublicIPprefix-NAT2'
+ ResourceGroupName = 'myResourceGroup'
+}
+$prefixIP2 = Get-AzPublicIPprefix @ip
+
+## Place the public IP address variables into an array. ##
+$preArray = $prefixIP1,$prefixIP2
+
+## Add the IP address prefix to the NAT gateway. ##
+$nt = @{
+ NatGateway = $nat
+ PublicIpPrefix = $preArray
+}
+Set-AzNatGateway @nt
+```
+
+### Remove public IP prefix
+
+To remove a public IP prefix from a NAT gateway, create an array object that *doesn't* contain the IP address prefix that you want to remove. For example, you have a NAT gateway configured with two public IP prefixes. You want to remove one of the IP prefixes. The IP prefixes associated with the NAT gateway are named myPublicIPprefix-NAT and myPublicIPprefix-NAT2. To remove myPublicIPprefix-NAT2, create an array object for the PowerShell command that contains *only* myPublicIPprefix-NAT. When you apply the command, the array is reapplied to the NAT gateway, and myPublicIPprefix-NAT is the only prefix associated.
+
+Use the [Set-AzNatGateway](/powershell/module/az.network/set-aznatgateway) cmdlet to remove a public IP prefix from the NAT gateway.
+
+```azurepowershell
+## Place NAT gateway into a variable. ##
+$ng = @{
+ Name = 'myNATgateway'
+ ResourceGroupName = 'myResourceGroup'
+}
+$nat = Get-AzNatGateway @ng
+
+## Place the existing public IP prefix associated with the NAT gateway into a variable. ##
+$ip = @{
+ Name = 'myPublicIPprefix-NAT'
+ ResourceGroupName = 'myResourceGroup'
+}
+$prefixIP1 = Get-AzPublicIPPrefix @ip
+
+## Place the secondary public IP prefix into a variable. ##
+$ip = @{
+ Name = 'myPublicIPprefix-NAT2'
+ ResourceGroupName = 'myResourceGroup'
+}
+$prefixIP2 = Get-AzPublicIPprefix @ip
+
+## Place ONLY the prefix you wish to keep in the array. DO NOT ADD THE SECONDARY VARIABLE ##
+$preArray = $prefixIP1
+
+## Add the IP address prefix to the NAT gateway. ##
+$nt = @{
+ NatGateway = $nat
+ PublicIpPrefix = $preArray
+}
+Set-AzNatGateway @nt
+```
+
+# [**Azure CLI**](#tab/manage-nat-cli)
+
+### Add public IP prefix
+
+In this example, the existing public IP prefix associated with the NAT gateway is named *myPublicIPprefix-NAT*.
+
+Use [az network public-ip prefix create](/cli/azure/network/public-ip/prefix#az-network-public-ip-prefix-create) to create a public IP prefix for the NAT gateway.
+
+```azurecli
+az network public-ip prefix create \
+ --length 29 \
+ --resource-group myResourceGroup \
+ --location eastus2 \
+ --name myPublicIPprefix-NAT2
+```
+
+Use [az network nat gateway update](/cli/azure/network/nat/gateway#az-network-nat-gateway-update) to add the public IP prefix that you created to the NAT gateway. The Azure CLI command replaces values. It doesn't add a value. To add the new IP address prefix to the NAT gateway, you must also include any other IP prefixes associated to the NAT gateway.
+
+```azurecli
+az network nat gateway update \
+ --name myNATgateway \
+ --resource-group myResourceGroup \
+ --public-ip-prefixes myPublicIPprefix-NAT myPublicIPprefix-NAT2
+```
+
+### Remove public IP prefix
+
+Use [az network nat gateway update](/cli/azure/network/nat/gateway#az-network-nat-gateway-update) to remove a public IP prefix from the NAT gateway. The Azure CLI command replaces the values. It doesn't remove a value. To remove a public IP prefix, include any prefix in the command that you wish to keep. Omit the one you want to remove. For example, you have a NAT gateway configured with two public IP prefixes. You want to remove one of the prefixes. The IP prefixes associated with the NAT gateway are named myPublicIPprefix-NAT and myPublicIPprefix-NAT2. To remove myPublicIPprefix-NAT2, omit the name of the IP prefix from the command. The command reapplies the IP prefixes listed in the command to the NAT gateway. It removes any IP address not listed.
+
+```azurecli
+az network nat gateway update \
+ --name myNATgateway \
+ --resource-group myResourceGroup \
+ --public-ip-prefixes myPublicIPprefix-NAT
+```
+++
+## Next steps
+
+To learn more about Azure Virtual Network NAT and its capabilities, see the following articles:
+
+- [What is Azure NAT Gateway?](nat-overview.md)
+- [NAT gateway and availability zones](nat-availability-zones.md)
+- [Design virtual networks with NAT gateway](nat-gateway-resource.md)
nat-gateway Nat Availability Zones https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/nat-availability-zones.md
+
+ Title: NAT gateway and availability zones
+
+description: Key concepts and design guidance on using NAT gateway with availability zones.
++++ Last updated : 09/14/2022+++
+# NAT gateway and availability zones
+NAT gateway is a zonal resource, which means it can be deployed and operate out of individual availability zones. With zone isolation scenarios, you can align your zonal NAT gateway resources with zonally designated IP based resources, such as virtual machines, to provide zone resiliency against outages. Review this document to understand key concepts and fundamental design guidance.
++
+*Figure 1: Zonal deployment of NAT gateway.*
+
+NAT gateway can either be designated to a specific zone within a region or to ΓÇÿno zoneΓÇÖ. Which zone property you select for your NAT gateway resource will inform the zone property of the public IP address that can be used for outbound connectivity as well.
+
+## NAT gateway has built in resiliency
+
+Virtual networks and their subnets are regional. Subnets aren't restricted to a zone. While NAT gateway is a zonal resource, it's a highly resilient and reliable method by which to connect outbound to the internet from virtual network subnets. NAT gateway uses [software defined networking](/azure-stack/hci/concepts/software-defined-networking) to operate as a fully managed and distributed service. NAT gateway infrastructure has built in redundancy. It can survive multiple infrastructure component failures. Availability zones build on this resiliency with zone isolation scenarios for NAT gateway.
+
+## Zonal
+
+You can place your NAT gateway resource in a specific zone for a region. When NAT gateway is deployed to a specific zone, it will provide outbound connectivity to the internet explicitly from that zone. The public IP address or prefix configured to NAT gateway must match the same zone. NAT gateway resources with public IP addresses from a different zone, zone-redundancy or with no zone aren't allowed.
+
+NAT gateway can provide outbound connectivity for virtual machines from other availability zones different from itself. The virtual machineΓÇÖs subnet needs to be configured to the NAT gateway resource to provide outbound connectivity. Additionally, multiple subnets can be configured to the same NAT gateway resource.
+
+While virtual machines in subnets from different availability zones can all be configured to a single zonal NAT gateway resource, this configuration doesn't provide the most effective method for ensuring zone-resiliency against zonal outages. For more information on how to safeguard against zonal outages, see [Design considerations](#design-considerations) later in this article.
+
+## Non-zonal
+If no zone is selected at the time that the NAT gateway resource is deployed, then it's placed in ΓÇÿno zoneΓÇÖ by default. When NAT gateway is placed in **no zone**, Azure places the resource in a zone for you. You won't have visibility into which zone Azure chooses for your NAT gateway. After NAT gateway is deployed, zonal configurations can't be changed. **No zone** NAT gateway resources, while still zonal resources can be associated to public IP addresses from a zone, no zone, or that are zone-redundant.
+
+## Design considerations
+
+Now that you understand the zone-related properties for NAT gateway, see the following design considerations to help you design for highly resilient outbound connectivity from Azure virtual networks.
+
+### Single zonal NAT gateway resource for zone-spanning resources
+
+A single zonal NAT gateway resource can be configured to either a subnet that contains virtual machines that span across multiple availability zones or to multiple subnets with different zonal virtual machines. When this type of deployment is configured, NAT gateway will provide outbound connectivity to the internet for all subnet resources from the specific zone it's located. If the zone that NAT gateway is deployed in goes down, then outbound connectivity across all virtual machine instances associated with the NAT gateway will also go down. This set up doesn't provide the best method of zone-resiliency.
++
+*Figure 2: Single zonal NAT gateway resource for multi-zone spanning resources doesn't provide an effective method of zone-resiliency against outages.*
+
+### Zonal NAT gateway resource for each zone in a region to create zone-resiliency
+
+A zonal promise for zone isolation scenarios exists when a virtual machine instance using a NAT gateway resource is in the same zone as the NAT gateway resource and its public IP addresses. The pattern you want to use for zone isolation is creating a "zonal stack" per availability zone. This "zonal stack" consists of virtual machine instances, a NAT gateway resource with public IP addresses or prefix on a subnet all in the same zone.
++
+*Figure 3: Zonal isolation by creating zonal stacks with the same zone NAT gateway, public IPs, and virtual machines provides the best method of ensuring zone resiliency against outages.*
+
+Failure of outbound connectivity due to a zone outage is isolated to the specific zone affected. The outage won't affect the other zonal stacks where other NAT gateways are deployed with their own subnets and zonal public IPs.
+
+Creating zonal stacks for each availability zone within a region is the most effective method for building zone-resiliency against outages for NAT gateway.
+
+### Integration of inbound with a standard load balancer
+
+If your scenario requires inbound endpoints, you have two options:
+
+| Option | Pattern | Example | Pro | Con |
+||||||
+| (1) | **Align** the inbound endpoints with the respective **zonal stacks** you're creating for outbound. | Create a standard load balancer with a zonal frontend. | Same failure model for inbound and outbound. Simpler to operate. | Individual IP addresses per zone may need to be masked by a common DNS name. |
+| (2) | **Overlay** the zonal stacks with a cross-zone inbound endpoint. | Create a standard load balancer with a zone-redundant front-end. | Single IP address for inbound endpoint. | Varying models for inbound and outbound. More complex to operate. |
+
+> [!NOTE]
+> Note that zonal configuration for a load balancer works differently from NAT gateway. The load balancer's availability zone selection is synonymous with its frontend IP configuration's zone selection. For public load balancers, if the public IP in the Load balancer's frontend is zone redundant then the load balancer is also zone-redundant. If the public IP in the load balancer's frontend is zonal, then the load balancer will also be designated to the same zone.
+
+## Limitations
+
+* Zones can't be changed, updated, or created for NAT gateway after deployment.
+
+## Next steps
+
+* Learn more about [Azure regions and availability zones](../availability-zones/az-overview.md)
+* Learn more about [Azure NAT Gateway](./nat-overview.md)
+* Learn more about [Azure Load balancer](../load-balancer/load-balancer-overview.md)
nat-gateway Nat Gateway Resource https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/nat-gateway-resource.md
+
+ Title: Design virtual networks with NAT gateway
+
+description: Learn how to design virtual networks that use Network Address Translation (NAT) gateway resources.
+++++ Last updated : 12/06/2022+++
+# Design virtual networks with NAT gateway
+
+NAT gateway provides outbound internet connectivity for one or more subnets of a virtual network. Once NAT gateway is associated to a subnet, NAT gateway provides source network address translation (SNAT) for that subnet. NAT gateway specifies which static IP addresses virtual machines use when creating outbound flows. Static IP addresses come from public IP addresses, public IP prefixes, or both. If a public IP prefix is used, all IP addresses of the entire public IP prefix are consumed by a NAT gateway. A NAT gateway can use up to 16 static IP addresses from either.
++
+*Figure: NAT gateway for outbound to internet*
+
+## How to deploy NAT
+
+Deployments are intentionally made simple:
+
+NAT gateway:
+
+- Create a non-zonal or zonal NAT gateway.
+
+- Assign a public IP address or public IP prefix.
+
+- If necessary, modify TCP idle timeout (optional). Review [timers](#timers) before you change the default.
+
+Virtual network:
+
+- Configure virtual network subnet to use a NAT gateway.
+
+User-defined routes aren't necessary.
+
+## Design guidance
+
+Review this section to familiarize yourself with considerations for designing virtual networks with NAT gateway.
+
+### Connect to Azure services with Private Link
+
+Connecting from your Azure virtual network to Azure PaaS services can be done directly over the Azure backbone and bypass the internet. When you bypass the internet to connect to other Azure PaaS services, you free up SNAT ports and reduce the risk of SNAT port exhaustion. [Private Link](../private-link/private-link-overview.md) should be used when possible to connect to Azure PaaS services in order to free up SNAT port inventory.
+
+Private Link uses the private IP addresses of your virtual machines or other compute resources from your Azure network to directly connect privately and securely to Azure PaaS services over the Azure backbone. See a list of [available Azure services](../private-link/availability.md) that are supported by Private Link.
+
+### Connect to the internet with NAT gateway
+
+NAT gateway is recommended for all production workloads where you need to connect to a public endpoint over the internet. Outbound connectivity takes place right away upon deployment of a NAT gateway with a subnet and at least one public IP address. No additional routing configurations are required to start connecting outbound with NAT gateway. NAT gateway becomes the default route to the internet after association to a subnet.
+
+In the presence of other outbound configurations within a virtual network, such as Load balancer or instance-level public IPs (IL PIPs), NAT gateway takes precedence for outbound connectivity. All new outbound initiated and return traffic starts using NAT gateway. There's no down time on outbound connectivity after adding NAT gateway to a subnet with existing outbound configurations.
+
+### Coexistence of outbound and inbound connectivity
+
+NAT gateway, load balancer and instance-level public IPs are flow direction aware. NAT gateway can coexist in the same virtual network as a load balancer and instance-level public IPs to provide outbound and inbound connectivity seamlessly. Inbound traffic through a load balancer or instance-level public IPs is translated separately from outbound traffic through NAT gateway.
+
+The following examples demonstrate co-existence of a load balancer or instance-level public IPs with a NAT gateway. Inbound traffic traverses the load balancer or public IP. Outbound traffic traverses the NAT gateway.
+
+#### NAT and VM with an instance-level public IP
++
+*Figure: NAT gateway and VM with an instance level public IP*
+
+| Direction | Resource |
+|::|::|
+| Inbound | VM with instance-level public IP |
+| Outbound | NAT gateway |
+
+VM will use NAT gateway for outbound. Inbound originated isn't affected.
+
+#### NAT and VM with a standard public load balancer
++
+*Figure: NAT gateway and VM with a standard public load balancer*
+
+| Direction | Resource |
+|::|::|
+| Inbound | Standard public load balancer |
+| Outbound | NAT gateway |
+
+Any outbound configuration from a load-balancing rule or outbound rules is superseded by NAT gateway. Inbound originated isn't affected.
+
+#### NAT and VM with an instance-level public IP and a standard public load balancer
++
+*Figure: Virtual Network NAT and VM with an instance-level public IP and a standard public load balancer*
+
+| Direction | Resource |
+|::|::|
+| Inbound | VM with instance-level public IP and a standard public load balancer |
+| Outbound | NAT gateway |
+
+Any outbound configuration from a load-balancing rule or outbound rules is superseded by NAT gateway. The VM will also use NAT gateway for outbound. Inbound originated isn't affected.
+
+### Monitor outbound network traffic with NSG flow logs
+
+A network security group allows you to filter inbound and outbound traffic to and from a virtual machine. To monitor outbound traffic flowing from the virtual machine behind your NAT gateway, enable NSG flow logs.
+
+To learn more about NSG flow logs, see [NSG Flow Log Overview](../network-watcher/network-watcher-nsg-flow-logging-overview.md).
+
+For guides on how to enable NSG flow logs, see [Enabling NSG Flow Logs](../network-watcher/network-watcher-nsg-flow-logging-overview.md#enabling-nsg-flow-logs).
+
+## Performance
+
+Each NAT gateway can provide up to 50 Gbps of throughput. This data throughput includes data processed both outbound and inbound through a NAT gateway resource. You can split your deployments into multiple subnets and assign each subnet or group of subnets a NAT gateway to scale out.
+
+NAT gateway can support up to 50,000 concurrent connections per public IP address **to the same destination endpoint** over the internet for TCP and UDP. The total number of connections that NAT gateway can support at any given time is up to 2 million. NAT gateway can process 1M packets per second and scale up to 5M packets per second.
+
+Review the following section for details and the [troubleshooting article](./troubleshoot-nat.md) for specific problem resolution guidance.
+
+## Scalability
+
+Scaling NAT gateway is primarily a function of managing the shared, available SNAT port inventory. NAT gateway needs sufficient SNAT port inventory for expected peak outbound flows for all subnets that are attached to a NAT gateway. You can use public IP addresses, public IP prefixes, or both to create SNAT port inventory.
+
+A single NAT gateway can scale up to 16 IP addresses. Each NAT gateway public IP address provides 64,512 SNAT ports to make outbound connections. NAT gateway can scale up to over 1 million SNAT ports. TCP and UDP are separate SNAT port inventories and are unrelated to NAT gateway.
+
+> [!NOTE]
+> If you assign a public IP prefix, the entire public IP prefix is used. You can't assign a public IP prefix and then break out individual IP addresses to assign to other resources. If you want to assign individual IP addresses from a public IP prefix to multiple resources, you need to create individual public IP addresses and assign them as needed instead of using the public IP prefix itself.
+
+When you scale your workload, assume that each flow requires a new SNAT port, and then scale the total number of available IP addresses for outbound traffic. Carefully consider the scale you're designing for, and then allocate IP addresses quantities accordingly.
+
+SNAT maps private addresses in your subnet to one or more public IP addresses attached to NAT gateway, rewriting the source address and source port in the process. SNAT ports sent to different destinations will most likely be reused when possible. As SNAT port exhaustion approaches, flows may not succeed.
+
+For a SNAT example, see [SNAT fundamentals](#source-network-address-translation).
+
+## Protocols
+
+NAT gateway interacts with IP and IP transport headers of UDP and TCP flows. NAT gateway is agnostic to application layer payloads. Other IP protocols aren't supported.
+
+## Source Network Address Translation
+
+### Fundamentals
+
+Source Network Address Translation (SNAT) rewrites the source of a flow to originate from a different IP address and/or port. Typically, SNAT is used when a private network needs to connect to a public host over the internet. SNAT allows multiple VM instances within the private VNet to use the same single Public IP address or set of IP addresses (prefix) to connect to the internet.
+
+NAT gateway uses SNAT to translate the private IP address and port of a virtual machine to a static public IP address and port. Traffic is translated before leaving the virtual network for the Internet. Each new connection to the same destination endpoint uses a different SNAT port so that connections can be distinguished from one another. SNAT port exhaustion occurs when a source endpoint has run out of available SNAT ports to differentiate between new connections.
+
+### Example SNAT flows for NAT gateway
+
+NAT gateway provides a many to one configuration in which multiple virtual machine instances within a NAT gatway configured subnet can use the same public IP address to connect outbound.
+
+In the following table, two different virtual machines (10.0.0.1 and 10.2.0.1) makes connections to https://microsoft.com destination IP 23.53.254.142. When NAT gateway is configured with public IP address 65.52.1.1, each virtual machine's source IPs are translated into NAT gateway's public IP address and a SNAT port:
+
+| Flow | Source tuple | Source tuple after SNAT | Destination tuple |
+|::|::|::|::|
+| 1 | 10.0.0.1: 4283 | **65.52.1.1: 1234** | 23.53.254.142: 80 |
+| 2 | 10.0.0.1: 4284 | **65.52.1.1: 1235** | 23.53.254.142: 80 |
+| 3 | 10.2.0.1: 5768 | **65.52.1.1: 1236** | 23.53.254.142: 80 |
+
+"IP masquerading" or "port masquerading" is the act of replacing the private IP and port with the public IP and port before connecting to the internet. Multiple private resources can be masqueraded behind the same public IP of NAT gateway.
+
+### NAT gateway dynamically allocates SNAT ports
+
+NAT gateway dynamically allocates SNAT ports across a subnet's private resources such as virtual machines. SNAT port inventory is made available by attaching public IP addresses to NAT gateway. All available SNAT ports can be used on-demand by any virtual machine in subnets configured with NAT gateway:
++
+*Figure: NAT gateway on-demand outbound SNAT*
+
+Pre-allocation of SNAT ports to each virtual machine is required for other SNAT methods. This pre-allocation of SNAT ports can cause SNAT port exhaustion on some virtual machines while others still have available SNAT ports for connecting outbound. With NAT gateway, pre-allocation of SNAT ports isn't required, which means SNAT ports aren't left unused by VMs not actively needing them.
++
+*Figure: Differences in exhaustion scenarios*
+
+After a SNAT port is released, it's available for use by any VM on subnets configured with NAT. On-demand allocation allows dynamic and divergent workloads on subnets to use SNAT ports as needed. As long as SNAT ports are available, SNAT flows will succeed.
+
+### Source (SNAT) port reuse
+
+NAT gateway selects a port at random out of the available inventory of ports to make new outbound connections. If NAT gateway doesn't find any available SNAT ports, then it will reuse a SNAT port. A SNAT port can be reused when connecting to a different destination IP and port as shown in the following table with this extra flow.
+
+| Flow | Source tuple | Source tuple after SNAT | Destination tuple |
+|::|::|::|::|
+| 4 | 10.0.0.1: 4285 | 65.52.1.1: **1234** | 23.53.254.143: 80 |
+
+A NAT gateway will translate flow 4 to a SNAT port that may already be in use for other destinations as well (see flow 1 from previous table). See [Scale NAT gateway](#scalability) for more discussion on correctly sizing your IP address provisioning.
+
+Don't take a dependency on the specific way source ports are assigned in the above example. The preceding is an illustration of the fundamental concept only.
+
+## Timers
+
+### Port Reuse Timers
+
+Port reuse timers determine the amount of time after a connection closes that a source port is in hold down before it can be reused to go to the same destination endpoint by NAT gateway.
+
+The following table provides information about when a TCP port becomes available for reuse to the same destination endpoint by NAT gateway.
+
+| Timer | Description | Value |
+||||
+| TCP FIN | After a connection is closed by a TCP FIN packet, a 65-second timer is activated that holds down the SNAT port. The SNAT port will be available for reuse after the timer ends. | 65 seconds |
+| TCP RST | After a connection is closed by a TCP RST packet (reset), a 16-second timer is activated that holds down the SNAT port. When the timer ends, the port is available for reuse. | 16 seconds |
+| TCP half open | During connection establishment where one connection endpoint is waiting for acknowledgment from the other endpoint, a 30-second timer is activated. If no traffic is detected, the connection will close. Once the connection has closed, the source port is available for reuse to the same destination endpoint. | 30 seconds |
+
+For UDP traffic, after a connection has closed, the port will be in hold down for 65 seconds before it's available for reuse.
+
+### Idle Timeout Timers
+
+| Timer | Description | Value |
+||||
+| TCP idle timeout | TCP connections can go idle when no data is transmitted between either endpoint for a prolonged period of time. A timer can be configured from 4 minutes (default) to 120 minutes (2 hours) to time out a connection that has gone idle. Traffic on the flow will reset the idle timeout timer. | Configurable; 4 minutes (default) - 120 minutes |
+| UDP idle timeout | UDP connections can go idle when no data is transmitted between either endpoint for a prolonged period of time. UDP idle timeout timers are 4 minutes and are **not configurable**. Traffic on the flow will reset the idle timeout timer. | **Not configurable**; 4 minutes |
+
+> [!NOTE]
+> These timer settings are subject to change. The values are provided to help with troubleshooting and you should not take a dependency on specific timers at this time.
+
+### Timer considerations
+
+Design recommendations for configuring timers:
+
+- In an idle connection scenario, NAT gateway holds onto SNAT ports until the connection idle times out. Because long idle timeout timers can unnecessarily increase the likelihood of SNAT port exhaustion, it isn't recommended to increase the TCP idle timeout duration to longer than the default time of 4 minutes. If a flow never goes idle, then it will not be impacted by the idle timer.
+
+- TCP keepalives can be used to provide a pattern of refreshing long idle connections and endpoint liveness detection. TCP keepalives appear as duplicate ACKs to the endpoints, are low overhead, and invisible to the application layer.
+
+- UDP idle timeout timers aren't configurable, UDP keepalives should be used to ensure that the idle timeout value isn't reached, and that the connection is maintained. Unlike TCP connections, a UDP keepalive enabled on one side of the connection only applies to traffic flow in one direction. UDP keepalives must be enabled on both sides of the traffic flow in order to keep the traffic flow alive.
+
+## Limitations
+
+- Basic load balancers and basic public IP addresses aren't compatible with NAT. Use standard SKU load balancers and public IPs instead.
+
+ - To upgrade a load balancer from basic to standard, see [Upgrade Azure Public Load Balancer](../load-balancer/upgrade-basic-standard.md)
+
+ - To upgrade a public IP address from basic to standard, see [Upgrade a public IP address](../virtual-network/ip-services/public-ip-upgrade-portal.md)
+
+- NAT gateway doesn't support ICMP
+
+- IP fragmentation isn't available for NAT gateway.
+
+## Next steps
+
+- Review [Azure NAT Gateway](nat-overview.md).
+
+- Learn about [metrics and alerts for NAT gateway](nat-metrics.md).
+
+- Learn how to [troubleshoot NAT gateway](troubleshoot-nat.md).
nat-gateway Nat Metrics https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/nat-metrics.md
+
+ Title: Metrics and alerts for Azure NAT Gateway
+
+description: Understand Azure Monitor metrics and alerts available for NAT gateway.
++
+# Customer intent: As an IT administrator, I want to understand available Azure Monitor metrics and alerts for Virtual Network NAT.
+ Last updated : 04/12/2022++
+# Azure NAT Gateway metrics and alerts
+
+This article provides an overview of all NAT gateway metrics and diagnostic capabilities. This article provides general guidance on how to use metrics and alerts to monitor, manage, and [troubleshoot](troubleshoot-nat.md) your NAT gateway resource.
+
+Azure NAT Gateway provides the following diagnostic capabilities:
+
+- Multi-dimensional metrics and alerts through Azure Monitor. You can use these metrics to monitor and manage your NAT gateway and to assist you in troubleshooting issues.
+
+- Network Insights: Azure Monitor Insights provides you with visual tools to view, monitor, and assist you in diagnosing issues with your NAT gateway resource. Insights provide you with a topological map of your Azure setup and metrics dashboards.
++
+*Figure: Azure NAT Gateway for outbound to Internet*
+
+## Metrics overview
+
+NAT gateway resources provide the following multi-dimensional metrics in Azure Monitor:
+
+| Metric | Description | Recommended aggregation | Dimensions |
+|||||
+| Bytes | Bytes processed inbound and outbound | Sum | Direction (In; Out), Protocol (6 TCP; 17 UDP) |
+| Packets | Packets processed inbound and outbound | Sum | Direction (In; Out), Protocol (6 TCP; 17 UDP) |
+| Dropped packets | Packets dropped by the NAT gateway | Sum | / |
+| SNAT Connection Count | Number of new SNAT connections over a given interval of time | Sum | Connection State (Attempted, Established, Failed, Closed, Timed Out), Protocol (6 TCP; 17 UDP) |
+| Total SNAT connection count | Total number of active SNAT connections | Sum | Protocol (6 TCP; 17 UDP) |
+| Data path availability (Preview) | Availability of the data path of the NAT gateway. Used to determine whether the NAT gateway endpoints are available for outbound traffic flow. | Avg | Availability (0, 100) |
+
+## Where to find my NAT gateway metrics
+
+NAT gateway metrics can be found in the following locations in the Azure portal.
+
+- **Metrics** page under **Monitoring** from a NAT gateway's resource page.
+
+- **Insights** page under **Monitoring** from a NAT gateway's resource page.
+
+ :::image type="content" source="./media/nat-metrics/nat-insights-metrics.png" alt-text="Screenshot of the insights and metrics options in NAT gateway overview.":::
+
+- Azure Monitor page under **Metrics**.
+
+ :::image type="content" source="./media/nat-metrics/azure-monitor.png" alt-text="Screenshot of the metrics section of Azure Monitor.":::
+
+To view any one of your metrics for a given NAT gateway resource:
+
+1. Select the NAT gateway resource you would like to monitor.
+
+2. In the **Metric** drop-down menu, select one of the provided metrics.
+
+3. In the **Aggregation** drop-down menu, select the recommended aggregation listed in the [metrics overview](#metrics-overview) table.
+
+ :::image type="content" source="./media/nat-metrics/nat-metrics-1.png" alt-text="Screenshot of the metrics setup configuration in NAT gateway resource.":::
+
+4. To adjust the time frame over which the chosen metric is presented on the metrics graph or to adjust how frequently the chosen metric is measured, select the **Time** window in the top right corner of the metrics page and make your adjustments.
+
+ :::image type="content" source="./media/nat-metrics/nat-metrics-2.png" alt-text="Screenshot of the metrics time setup configuration in NAT gateway resource.":::
+
+## How to use NAT gateway metrics
+
+### Bytes
+
+The **Bytes** metric shows you the amount of data going outbound through NAT gateway and returning inbound in response to an outbound connection.
+
+Use this metric for the following measurements:
+
+- Assess the amount of data being processed through NAT gateway to connect outbound or return inbound.
+
+To view the amount of data sent in one or both directions when connecting outbound through NAT gateway:
+
+1. Select the NAT gateway resource you would like to monitor.
+
+2. In the **Metric** drop-down menu, select the **Bytes** metric.
+
+3. In the **Aggregation** drop-down menu, select **Sum**.
+
+4. Select to **Add filter**.
+
+5. In the **Property** drop-down menu, select **Direction (Out | In)**.
+
+6. In the **Values** drop-down menu, select **Out**, **In**, or both.
+
+7. To see data processed inbound or outbound as their own individual lines in the metric graph, select **Apply splitting**.
+
+8. In the **Values** drop-down menu, select **Direction (Out | In)**.
+
+### Packets
+
+The packets metric shows you the number of data packets transmitted through the NAT gateway.
+
+Use this metric to:
+
+- To confirm that traffic is being sent through your NAT gateway to go outbound to the internet or return inbound.
+
+- To assess the amount of traffic being directed through your NAT gateway resource outbound or inbound (when in response to an outbound directed flow).
+
+To view the number of packets sent in one or both directions when connecting outbound through NAT gateway, follow the same steps in the [Bytes](#bytes) section.
+
+### Dropped packets
+
+The dropped packets metric shows you the number of data packets dropped by NAT gateway when directing traffic outbound or inbound in response to an outbound connection.
+
+Use this metric to:
+
+- Assess whether or not you're nearing or possibly experiencing SNAT exhaustion with a given NAT gateway resource. Check to see if periods of dropped packets coincide with periods of failed SNAT connections with the [SNAT Connection Count](#snat-connection-count) metric.
+
+- Help assess if you're experiencing a pattern of failed outbound connections.
+
+Reasons for why you may see dropped packets:
+
+- If you're seeing a high rate of dropped packets, it may be due to outbound connectivity failure. Connectivity failure may happen for various reasons. See the NAT gateway [troubleshooting guide](./troubleshoot-nat.md) to help you further diagnose.
+
+### SNAT connection count
+
+The SNAT connection count metric shows you the number of new SNAT connections within a specified time frame. This metric can be broken out to view different connection states including: attempted, established, failed, closed, and timed out connections. A failed connection volume greater than zero may indicate SNAT port exhaustion.
+
+Use this metric to:
+
+- Evaluate the health of your outbound connections.
+
+- Assess whether or not you're nearing or possibly experiencing SNAT port exhaustion.
+
+- Evaluate whether your NAT gateway resource should be scaled out further by adding more public IPs.
+
+- Assess if you're experiencing a pattern of failed outbound connections.
+
+To view the connection state of your connections:
+
+1. Select the NAT gateway resource you would like to monitor.
+
+2. In the **Metric** drop-down menu, select the **SNAT Connection Count** metric.
+
+3. In the **Aggregation** drop-down menu, select **Sum**.
+
+4. Select to **Add filter**.
+
+5. In the **Property** drop-down menu, select **Connection State**.
+
+6. In the **Values** drop-down menu, select **Attempted**, **Failed**, or both.
+
+7. To see attempted and failed connections as their own individual lines in the metric graph, select **Apply splitting**.
+
+8. In the **Values** drop-down menu, select **Connection State**.
+
+ :::image type="content" source="./media/nat-metrics/nat-metrics-3.png" alt-text="Screenshot of the metrics configuration.":::
+
+### Total SNAT connection count
+
+The **Total SNAT connection count** metric shows you the total number of active SNAT connections over a period of time.
+
+You can use this metric to:
+
+- Assess if you're nearing the connection limit of your NAT gateway resource.
+
+- Help assess if you're experiencing a pattern of failed outbound connections.
+
+Reasons for why you may see failed connections:
+
+- If you're seeing a pattern of failed connections for your NAT gateway resource, there could be multiple possible reasons. See the NAT gateway [troubleshooting guide](./troubleshoot-nat.md) to help you further diagnose.
+
+### Data path availability
+
+The data path availability metric measures the status of the NAT gateway resource over time. This metric informs on whether or not NAT gateway is available for directing outbound traffic to the internet. This metric is a reflection of the health of the Azure infrastructure.
+
+You can use this metric to:
+
+- Monitor the availability of your NAT gateway resource.
+
+- Investigate the platform where your NAT gateway is deployed and determine if itΓÇÖs healthy.
+
+- Isolate whether an event is related to your NAT gateway or to the underlying data plane.
+
+Reasons for why you may see a drop in data path availability include:
+
+- An infrastructure outage has occurred.
+
+- There aren't healthy VMs available in your NAT gateway configured subnet. For more information, see the NAT gateway [troubleshooting guide](./troubleshoot-nat.md).
+
+## Alerts
+
+Alerts can be configured in Azure Monitor for each of the preceding metrics. These alerts proactively notify you when important conditions are found in your monitoring data. They allow you to identify and address potential issues with your NAT gateway resource.
+
+For more information about how metric alerts work, see [Azure Monitor Metric Alerts](../azure-monitor/alerts/alerts-metric-overview.md). See guidance below on how to configure some common and recommended types of alerts for your NAT gateway.
+
+### Alerts for data path availability droppage
+
+If the datapath of your NAT gateway resource begins to experience drops in availability, you can set up an alert to be fired when it hits a specific threshold in availability.
+
+The recommended guidance is to alert on NAT gatewayΓÇÖs datapath availability when it drops below 90% over a 15 minute period. This configuration will be indicative of a NAT gateway resource going into a degraded state.
+
+To set up a datapath availability alert, follow these steps:
+
+1. From the NAT gateway resource page, select **Alerts**.
+
+2. Select **Create alert rule**.
+
+3. From the signal list, select **Datapath Availability**.
+
+4. From the **Operator** drop-down menu, select **Less than**.
+
+5. From the **Aggregation type** drop-down menu, select **Average**.
+
+6. In the **Threshold value** box, enter **90%** as the value that the datapath availability must drop below before an alert is fired.
+
+7. From the **Unit** drop-down menu, select **Count**.
+
+8. From the **Aggregation granularity (Period)** drop-down menu, select **15 minutes**.
+
+9. Create an **Action** for your alert by providing a name, notification type, and type of action that is performed when the alert is triggered.
+
+10. Before deploying your action, **test the action group**.
+
+11. Select **Create** to create the alert rule.
+
+>[!NOTE]
+>Aggregation granularity is the period of time over which the datapath availability is measured to determine if it has dropped below the threshold value.
+Setting the aggregation granularity to less than 5 minutes may trigger false positive alerts that detect noise in the datapath.
+
+### Alerts for SNAT port exhaustion
+
+Use the **SNAT connection count** metric and alerts to help determine if you're experiencing SNAT port exhaustion. A failed connection volume greater than zero may indicate SNAT port exhaustion. You may need to investigate further to determine the root cause of these failures.
+
+To create the alert, use the following steps:
+
+1. From the NAT gateway resource page, select **Alerts**.
+
+2. Select **Create alert rule**.
+
+3. From the signal list, select **SNAT Connection Count**.
+
+4. From the **Aggregation type** drop-down menu, select **Total**.
+
+5. From the **Operator** drop-down menu, select **Greater than**.
+
+6. From the **Unit** drop-down menu, select **Count**.
+
+7. In the **Threshold value** box, enter 0.
+
+8. In the Split by dimensions section, select **Connection State** under Dimension name.
+
+9. Under Dimension values, select **Failed** connections.
+
+8. From the When to evaluate section, select **1 minute** under the **Check every** drop-down menu.
+
+9. For the lookback period, select **5 minutes** from the drop-down menu options.
+
+9. Create an **Action** for your alert by providing a name, notification type, and type of action that is performed when the alert is triggered.
+
+10. Before deploying your action, **test the action group**.
+
+11. Select **Create** to create the alert rule.
+
+>[!NOTE]
+>SNAT port exhaustion on your NAT gateway resource is uncommon. If you see SNAT port exhaustion, your NAT gateway's idle timeout timer may be holding on to SNAT ports too long or your may need to scale with additional public IPs. To troubleshoot these kinds of issues, refer to the [NAT gateway connectivity troubleshooting guide](./troubleshoot-nat-connectivity.md#snat-exhaustion-due-to-nat-gateway-configuration).
+
+## Network Insights
+
+[Azure Monitor Network Insights](../network-watcher/network-insights-overview.md) allows you to visualize your Azure infrastructure setup and to review all metrics for your NAT gateway resource from a pre-configured metrics dashboard. These visual tools help you diagnose and troubleshoot any issues with your NAT gateway resource.
+
+### View the topology of your Azure architectural setup
+
+To view a topological map of your setup in Azure:
+
+1. From your NAT gatewayΓÇÖs resource page, select **Insights** from the **Monitoring** section.
+
+2. On the landing page for **Insights**, you'll see a topology map of your NAT gateway setup. This map will show you the relationship between the different components of your network (subnets, virtual machines, public IP addresses).
+
+3. Hover over any component in the topology map to view configuration information.
+
+ :::image type="content" source="./media/nat-metrics/nat-insights.png" alt-text="Screenshot of the Insights section of NAT gateway.":::
+
+### View all NAT gateway metrics in a dashboard
+
+The metrics dashboard can be used to better understand the performance and health of your NAT gateway resource. The metrics dashboard shows a view of all metrics for NAT gateway on a single page.
+
+- All NAT gateway metrics can be viewed in a dashboard when selecting **Show Metrics Pane**.
+
+ :::image type="content" source="./media/nat-metrics/nat-metrics-pane.png" alt-text="Screenshot of the show metrics pane.":::
+
+- A full page view of all NAT gateway metrics can be viewed when selecting **View Detailed Metrics**.
+
+ :::image type="content" source="./media/nat-metrics/detailed-metrics.png" alt-text="Screenshot of the view detailed metrics.":::
+
+For more information on what each metric is showing you and how to analyze these metrics, see [How to use NAT gateway metrics](#how-to-use-nat-gateway-metrics).
+
+## Next steps
+
+* Learn about [Azure NAT Gateway](nat-overview.md)
+* Learn about [NAT gateway resource](nat-gateway-resource.md)
+* Learn about [Azure Monitor](../azure-monitor/overview.md)
+* Learn about [troubleshooting NAT gateway resources](troubleshoot-nat.md).
nat-gateway Nat Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/nat-overview.md
++
+ Title: What is Azure NAT Gateway?
+
+description: Overview of Azure NAT Gateway features, resources, architecture, and implementation. Learn how Azure NAT Gateway works and how to use NAT gateway resources in Azure.
++++ Last updated : 12/06/2022++++
+# What is Azure NAT Gateway?
+
+Azure NAT Gateway is a fully managed and highly resilient Network Address Translation (NAT) service. Azure NAT Gateway simplifies outbound Internet connectivity for virtual networks. When configured on a subnet, all outbound connectivity uses the NAT gateway's static public IP addresses.
++
+*Figure: Azure NAT Gateway*
+
+## Azure NAT Gateway benefits
+
+### Security
+
+With a NAT gateway, individual VMs or other compute resources, don't need public IP addresses and can remain private. Resources without a public IP address can still reach external sources outside the virtual network with NAT gateway's static public IP addresses or prefixes. You can associate a public IP prefix to ensure that a contiguous set of IPs will be used for outbound. Destination firewall rules can be configured based on this predictable IP list.
+
+### Resiliency
+
+Azure NAT Gateway is a fully managed and distributed service. It doesn't depend on individual compute instances such as VMs or a single physical gateway device. A NAT gateway always has multiple fault domains and can sustain multiple failures without service outage. Software defined networking makes a NAT gateway highly resilient.
+
+### Scalability
+
+NAT gateway is scaled out from creation. There isn't a ramp up or scale-out operation required. Azure manages the operation of NAT gateway for you.
+
+A NAT gateway resource can be associated to a subnet and can be used by all compute resources in that subnet. All subnets in a virtual network can use the same NAT gateway resource. Outbound connectivity can be scaled out by assigning up to 16 IP addresses to NAT gateway. When a NAT gateway is associated to a public IP prefix, it automatically scales to the number of IP addresses needed for outbound.
+
+### Performance
+
+Azure NAT Gateway is a software defined networking service. A NAT gateway won't affect the network bandwidth of your compute resources. Learn more about [NAT gateway's performance](nat-gateway-resource.md#performance).
+
+## Azure NAT Gateway basics
+
+### Outbound connectivity
+
+* NAT gateway is the recommended method for outbound connectivity. NAT gateway doesn't have the same limitations of SNAT port exhaustion as does [default outbound access](../virtual-network/ip-services/default-outbound-access.md) and [outbound rules of a load balancer](../load-balancer/outbound-rules.md).
+
+* NAT gateway allows flows to be created from the virtual network to the services outside your virtual network. Return traffic from the internet is only allowed in response to an active flow. Services outside your virtual network canΓÇÖt initiate an inbound connection through NAT gateway.
+
+ * To migrate outbound access to a NAT gateway from default outbound access or load balancer outbound rules, see [Migrate outbound access to Azure NAT Gateway](./tutorial-migrate-outbound-nat.md).
+
+* NAT gateway takes precedence over other outbound scenarios (including Load balancer and instance-level public IP addresses) and replaces the default Internet destination of a subnet.
+
+* When NAT gateway is configured to a virtual network where standard Load balancer with outbound rules already exists, NAT gateway will take over all outbound traffic moving forward. There will be no drops in traffic flow for existing connections on Load balancer. All new connections will use NAT gateway.
+
+* Presence of custom UDRs for virtual appliances and ExpressRoute override NAT gateway for directing internet bound traffic (route to the 0.0.0.0/0 address prefix).
+
+* The order of operations for outbound connectivity follows this order of precedence:
+Virtual appliance UDR / ExpressRoute >> NAT gateway >> Instance-level public IP addresses on virtual machines >> Load balancer outbound rules >> default system
+
+* NAT gateway supports TCP and UDP protocols only. ICMP isn't supported.
+
+* NAT gateway will send a TCP Rest (RST) packet to the connection endpoint that attempts to communicate on a connection flow that does not exist. This connection flow may no longer exist if the NAT gateway idle timeout was reached or the connection was closed earlier. When the NAT gateway TCP RST packet is received by the connection endpoint, this signifies that the connection is no longer usable.
+
+### NAT gateway configurations
+
+* Outbound connectivity can be defined for each subnet with a NAT gateway. All outbound traffic for the subnet is processed by the NAT gateway without any customer configuration.
+
+* A NAT gateway canΓÇÖt span multiple virtual networks.
+
+* Multiple subnets within the same virtual network can either use different NAT gateways or the same NAT gateway.
+
+* Multiple NAT gateways canΓÇÖt be attached to a single subnet.
+
+* A NAT gateway canΓÇÖt be deployed in a [gateway subnet](../vpn-gateway/vpn-gateway-about-vpn-gateway-settings.md#gwsub).
+
+* A NAT gateway resource can use up to 16 IP addresses in any combination of:
+
+ * Public IP addresses
+
+ * Public IP prefixes
+
+ * Public IP addresses and prefixes derived from custom IP prefixes (BYOIP), to learn more, see [Custom IP address prefix (BYOIP)](../virtual-network/ip-services/custom-ip-address-prefix.md).
+
+* NAT gateway canΓÇÖt be associated to an IPv6 public IP address or IPv6 public IP prefix. It can be associated to a dual stack subnet, but will only be able to direct outbound traffic with an IPv4 address. To set up a dual stack outbound configuration, see [dual stack outbound connectivity with NAT gateway and Load balancer](/azure/virtual-network/nat-gateway/tutorial-dual-stack-outbound-nat-load-balancer?tabs=dual-stack-outbound-portal).
+
+* NAT gateway can be associated to an Azure Firewall subnet in a hub virtual network and provide outbound connectivity from spoke virtual networks peered to the hub. To learn more, see [Azure Firewall integration with NAT gateway](../firewall/integrate-with-nat-gateway.md).
+
+### Availability zones
+
+* A NAT gateway can be created in a specific availability zone or placed in 'no zone'.
+
+* NAT gateway can be isolated in a specific zone when you create [zone isolation scenarios](./nat-availability-zones.md). This deployment is called a zonal deployment. After NAT gateway is deployed, the zone selection can't be changed.
+
+* NAT gateway is placed in 'no zone' by default. A [non-zonal NAT gateway](./nat-availability-zones.md#non-zonal) is placed in a zone for you by Azure.
+
+### NAT gateway and basic SKU resources
+
+* NAT gateway is compatible with standard SKU public IP addresses or public IP prefix resources or a combination of both. You can use a public IP prefix directly or distribute the public IP addresses of the prefix across multiple NAT gateway resources. The NAT gateway will groom all traffic to the range of IP addresses of the prefix.
+
+* Basic resources, such as basic load balancer or basic public IPs aren't compatible with NAT gateway. Basic resources must be placed on a subnet not associated to a NAT gateway. Basic load balancer and basic public IP can be upgraded to standard to work with a NAT gateway
+
+ * Upgrade a load balancer from basic to standard, see [Upgrade a public basic Azure Load Balancer](../load-balancer/upgrade-basic-standard.md).
+
+ * Upgrade a public IP from basic to standard, see [Upgrade a public IP address](../virtual-network/ip-services/public-ip-upgrade-portal.md).
+
+### NAT gateway timers
+
+* NAT gateway holds on to SNAT ports after a connection closes before it's available to reuse to connect to the same destination endpoint over the internet. SNAT port reuse timer durations for TCP traffic vary depending on how the connection closes. To learn more, see [Port Reuse Timers](./nat-gateway-resource.md#port-reuse-timers).
+
+* A default TCP idle timeout of 4 minutes is used and can be increased to up to 120 minutes. Any activity on a flow can also reset the idle timer, including TCP keepalives. To learn more, see [Idle Timeout Timers](./nat-gateway-resource.md#idle-timeout-timers).
+
+* UDP traffic has an idle timeout timer of 4 minutes that can't be changed.
+
+* UDP traffic has a port reset timer of 65 seconds for which a port is in hold down before it's available for reuse to the same destination endpoint.
+
+## Pricing and SLA
+
+For Azure NAT Gateway pricing, see [NAT gateway pricing](https://azure.microsoft.com/pricing/details/virtual-network/#pricing).
+
+For information on the SLA, see [SLA for Azure NAT Gateway](https://azure.microsoft.com/support/legal/sla/virtual-network-nat/v1_0/).
+
+## Next steps
+
+* To create and validate a NAT gateway, see [Quickstart: Create a NAT gateway using the Azure portal](quickstart-create-nat-gateway-portal.md).
+
+* To view a video on more information about Azure NAT Gateway, see [How to get better outbound connectivity using an Azure NAT gateway](https://www.youtube.com/watch?v=2Ng_uM0ZaB4).
+
+* Learn about the [NAT gateway resource](./nat-gateway-resource.md).
+
+* [Learn module: Introduction to Azure NAT Gateway](/training/modules/intro-to-azure-virtual-network-nat).
+
+* To learn more about architecture options for Azure NAT Gateway, see [Azure Well-Architected Framework review of an Azure NAT gateway](/azure/architecture/networking/guide/well-architected-network-address-translation-gateway).
nat-gateway Quickstart Create Nat Gateway Bicep https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/quickstart-create-nat-gateway-bicep.md
+
+ Title: 'Create a NAT gateway - Bicep'
+
+description: This quickstart shows how to create a NAT gateway using Bicep.
++++ Last updated : 04/24/2023++
+# Customer intent: I want to create a NAT gateway using Bicep so that I can provide outbound connectivity for my virtual machines.
++
+# Quickstart: Create a NAT gateway - Bicep
+
+Get started with Azure NAT Gateway using Bicep. This Bicep file deploys a virtual network, a NAT gateway resource, and Ubuntu virtual machine. The Ubuntu virtual machine is deployed to a subnet that is associated with the NAT gateway resource.
++
+## Prerequisites
+
+If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
+
+## Review the Bicep file
+
+The Bicep file used in this quickstart is from [Azure Quickstart Templates](https://azure.microsoft.com/resources/templates/nat-gateway-1-vm/).
+
+This Bicep file is configured to create a:
+
+* Virtual network
+
+* NAT gateway resource
+
+* Ubuntu virtual machine
+
+The Ubuntu VM is deployed to a subnet that's associated with the NAT gateway resource.
++
+Nine Azure resources are defined in the Bicep file:
+
+* **[Microsoft.Network/networkSecurityGroups](/azure/templates/microsoft.network/networksecuritygroups)**: Creates a network security group.
+
+* **[Microsoft.Network/networkSecurityGroups/securityRules](/azure/templates/microsoft.network/networksecuritygroups/securityrules)**: Creates a security rule.
+
+* **[Microsoft.Network/publicIPAddresses](/azure/templates/microsoft.network/publicipaddresses)**: Creates a public IP address.
+
+* **[Microsoft.Network/publicIPPrefixes](/azure/templates/microsoft.network/publicipprefixes)**: Creates a public IP prefix.
+
+* **[Microsoft.Compute/virtualMachines](/azure/templates/Microsoft.Compute/virtualMachines)**: Creates a virtual machine.
+
+* **[Microsoft.Network/virtualNetworks](/azure/templates/microsoft.network/virtualnetworks)**: Creates a virtual network.
+
+* **[Microsoft.Network/natGateways](/azure/templates/microsoft.network/natgateways)**: Creates a NAT gateway resource.
+
+* **[Microsoft.Network/virtualNetworks/subnets](/azure/templates/microsoft.network/virtualnetworks/subnets)**: Creates a virtual network subnet.
+
+* **[Microsoft.Network/networkinterfaces](/azure/templates/microsoft.network/networkinterfaces)**: Creates a network interface.
+
+## Deploy the Bicep file
+
+1. Save the Bicep file as **main.bicep** to your local computer.
+
+1. Deploy the Bicep file using either Azure CLI or Azure PowerShell.
+
+ # [CLI](#tab/CLI)
+
+ ```azurecli
+ az group create --name exampleRG --location eastus
+ az deployment group create --resource-group exampleRG --template-file main.bicep --parameters adminusername=<admin-name>
+ ```
+
+ # [PowerShell](#tab/PowerShell)
+
+ ```azurepowershell
+ New-AzResourceGroup -Name exampleRG -Location eastus
+ New-AzResourceGroupDeployment -ResourceGroupName exampleRG -TemplateFile ./main.bicep -adminusername "<admin-name>"
+ ```
+
+
+
+ > [!NOTE]
+ > Replace **\<admin-name\>** with the administrator username for the virtual machine. You'll also be prompted to enter **adminpassword**.
+
+ When the deployment finishes, you should see a message indicating the deployment succeeded.
+
+## Review deployed resources
+
+Use the Azure portal, Azure CLI, or Azure PowerShell to list the deployed resources in the resource group.
+
+# [CLI](#tab/CLI)
+
+```azurecli-interactive
+az resource list --resource-group exampleRG
+```
+
+# [PowerShell](#tab/PowerShell)
+
+```azurepowershell-interactive
+Get-AzResource -ResourceGroupName exampleRG
+```
+++
+## Clean up resources
+
+When no longer needed, use the Azure portal, Azure CLI, or Azure PowerShell to delete the resource group and its resources.
+
+# [CLI](#tab/CLI)
+
+```azurecli-interactive
+az group delete --name exampleRG
+```
+
+# [PowerShell](#tab/PowerShell)
+
+```azurepowershell-interactive
+Remove-AzResourceGroup -Name exampleRG
+```
+++
+## Next steps
+
+In this quickstart, you created a:
+
+* NAT gateway resource
+
+* Virtual network
+
+* Ubuntu virtual machine
+
+The virtual machine is deployed to a virtual network subnet associated with the NAT gateway.
+
+To learn more about Azure NAT Gateway and Bicep, continue to the following articles.
+
+* Read an [Overview of Azure NAT Gateway](nat-overview.md)
+
+* Read about the [NAT Gateway resource](nat-gateway-resource.md)
+
+* Learn more about [Bicep](../azure-resource-manager/bicep/overview.md)
nat-gateway Quickstart Create Nat Gateway Cli https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/quickstart-create-nat-gateway-cli.md
+
+ Title: 'Quickstart: Create a NAT gateway - Azure CLI'
+
+description: Get started creating a NAT gateway using the Azure CLI.
++++ Last updated : 02/04/2022+++
+# Quickstart: Create a NAT gateway using the Azure CLI
+
+This quickstart shows you how to use the Azure NAT Gateway service. You'll create a NAT gateway to provide outbound connectivity for a virtual machine in Azure.
++++
+## Set parameter values to create resources
+
+Set the parameter values for use in creating the required resources. The $RANDOM function is used to create unique object names.
++
+## Create a resource group
+
+Create a resource group with [az group create](/cli/azure/group#az-group-create). An Azure resource group is a logical container into which Azure resources are deployed and managed.
++
+## Create the NAT gateway
+
+In this section we create the NAT gateway and supporting resources.
+
+### Create public IP address
+
+To access the Internet, you need one or more public IP addresses for the NAT gateway. Use [az network public-ip create](/cli/azure/network/public-ip#az-network-public-ip-create) to create a public IP address resource.
++
+### Create NAT gateway resource
+
+Create a global Azure NAT gateway with [az network nat gateway create](/cli/azure/network/nat#az-network-nat-gateway-create). The result of this command will create a gateway resource that uses the public IP address defined in the previous step. The idle timeout is set to 10 minutes.
++
+### Create virtual network
+
+Create a virtual network with a subnet with [az network vnet create](/cli/azure/network/vnet#az-network-vnet-create). The IP address space for the virtual network is **10.1.0.0/16**. The subnet within the virtual network is **10.1.0.0/24**.
++
+### Create bastion host subnet
+
+Create an Azure Bastion host to access the virtual machine.
+
+Use [az network vnet subnet create](/cli/azure/network/vnet/subnet#az-network-vnet-subnet-create) to create an Azure Bastion subnet.
++
+### Create public IP address for the bastion host
+
+Create a public IP address for the bastion host with [az network public-ip create](/cli/azure/network/public-ip#az-network-public-ip-create).
++
+### Create the bastion host
+
+Use [az network bastion create](/cli/azure/network/bastion#az-network-bastion-create) to create the bastion host.
++
+### Configure NAT service for source subnet
+
+Configure the source subnet in virtual network to use a specific NAT gateway resource with [az network vnet subnet update](/cli/azure/network/vnet/subnet#az-network-vnet-subnet-update). This command will activate the NAT service on the specified subnet.
++
+All outbound traffic to Internet destinations is now using the NAT gateway. It's not necessary to configure a UDR.
+
+## Create virtual machine
+
+Create a virtual machine to test the NAT gateway to verify the public IP address of the outbound connection.
+
+Create the virtual machine with [az vm create](/cli/azure/vm#az-vm-create).
++
+Wait for the virtual machine creation to complete before moving on to the next section.
+
+## Test NAT gateway
+
+In this section, we'll test the NAT gateway. We'll first discover the public IP of the NAT gateway. We'll then connect to the test virtual machine and verify the outbound connection through the NAT gateway.
+
+1. Sign in to the [Azure portal](https://portal.azure.com)
+
+1. Find the public IP address for the NAT gateway on the **Overview** screen. Select **All services** in the left-hand menu, select **All resources**, and then select **myPublicIP**.
+
+1. Make note of the public IP address:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/find-public-ip.png" alt-text="Discover public IP address of NAT gateway" border="true":::
+
+1. Select **All services** in the left-hand menu, select **All resources**, and then from the resources list, select **myVM** that is located in the **myResourceGroupNAT** resource group.
+
+1. On the **Overview** page, select **Connect**, then **Bastion**.
+
+1. Select the blue **Use Bastion** button.
+
+1. Enter the username and password entered during VM creation.
+
+1. Open **Internet Explorer** on **myTestVM**.
+
+1. Enter **https://whatsmyip.com** in the address bar.
+
+1. Verify the IP address displayed matches the NAT gateway address you noted in the previous step:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/my-ip.png" alt-text="Internet Explorer showing external outbound IP" border="true":::
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete
+the virtual network, virtual machine, and NAT gateway with the following CLI command:
+
+```azurecli-interactive
+ az group delete \
+ --name $resourceGroup
+```
+
+## Next steps
+
+For more information on Azure NAT Gateway, see:
+> [!div class="nextstepaction"]
+> [Virtual Network NAT overview](nat-overview.md)
nat-gateway Quickstart Create Nat Gateway Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/quickstart-create-nat-gateway-portal.md
+
+ Title: 'Quickstart: Create a NAT gateway - Azure portal'
+
+description: This quickstart shows how to create a NAT gateway by using the Azure portal.
++++ Last updated : 02/09/2023+++
+# Quickstart: Create a NAT gateway using the Azure portal
+
+This quickstart shows you how to use the Azure NAT Gateway service. You'll create a NAT gateway to provide outbound connectivity for a virtual machine in Azure.
+
+## Prerequisites
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+## Create a NAT gateway
+
+Before you deploy the NAT gateway resource and the other resources, a resource group is required to contain the resources deployed. In the following steps, you'll create a resource group, NAT gateway resource, and a public IP address. You can use one or more public IP address resources, public IP prefixes, or both.
+
+For information about public IP prefixes and a NAT gateway, see [Manage NAT gateway](./manage-nat-gateway.md?tabs=manage-nat-portal#add-or-remove-a-public-ip-prefix).
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways** in the search results.
+
+1. Select **+ Create**.
+
+1. In **Create network address translation (NAT) gateway**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription. |
+ | Resource Group | Select **Create new**. </br> Enter **myResourceGroupNAT**. </br> Select **OK**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway** |
+ | Region | Select **West Europe** |
+ | Availability Zone | Select **No Zone**. |
+ | TCP idle timeout (minutes) | Enter **10**. |
+
+ For information about availability zones and NAT gateway, see [NAT gateway and availability zones](./nat-availability-zones.md).
+
+1. Select the **Outbound IP** tab, or select the **Next: Outbound IP** button at the bottom of the page.
+
+1. In the **Outbound IP** tab, enter or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | Public IP addresses | Select **Create a new public IP address**. </br> In **Name**, enter **myPublicIP**. </br> Select **OK**. |
+
+1. Select the **Review + create** tab, or select the blue **Review + create** button at the bottom of the page.
+
+1. Select **Create**.
+
+## Virtual network
+
+Before you deploy a virtual machine and can use your NAT gateway, you need to create the virtual network. This virtual network will contain the virtual machine created in later steps.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+1. Select **+ Create**.
+
+1. In **Create virtual network**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription |
+ | Resource Group | Select **myResourceGroupNAT**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet** |
+ | Region | Select **(Europe) West Europe** |
+
+1. Select the **Security** tab or select the **Next: Security** button at the bottom of the page.
+
+1. Under **Azure Bastion**, select **Enable Azure Bastion**. Enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Azure Bastion name | Enter **myBastionHost** |
+ | Azure Bastion public IP address | Select **New(myVNet-publicipAddress1)** |
+
+1. Select the **IP Addresses** tab or select the **Next: IP Addresses** button at the bottom of the page.
+
+1. Accept the default IPv4 address space of **10.0.0.0/16**.
+
+1. In the subnet section in **Subnet name**, select the **default** subnet, then select **Save**.
+
+1. In **Edit subnet**, enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Name| Enter **mySubnet** |
+ | Starting address | Enter **10.0.0.0** |
+ | Subnet size | Select **/24** |
+ | **Security** |
+ | NAT gateway | Select **myNATgateway**. |
+
+1. Select **Add a subnet** and enter the following information, then select **Add**.
+
+ | Setting | Value |
+ |--|-|
+ | Subnet template | Select **Azure Bastion** |
+ | Starting address | Enter **10.0.1.0** |
+ | Subnet size | Select **/26** |
+
+1. Select the **Review + create** tab or select the **Review + create** button.
+
+1. Select **Create**.
+
+It can take a few minutes for the deployment of the virtual network to complete. Proceed to the next steps when the deployment completes.
+
+## Virtual machine
+
+In this section, you'll create a virtual machine to test the NAT gateway and verify the public IP address of the outbound connection.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+1. Select **+ Create** > **Azure virtual machine**.
+
+1. In the **Create a virtual machine** page in the **Basics** tab, enter, or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **myResourceGroupNAT**. |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM**. |
+ | Region | Select **(Europe) West Europe**. |
+ | Availability options | Select **No infrastructure redundancy required**. |
+ | Security type | Select **Standard**. |
+ | Image | Select **Windows Server 2022 Datacenter: Azure Edition - Gen2**. |
+ | Size | Select a size. |
+ | **Administrator account** | |
+ | Username | Enter a username for the virtual machine. |
+ | Password | Enter a password. |
+ | Confirm password | Confirm password. |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None**. |
+
+1. Select the **Disks** tab, or select the **Next: Disks** button at the bottom of the page.
+
+1. Leave the default in the **Disks** tab.
+
+1. Select the **Networking** tab, or select the **Next: Networking** button at the bottom of the page.
+
+1. In the **Networking** tab, enter or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | **Network interface** | |
+ | Virtual network | Select **myVNet**. |
+ | Subnet | Select **mySubnet (10.1.0.0/24)**. |
+ | Public IP | Select **None**. |
+ | NIC network security group | Select **Basic**. |
+ | Public inbound ports | Select **None**. |
+
+1. Select the **Review + create** tab, or select the blue **Review + create** button at the bottom of the page.
+
+1. Select **Create**.
+
+## Test NAT gateway
+
+In this section, you'll test the NAT gateway. You'll first discover the public IP of the NAT gateway. You'll then connect to the test virtual machine and verify the outbound connection through the NAT gateway.
+
+1. In the search box at the top of the portal, enter **Public IP**. Select **Public IP addresses** in the search results.
+
+1. Select **myPublicIP**.
+
+1. Make note of the public IP address:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/find-public-ip.png" alt-text="Discover public IP address of NAT gateway" border="true":::
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+1. Select **myVM**.
+
+1. On the **Overview** page, select **Connect**, then **Bastion**.
+
+1. Enter the username and password entered during VM creation. Select **Connect**.
+
+1. Open **Microsoft Edge** on **myTestVM**.
+
+1. Enter **https://whatsmyip.com** in the address bar.
+
+1. Verify the IP address displayed matches the NAT gateway address you noted in the previous step:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/my-ip.png" alt-text="Internet Explorer showing external outbound IP" border="true":::
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete
+the virtual network, virtual machine, and NAT gateway with the following steps:
+
+1. From the left-hand menu, select **Resource groups**.
+
+1. Select the **myResourceGroupNAT** resource group.
+
+1. Select **Delete resource group**.
+
+1. Enter **myResourceGroupNAT** and select **Delete**.
+
+## Next steps
+
+For more information on Azure NAT Gateway, see:
+> [!div class="nextstepaction"]
+> [Azure NAT Gateway overview](nat-overview.md)
nat-gateway Quickstart Create Nat Gateway Powershell https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/quickstart-create-nat-gateway-powershell.md
+
+ Title: 'Quickstart: Create a NAT gateway - PowerShell'
+
+description: Get started creating a NAT gateway using Azure PowerShell.
++++ Last updated : 03/09/2021+++
+# Quickstart: Create a NAT gateway using Azure PowerShell
+
+This quickstart shows you how to use the Azure NAT Gateway service. You'll create a NAT gateway to provide outbound connectivity for a virtual machine in Azure.
+
+## Prerequisites
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+- Azure PowerShell installed locally or Azure Cloud Shell
+
+If you choose to install and use PowerShell locally, this article requires the Azure PowerShell module version 5.4.1 or later. Run `Get-Module -ListAvailable Az` to find the installed version. If you need to upgrade, see [Install Azure PowerShell module](/powershell/azure/install-Az-ps). If you're running PowerShell locally, you also need to run `Connect-AzAccount` to create a connection with Azure.
+
+## Create a resource group
+
+Create a resource group with [New-AzResourceGroup](/powershell/module/az.resources/new-azresourcegroup). An Azure resource group is a logical container into which Azure resources are deployed and managed.
+
+The following example creates a resource group named **myResourceGroupNAT** in the **eastus2** location:
+
+```azurepowershell-interactive
+$rsg = @{
+ Name = 'myResourceGroupNAT'
+ Location = 'eastus2'
+}
+New-AzResourceGroup @rsg
+```
+## Create the NAT gateway
+
+In this section we create the NAT gateway and supporting resources.
+
+* To access the Internet, you need one or more public IP addresses for the NAT gateway. Use [New-AzPublicIpAddress](/powershell/module/az.network/new-azpublicipaddress) to create a public IP address resource named **myPublicIP** in **myResourceGroupNAT**.
+
+* Create a global Azure NAT gateway with [New-AzNatGateway](/powershell/module/az.network/new-aznatgateway). The result of this command will create a gateway resource named **myNATgateway** that uses the public IP address **myPublicIP**. The idle timeout is set to 10 minutes.
+
+* Create a virtual network named **myVnet** with a subnet named **mySubnet** using [New-AzVirtualNetworkSubnetConfig](/powershell/module/az.network/new-azvirtualnetworksubnetconfig) in the **myResourceGroup** using [New-AzVirtualNetwork](/powershell/module/az.network/new-azvirtualnetwork). The IP address space for the virtual network is **10.1.0.0/16**. The subnet within the virtual network is **10.1.0.0/24**.
+
+* Create an Azure Bastion host named **myBastionHost** to access the virtual machine. Use [New-AzBastion](/powershell/module/az.network/new-azbastion) to create the bastion host. Create a public IP address for the bastion host with [New-AzPublicIpAddress](/powershell/module/az.network/new-azpublicipaddress).
+
+```azurepowershell-interactive
+## Create public IP address for NAT gateway ##
+$ip = @{
+ Name = 'myPublicIP'
+ ResourceGroupName = 'myResourceGroupNAT'
+ Location = 'eastus2'
+ Sku = 'Standard'
+ AllocationMethod = 'Static'
+}
+$publicIP = New-AzPublicIpAddress @ip
+
+## Create NAT gateway resource ##
+$nat = @{
+ ResourceGroupName = 'myResourceGroupNAT'
+ Name = 'myNATgateway'
+ IdleTimeoutInMinutes = '10'
+ Sku = 'Standard'
+ Location = 'eastus2'
+ PublicIpAddress = $publicIP
+}
+$natGateway = New-AzNatGateway @nat
+
+## Create subnet config and associate NAT gateway to subnet##
+$subnet = @{
+ Name = 'mySubnet'
+ AddressPrefix = '10.1.0.0/24'
+ NatGateway = $natGateway
+}
+$subnetConfig = New-AzVirtualNetworkSubnetConfig @subnet
+
+## Create Azure Bastion subnet. ##
+$bastsubnet = @{
+ Name = 'AzureBastionSubnet'
+ AddressPrefix = '10.1.1.0/24'
+}
+$bastsubnetConfig = New-AzVirtualNetworkSubnetConfig @bastsubnet
+
+## Create the virtual network ##
+$net = @{
+ Name = 'myVNet'
+ ResourceGroupName = 'myResourceGroupNAT'
+ Location = 'eastus2'
+ AddressPrefix = '10.1.0.0/16'
+ Subnet = $subnetConfig,$bastsubnetConfig
+}
+$vnet = New-AzVirtualNetwork @net
+
+## Create public IP address for bastion host. ##
+$ip = @{
+ Name = 'myBastionIP'
+ ResourceGroupName = 'myResourceGroupNAT'
+ Location = 'eastus2'
+ Sku = 'Standard'
+ AllocationMethod = 'Static'
+}
+$publicip = New-AzPublicIpAddress @ip
+
+## Create bastion host ##
+$bastion = @{
+ ResourceGroupName = 'myResourceGroupNAT'
+ Name = 'myBastion'
+ PublicIpAddress = $publicip
+ VirtualNetwork = $vnet
+}
+New-AzBastion @bastion -AsJob
+
+```
+
+## Virtual machine
+
+In this section, you'll create a virtual machine to test the NAT gateway and verify the public IP address of the outbound connection.
+
+* Create a network interface with [New-AzNetworkInterface](/powershell/module/az.network/new-aznetworkinterface).
+
+* Set an administrator username and password for the VM with [Get-Credential](/powershell/module/microsoft.powershell.security/get-credential).
+
+* Create the virtual machine with:
+ * [New-AzVM](/powershell/module/az.compute/new-azvm)
+ * [New-AzVMConfig](/powershell/module/az.compute/new-azvmconfig)
+ * [Set-AzVMOperatingSystem](/powershell/module/az.compute/set-azvmoperatingsystem)
+ * [Set-AzVMSourceImage](/powershell/module/az.compute/set-azvmsourceimage)
+ * [Add-AzVMNetworkInterface](/powershell/module/az.compute/add-azvmnetworkinterface)
+
+```azurepowershell-interactive
+# Set the administrator and password for the VMs. ##
+$cred = Get-Credential
+
+## Place the virtual network into a variable. ##
+$vnet = Get-AzVirtualNetwork -Name 'myVNet' -ResourceGroupName 'myResourceGroupNAT'
+
+## Create network interface for virtual machine. ##
+$nic = @{
+ Name = "myNicVM"
+ ResourceGroupName = 'myResourceGroupNAT'
+ Location = 'eastus2'
+ Subnet = $vnet.Subnets[0]
+}
+$nicVM = New-AzNetworkInterface @nic
+
+## Create a virtual machine configuration for VMs ##
+$vmsz = @{
+ VMName = "myVM"
+ VMSize = 'Standard_DS1_v2'
+}
+$vmos = @{
+ ComputerName = "myVM"
+ Credential = $cred
+}
+$vmimage = @{
+ PublisherName = 'MicrosoftWindowsServer'
+ Offer = 'WindowsServer'
+ Skus = '2019-Datacenter'
+ Version = 'latest'
+}
+$vmConfig = New-AzVMConfig @vmsz `
+ | Set-AzVMOperatingSystem @vmos -Windows `
+ | Set-AzVMSourceImage @vmimage `
+ | Add-AzVMNetworkInterface -Id $nicVM.Id
+
+## Create the virtual machine for VMs ##
+$vm = @{
+ ResourceGroupName = 'myResourceGroupNAT'
+ Location = 'eastus2'
+ VM = $vmConfig
+}
+New-AzVM @vm
+
+```
+
+Wait for the virtual machine creation to complete before moving on to the next section.
+
+## Test NAT gateway
+
+In this section, we'll test the NAT gateway. We'll first discover the public IP of the NAT gateway. We'll then connect to the test virtual machine and verify the outbound connection through the NAT gateway.
+
+1. Sign in to the [Azure portal](https://portal.azure.com)
+
+1. Find the public IP address for the NAT gateway on the **Overview** screen. Select **All services** in the left-hand menu, select **All resources**, and then select **myPublicIP**.
+
+2. Make note of the public IP address:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/find-public-ip.png" alt-text="Discover public IP address of NAT gateway" border="true":::
+
+3. Select **All services** in the left-hand menu, select **All resources**, and then from the resources list, select **myVM** that is located in the **myResourceGroupNAT** resource group.
+
+4. On the **Overview** page, select **Connect**, then **Bastion**.
+
+5. Select the blue **Use Bastion** button.
+
+6. Enter the username and password entered during VM creation.
+
+7. Open **Internet Explorer** on **myTestVM**.
+
+8. Enter **https://whatsmyip.com** in the address bar.
+
+9. Verify the IP address displayed matches the NAT gateway address you noted in the previous step:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/my-ip.png" alt-text="Internet Explorer showing external outbound IP" border="true":::
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete
+the virtual network, virtual machine, and NAT gateway with the following steps:
+
+```azurepowershell-interactive
+Remove-AzResourceGroup -Name 'myResourceGroupNAT' -Force
+```
+
+## Next steps
+
+For more information on Azure NAT Gateway, see:
+> [!div class="nextstepaction"]
+> [Azure NAT Gateway overview](nat-overview.md)
nat-gateway Quickstart Create Nat Gateway Template https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/quickstart-create-nat-gateway-template.md
+
+ Title: 'Create a NAT gateway - Resource Manager Template'
+
+description: This quickstart shows how to create a NAT gateway by using the Azure Resource Manager template (ARM template).
+++ Last updated : 04/24/2023++
+# Customer intent: I want to create a NAT gateway by using an Azure Resource Manager template so that I can provide outbound connectivity for my virtual machines.
++
+# Quickstart: Create a NAT gateway - ARM template
+
+Get started with Azure NAT Gateway by using an Azure Resource Manager template (ARM template). This template deploys a virtual network, a NAT gateway resource, and Ubuntu virtual machine. The Ubuntu virtual machine is deployed to a subnet that is associated with the NAT gateway resource.
++
+If your environment meets the prerequisites and you're familiar with using ARM templates, select the **Deploy to Azure** button. The template opens in the Azure portal.
+
+[![Deploy to Azure](../media/template-deployments/deploy-to-azure.svg)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-quickstart-templates%2Fmaster%2Fquickstarts%2Fmicrosoft.network%2Fnat-gateway-1-vm%2Fazuredeploy.json)
+
+## Prerequisites
+
+# [**Portal**](#tab/create-nat-portal)
+
+- If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
+
+# [**PowerShell**](#tab/create-nat-powershell)
+
+- If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
+
+- Azure PowerShell installed locally or Azure Cloud Shell.
+
+- Sign in to Azure PowerShell and ensure you've selected the subscription with which you want to use this feature. For more information, see [Sign in with Azure PowerShell](/powershell/azure/authenticate-azureps).
+
+- Ensure your `Az.Network` module is 4.3.0 or later. To verify the installed module, use the command `Get-InstalledModule -Name "Az.Network"`. If the module requires an update, use the command `Update-Module -Name Az.Network` if necessary.
+
+If you choose to install and use PowerShell locally, this article requires the Azure PowerShell module version 5.4.1 or later. Run `Get-Module -ListAvailable Az` to find the installed version. If you need to upgrade, see [Install Azure PowerShell module](/powershell/azure/install-Az-ps). If you're running PowerShell locally, you also need to run `Connect-AzAccount` to create a connection with Azure.
+
+# [**Azure CLI**](#tab/create-nat-cli)
+
+ - If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
++
+- This how-to article requires version 2.31.0 or later of the Azure CLI. If using Azure Cloud Shell, the latest version is already installed.
++
+## Review the template
+
+The template used in this quickstart is from [Azure Quickstart Templates](https://azure.microsoft.com/resources/templates/nat-gateway-1-vm).
+
+This template is configured to create a:
+
+* Virtual network
+
+* NAT gateway resource
+
+* Ubuntu virtual machine
+
+The Ubuntu VM is deployed to a subnet that's associated with the NAT gateway resource.
++
+Nine Azure resources are defined in the template:
+
+* **[Microsoft.Network/networkSecurityGroups](/azure/templates/microsoft.network/networksecuritygroups)**: Creates a network security group.
+
+* **[Microsoft.Network/networkSecurityGroups/securityRules](/azure/templates/microsoft.network/networksecuritygroups/securityrules)**: Creates a security rule.
+
+* **[Microsoft.Network/publicIPAddresses](/azure/templates/microsoft.network/publicipaddresses)**: Creates a public IP address.
+
+* **[Microsoft.Network/publicIPPrefixes](/azure/templates/microsoft.network/publicipprefixes)**: Creates a public IP prefix.
+
+* **[Microsoft.Compute/virtualMachines](/azure/templates/Microsoft.Compute/virtualMachines)**: Creates a virtual machine.
+
+* **[Microsoft.Network/virtualNetworks](/azure/templates/microsoft.network/virtualnetworks)**: Creates a virtual network.
+
+* **[Microsoft.Network/natGateways](/azure/templates/microsoft.network/natgateways)**: Creates a NAT gateway resource.
+
+* **[Microsoft.Network/virtualNetworks/subnets](/azure/templates/microsoft.network/virtualnetworks/subnets)**: Creates a virtual network subnet.
+
+* **[Microsoft.Network/networkinterfaces](/azure/templates/microsoft.network/networkinterfaces)**: Creates a network interface.
+
+## Deploy the template
+
+# [**Portal**](#tab/create-nat-portal)
+
+[![Deploy to Azure](../media/template-deployments/deploy-to-azure.svg)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-quickstart-templates%2Fmaster%2Fquickstarts%2Fmicrosoft.network%2Fnat-gateway-1-vm%2Fazuredeploy.json)
+
+## Review deployed resources
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+1. Select **Resource groups** from the left pane.
+
+1. Select the resource group that you created in the previous section. The default resource group name is **myResourceGroupNAT**
+
+1. Verify the following resources were created in the resource group:
+
+ ![Virtual Network NAT resource group](./media/quick-create-template/nat-gateway-template-rg.png)
+
+# [**PowerShell**](#tab/create-nat-powershell)
+
+```azurepowershell-interactive
+$location = Read-Host -Prompt "Enter the location (i.e. westcentralus)"
+$templateUri = "https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/quickstarts/microsoft.network/nat-gateway-1-vm/azuredeploy.json"
+
+$resourceGroupName = "myResourceGroupNAT"
+
+New-AzResourceGroup -Name $resourceGroupName -Location $location
+New-AzResourceGroupDeployment -ResourceGroupName $resourceGroupName -TemplateUri $templateUri
+```
+
+# [**Azure CLI**](#tab/create-nat-cli)
+
+```azurecli-interactive
+read -p "Enter the location (i.e. westcentralus): " location
+resourceGroupName="myResourceGroupNAT"
+templateUri="https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/quickstarts/microsoft.network/nat-gateway-1-vm/azuredeploy.json"
+
+az group create \
+--name $resourceGroupName \
+--location $location
+
+az deployment group create \
+--resource-group $resourceGroupName \
+--template-uri $templateUri
+```
+++
+## Clean up resources
+
+# [**Portal**](#tab/create-nat-portal)
+
+When no longer needed, delete the resource group, NAT gateway, and all related resources. Select the resource group **myResourceGroupNAT** that contains the NAT gateway, and then select **Delete**.
+
+# [**PowerShell**](#tab/create-nat-powershell)
+
+When no longer needed, you can use the [Remove-AzResourceGroup](/powershell/module/az.resources/remove-azresourcegroup) command to remove the resource group and all resources contained within.
+
+```azurepowershell-interactive
+Remove-AzResourceGroup -Name myResourceGroupNAT
+```
+
+# [**Azure CLI**](#tab/create-nat-cli)
+
+When no longer needed, you can use the [az group delete](/cli/azure/group#az-group-delete) command to remove the resource group and all resources contained within.
+
+```azurecli-interactive
+ az group delete \
+ --name myResourceGroupNAT
+```
+++
+## Next steps
+
+In this quickstart, you created a:
+
+* NAT gateway resource
+
+* Virtual network
+
+* Ubuntu virtual machine
+
+The virtual machine is deployed to a virtual network subnet associated with the NAT gateway.
+
+To learn more about Azure NAT Gateway and Azure Resource Manager, continue to the following articles.
+
+* Read an [Overview of Azure NAT Gateway](nat-overview.md)
+
+* Read about the [NAT Gateway resource](nat-gateway-resource.md)
+
+* Learn more about [Azure Resource Manager](../azure-resource-manager/management/overview.md)
nat-gateway Region Move Nat Gateway https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/region-move-nat-gateway.md
+
+ Title: Create and configure NAT gateway after moving resources to another region
+description: Learn how to configure a new NAT gateway for resources moved to another region.
++++ Last updated : 01/04/2022+++
+# Create and configure NAT gateway after moving resources to another region
+
+In this article, learn how to configure a NAT gateway after moving resources to a different region. You might want to move resources to take advantage of a new Azure region that is better suited to your customers' geographical presence, other needs, or to meet internal policy and governance requirements, or to take advantage of your organizationΓÇÖs infrastructure.
+
+> [!NOTE]
+> NAT gateway instances can't directly be moved from one region to another. A workaround is to use Azure Resource Mover to move all the resources associated with the existing NAT gateway to the new region. You then create a new instance of NAT gateway in the new region and then associate the moved resources with the new instance. After the new NAT gateway is functional in the new region, you delete the old instance in the previous region.
+
+## Prerequisites
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+- **Owner** access in the subscription in which resources you want to move are located.
+
+- Resources from previous region moved to new region. For more information on moving resources to another region, see [Move resources to another region with Azure Resource Mover](../resource-mover/move-region-within-resource-group.md). Follow the steps in that article to move the resources in your previous region that are associated with the NAT gateway. After successful move of the resources, continue with the steps in this article.
+
+## Create a new NAT gateway
+
+After you have moved all the resources associated with the original instance of NAT gateway to the new region and verified them, the following steps will enable you to create a new instance of NAT gateway. This new NAT gateway can then be associated with the moved resources.
+
+1. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways**.
+
+2. Select **+ Create**.
+
+3. In **Create network address translation (NAT) gateway**, enter or select the following information in the **Basics** tab.
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **Create new**. </br> Enter **myResourceGroup** in **Name**. </br> Select **OK**. </br> Instead, you can select the existing resource group associated with the moved resources in the subscription. |
+ | **Instance details** | |
+ | Name | Enter **myNATgateway**. |
+ | Region | Select the name of the new region. |
+ | Availability Zone | Select **None**. Instead, you can select the zone of the moved resources if applicable. |
+ | Idle timeout (minutes) | Enter **10**. |
+
+4. Select the **Outbound IP** tab, or select **Next: Outbound IP** at the bottom of the page.
+
+5. In the **Outbound IP** tab, enter or select the following information.
+
+ | Setting | Value |
+ | - | -- |
+ | Public IP addresses | Select **Create a new public IP address**. </br> Enter **myNATPublicIP** in **Name**. </br> Select **OK**. </br> Instead, you can select an existing public IP in your subscription if applicable. |
+
+6. Select the **Subnet** tab, or select **Next: Subnet** at the bottom of the page.
+
+7. Select the pull-down box under **Virtual network** in the **Subnet** tab. Select the **Virtual Network** that you **moved** using Azure Resource Mover.
+
+8. In **Subnet name**, select the **subnet** that you **moved** using Azure Resource Mover.
+
+9. Select the **Review + create** tab, or select the **Review + create** button at the bottom of the page.
+
+10. Select **Create**.
+
+## Test NAT gateway in new region
+
+For steps on how to test the NAT gateway, see [Quickstart: Create a NAT gateway - Azure portal](quickstart-create-nat-gateway-portal.md#test-nat-gateway).
+
+## Delete old instance of NAT gateway
+
+After you have created new NAT gateway and have tested it, you can delete the source resources from the old region. This step will automatically delete the original NAT gateway.
+
+## Next steps
+
+For more information on moving resources in Azure, see:
+
+- [Move NSGs to another region](../virtual-network/move-across-regions-nsg-portal.md).
+- [Move public IP addresses to another region](../virtual-network/move-across-regions-publicip-portal.md).
+- [Move a storage account to another region](../storage/common/storage-account-move.md?tabs=azure-portal)
++
nat-gateway Resource Health https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/resource-health.md
+
+ Title: Azure NAT Gateway Resource Health
+
+description: Understand how to use resource health for NAT gateway.
++
+# Customer intent: As an IT administrator, I want to understand how to use resource health to monitor NAT gateway.
+ Last updated : 04/25/2022++
+# Azure NAT Gateway Resource Health
+
+This article provides guidance on how to use Azure Resource Health to monitor and troubleshoot connectivity issues with your NAT gateway resource. Resource health provides an automatic check to keep you informed on the current availability of your NAT gateway.
+
+## Resource health status
+
+[Azure Resource Health](../service-health/overview.md) provides information about the health of your NAT gateway resource. You can use resource health and Azure monitor notifications to keep you informed on the availability and health status of your NAT gateway resource. Resource health can help you quickly assess whether an issue is due to a problem in your Azure infrastructure or because of an Azure platform event. The resource health of your NAT gateway is evaluated by measuring the data-path availability of your NAT gateway endpoint.
+
+You can view the status of your NAT gatewayΓÇÖs health status on the **Resource Health** page, found under **Support + troubleshooting** for your NAT gateway resource.
+
+The health of your NAT gateway resource is displayed as one of the following statuses:
+
+| Resource health status | Description |
+|||
+| Available | Your NAT gateway resource is healthy and available. |
+| Degraded | Your NAT gateway resource has platform or user initiated events impacting the health of your NAT gateway. The metric for the data-path availability has reported less than 80% but greater than 25% health for the last fifteen minutes. |
+| Unavailable | Your NAT gateway resource is not healthy. The metric for the data-path availability has reported less than 25% for the past 15 minutes. You may experience unavailability of your NAT gateway resource for outbound connectivity. |
+| Unknown | Health status for your NAT gateway resource hasnΓÇÖt been updated or hasnΓÇÖt received information for data-path availability for more than 5 minutes. This state should be transient and will reflect the correct status as soon as data is received. |
+
+For more information about Azure Resource Health, see [Resource Health overview](../service-health/resource-health-overview.md).
+
+To view the health of your NAT gateway resource:
+
+1. From the NAT gateway resource page, under **Support + troubleshooting**, select **Resource health**.
+
+2. In the health history section, select the drop-down arrows next to dates to get more information on health history events of your NAT gateway resource. You can view up to 30 days of history in the health history section.
+
+3. Select the **+ Add resource health alert** at the top of the page to set up an alert for a specific health status of your NAT gateway resource.
+
+## Next steps
+
+- Learn about [Azure NAT Gateway](./nat-overview.md)
+- Learn about [metrics and alerts for NAT gateway](./nat-metrics.md)
+- Learn about [troubleshooting NAT gateway resources](./troubleshoot-nat.md)
+- Learn about [Azure resource health](../service-health/resource-health-overview.md)
nat-gateway Troubleshoot Nat And Azure Services https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/troubleshoot-nat-and-azure-services.md
+
+ Title: Troubleshoot outbound connectivity with Azure services
+
+description: Troubleshoot issues with NAT gateway and Azure services.
+++ Last updated : 08/29/2022+++
+# Troubleshoot outbound connectivity with NAT gateway and Azure services
+
+This article provides guidance on how to troubleshoot connectivity issues when using NAT gateway with other Azure services, including:
+
+* [Azure App Services](#azure-app-services)
+
+* [Azure Kubernetes Service](#azure-kubernetes-service)
+
+* [Azure Firewall](#azure-firewall)
+
+* [Azure Databricks](#azure-databricks)
+
+## Azure App Services
+
+### Azure App Services regional Virtual network integration turned off
+
+NAT gateway can be used with Azure app services to allow applications to make outbound calls from a virtual network. To use this integration between Azure app services and NAT gateway, regional virtual network integration must be enabled. See [how regional virtual network integration works](../app-service/overview-vnet-integration.md#how-regional-virtual-network-integration-works) to learn more.
+
+To use NAT gateway with Azure App services, follow these steps:
+
+1. Ensure that your application(s) have virtual network integration configured, see [Enable virtual network integration](../app-service/configure-vnet-integration-enable.md).
+
+2. Ensure that **Route All** is enabled for your virtual network integration, see [Configure virtual network integration routing](../app-service/configure-vnet-integration-routing.md).
+
+3. Create a NAT gateway resource.
+
+4. Create a new public IP address or attach an existing public IP address in your network to NAT gateway.
+
+5. Assign NAT gateway to the same subnet being used for Virtual network integration with your application(s).
+
+To see step-by-step instructions on how to configure NAT gateway with virtual network integration, see [Configuring NAT gateway integration](../app-service/networking/nat-gateway-integration.md#configuring-nat-gateway-integration)
+
+Important notes about the NAT gateway and Azure App Services integration:
+
+* Virtual network integration doesn't provide inbound private access to your app from the virtual network.
+
+* Because of the nature of how virtual network integration operates, the traffic from virtual network integration doesn't show up in Azure Network Watcher or NSG flow logs.
+
+### App services isn't using the NAT gateway public IP address to connect outbound
+
+App services can still connect outbound to the internet even if VNet integration isn't enabled. By default, apps that are hosted in App Service are accessible directly through the internet and can reach only internet-hosted endpoints. To learn more, see App Services Networking Features.
+
+If you notice that the IP address used to connect outbound isn't your NAT gateway public IP address or addresses, check that virtual network integration has been enabled. Ensure the NAT gateway is configured to the subnet used for integration with your application(s).
+
+To validate that web applications are using the NAT gateway public IP, ping a virtual machine on your Web Apps and check the traffic via a network capture.
+
+## Azure Kubernetes Service
+
+### How to deploy NAT gateway with AKS clusters
+
+NAT gateway can be deployed with AKS clusters in order to allow for explicit outbound connectivity. There are two different ways to deploy NAT gateway with AKS clusters:
+
+1. **Managed NAT gateway**: NAT gateway is provisioned by Azure at the time of the AKS cluster creation and managed by AKS.
+
+2. **User-Assigned NAT gateway**: NAT gateway is provisioned by you to an existing virtual network for the AKS cluster.
+
+Learn more at [Managed NAT Gateway](../aks/nat-gateway.md).
+
+### Can't update my NAT gateway IPs or idle timeout timer for an AKS cluster
+
+Public IP addresses and the idle timeout timer for NAT gateway can be updated with the az aks update command for a Managed NAT gateway ONLY.
+
+If you've provisioned a User-Assigned NAT gateway to your AKS subnets, then you can't use the az aks update command to update public IP addresses or the idle timeout timer. A User-Assigned NAT gateway is managed by the user rather than by AKS. You'll need to update these configurations manually on your NAT gateway resource.
+
+Update your public IP addresses on your User-Assigned NAT gateway with the following steps:
+
+1. In your resource group, select on your NAT gateway resource in the portal
+
+2. Under Settings on the left-hand navigation bar, select Outbound IP
+
+3. To manage your Public IP addresses, select the blue Change
+
+4. From the Manage public IP addresses and prefixes configuration that slides in from the right, update your assigned public IPs from the drop-down menu or select **Create a new public IP address**.
+
+5. Once you're done updating your IP configurations, select the OK button at the bottom of the screen.
+
+6. After the configuration page disappears, select the Save button to save your changes
+
+7. Use steps 3 - 6 to do the same for public IP prefixes.
+
+Update your idle timeout timer configuration on your User-Assigned NAT gateway with the following steps:
+
+1. In your resource group, select on your NAT gateway resource in the portal
+
+2. Under Settings on the left-hand navigation bar, select Configuration
+
+3. In the TCP idle timeout (minutes) text bar, adjust the idle timeout timer (the timer can be configured 4 ΓÇô 120 minutes).
+
+4. Select the Save button when youΓÇÖre done.
+
+>[!Note]
+>Increasing the TCP idle timeout timer to longer than 4 minutes can increase the risk of SNAT port exhaustion. For more information, see timer considerations.
+
+## Azure Firewall
+
+### SNAT exhaustion when connecting outbound with Azure Firewall
+
+Azure Firewall can provide outbound connectivity to the internet from virtual networks. Azure Firewall provides only 2,496 SNAT ports per public IP address. While Azure Firewall can be associated with up to 250 public IP addresses to handle egress traffic, users may require much fewer public IP addresses for connecting outbound. The requirement for egressing with fewer public IP addresses may be due to various architectural requirements and allowlist limitations by destination endpoints.
+
+One method by which to provide greater scalability for outbound traffic and also reduce the risk of SNAT port exhaustion is to use NAT gateway in the same subnet with Azure Firewall. To set up NAT gateway in an Azure Firewall subnet, see [integrate NAT gateway with Azure Firewall](/azure/virtual-network/nat-gateway/tutorial-hub-spoke-nat-firewall). See [Scale SNAT ports with Azure NAT Gateway](../firewall/integrate-with-nat-gateway.md) to learn more about how NAT gateway works with Firewall.
+
+> [!NOTE]
+> NAT gateway is not supported in a vWAN architecture. NAT gateway cannot be configured to an Azure Firewall subnet in a vWAN hub.
+
+## Azure Databricks
+
+### How to use NAT gateway to connect outbound from a databricks cluster
+
+NAT gateway can be used to connect outbound from your databricks cluster when you create your Databricks workspace. NAT gateway can be deployed to your databricks cluster in one of two ways:
+
+1. By enabling [Secure Cluster Connectivity (No Public IP)](/azure/databricks/security/secure-cluster-connectivity#use-secure-cluster-connectivity) on the default virtual network that Azure Databricks creates, NAT gateway will automatically be deployed for connecting outbound from your workspaceΓÇÖs subnets to the internet. This NAT gateway resource is created within the managed resource group managed by Azure Databricks. You can't modify this resource group or any other resources provisioned in it.
+
+2. After deploying Azure Databricks workspace in your own VNet (via [VNet injection](/azure/databricks/administration-guide/cloud-configurations/azure/vnet-inject)), you can deploy and configure NAT gateway to both of your workspaceΓÇÖs subnets to ensure outbound connectivity through the NAT gateway. You can implement this solution using an [Azure template](/azure/databricks/administration-guide/cloud-configurations/azure/vnet-inject#advanced-configuration-using-azure-resource-manager-templates) or in the portal.
+
+## Next steps
+
+We're always looking to improve the experience of our customers. If you're experiencing issues with NAT gateway that aren't listed or resolved by this article, submit feedback through GitHub via the bottom of this page. We'll address your feedback as soon as possible.
+
+To learn more about NAT gateway, see:
+
+* [Azure NAT Gateway](./nat-overview.md)
+
+* [NAT gateway resource](./nat-gateway-resource.md)
+
+* [Metrics and alerts for NAT gateway resources](./nat-metrics.md)
nat-gateway Troubleshoot Nat Connectivity https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/troubleshoot-nat-connectivity.md
+
+ Title: Troubleshoot Azure NAT Gateway connectivity
+description: Troubleshoot connectivity issues with a NAT gateway.
++++ Last updated : 04/24/2023+++
+# Troubleshoot Azure NAT Gateway connectivity
+
+This article provides guidance on how to troubleshoot and resolve common outbound connectivity issues with your NAT gateway resource. This article also provides best practices on how to design applications to use outbound connections efficiently.
+
+## SNAT exhaustion due to NAT gateway configuration
+
+SNAT exhaustion issues with NAT gateway typically have to do with the configurations on the NAT gateway, such as:
+
+* NAT gateway not scaled out with enough public IP addresses.
+
+* NAT gateway's configurable TCP idle timeout timer is set higher than the default value of 4 minutes.
+
+### NAT gateway not scaled out enough
+
+Each public IP address provides 64,512 SNAT ports for connecting outbound with NAT gateway. From those available SNAT ports, NAT gateway can support up to 50,000 concurrent connections to the same destination endpoint. If outbound connections are dropping because SNAT ports are being exhausted, then NAT gateway may not be scaled out enough to handle the workload. More public IP addresses on NAT gateway may be required in order to provide more SNAT ports for outbound connectivity.
+
+The following table describes two common outbound connectivity failure scenarios due to scalability issues and how to validate and mitigate these issues:
+
+| Scenario | Evidence |Mitigation |
+||||
+| You're experiencing contention for SNAT ports and SNAT port exhaustion during periods of high usage. | You run the following [metrics](nat-metrics.md) in Azure Monitor: **Total SNAT Connection Count**: "Sum" aggregation shows high connection volume. For **SNAT Connection Count**, "Failed" connection state shows transient or persistent failures over time. **Dropped Packets**: "Sum" aggregation shows packets dropping consistent with high connection volume and connection failures. | Add more public IP addresses or public IP prefixes as need (assign up to 16 IP addresses in total to your NAT gateway). This addition provides more SNAT port inventory and allow you to scale your scenario further. |
+| You have already assigned 16 IP addresses to your NAT gateway and still are experiencing SNAT port exhaustion. | Attempt to add more IP addresses fails. Total number of IP addresses from public IP address or public IP prefix resources exceeds a total of 16. | Distribute your application environment across multiple subnets and provide a NAT gateway resource for each subnet. |
+
+>[!NOTE]
+>It is important to understand why SNAT exhaustion occurs. Make sure you are using the right patterns for scalable and reliable scenarios. Adding more SNAT ports to a scenario without understanding the cause of the demand should be a last resort. If you do not understand why your scenario is applying pressure on SNAT port inventory, adding more SNAT ports by adding more IP addresses will only delay the same exhaustion failure as your application scales. You may be masking other inefficiencies and anti-patterns. For more information, see [best practices for efficient use of outbound connections](#outbound-connectivity-best-practices).
+
+### TCP idle timeout timers set higher than the default value
+
+The NAT gateway TCP idle timeout timer is set to 4 minutes by default but is configurable up to 120 minutes. If the timer is set to a higher value than the default, NAT gateway holds on to flows longer, and can create [extra pressure on SNAT port inventory](./nat-gateway-resource.md#timers).
+
+The following table describes a scenario where a long TCP idle timeout timer is causing SNAT exhaustion and provides mitigation steps to take:
+
+| Scenario | Evidence | Mitigation |
+||||
+| You want to ensure that TCP connections stay active for long periods of time without idling and timing out. You increase the TCP idle timeout timer setting. After a period of time, you start to notice that connection failures occur more often. You suspect that you may be exhausting your inventory of SNAT ports since connections are holding on to them longer. | You check the following [NAT gateway metrics](nat-metrics.md) in Azure Monitor to determine if SNAT port exhaustion is happening: **Total SNAT Connection Count**: "Sum" aggregation shows high connection volume. For **SNAT Connection Count**, "Failed" connection state shows transient or persistent failures over time. **Dropped Packets**: "Sum" aggregation shows packets dropping consistent with high connection volume and connection failures. | Some possible steps you can take to resolve SNAT port exhaustion include: </br></br> **Reduce the TCP idle timeout** to a lower value to free up SNAT port inventory earlier. The TCP idle timeout timer can't be set lower than 4 minutes. </br></br> Consider **[asynchronous polling patterns](/azure/architecture/patterns/async-request-reply)** to free up connection resources for other operations. </br></br> **Use TCP keepalives or application layer keepalives** to avoid intermediate systems timing out. For examples, see [.NET examples](/dotnet/api/system.net.servicepoint.settcpkeepalive). </br></br> Make connections to Azure PaaS services over the Azure backbone using **[Private Link](../private-link/private-link-overview.md)**. The use of private link frees up SNAT ports for outbound connections to the internet. |
+
+## Connection failures due to idle timeouts
+
+### TCP idle timeout
+
+As described in the [TCP timers](#tcp-idle-timeout-timers-set-higher-than-the-default-value) in the previous section, TCP keepalives should be used to refresh idle flows and reset the idle timeout. TCP keepalives only need to be enabled from one side of a connection in order to keep a connection alive from both sides. When a TCP keepalive is sent from one side of a connection, the other side automatically sends an ACK packet. The idle timeout timer is then reset on both sides of the connection. To learn more, see [Timer considerations](./nat-gateway-resource.md#timer-considerations).
+
+>[!Note]
+>Increasing the TCP idle timeout is a last resort and may not resolve the root cause. A long timeout can cause low-rate failures when timeout expires and introduce delay and unnecessary failures.
+
+### UDP idle timeout
+
+UDP idle timeout timers are set to 4 minutes. Unlike TCP idle timeout timers for NAT gateway, UDP idle timeout timers aren't configurable.
+
+The following table describes a common scenario encountered with connections dropping due to UDP traffic idle timing out and steps to take to mitigate the issue.
+
+| Scenario | Evidence | Mitigation |
+||||
+| You notice that UDP traffic is dropping connections that need to be maintained for long periods of time. | You check the following [NAT gateway metrics](nat-metrics.md) in Azure Monitor, **Dropped Packets**: "Sum" aggregation shows packets dropping consistent with high connection volume and connection failures. | A few possible mitigation steps that can be taken: - **Enable UDP keepalives**. Keep in mind that when a UDP keepalive is enabled, it's only active for one direction in a connection. The connection can still go idle and time out on the other side of a connection. To prevent a UDP connection from idle time-out, UDP keepalives should be enabled for both directions in a connection flow. - **Application layer keepalives** can also be used to refresh idle flows and reset the idle timeout. Check the server side for what options exist for application specific keepalives. |
+
+## NAT gateway public IP not being used for outbound traffic
+
+### VMs hold on to prior SNAT IP with active connection after NAT gateway added to a virtual network
+
+[NAT gateway](nat-overview.md) becomes the default route to the internet when configured to a subnet. Migration from default outbound access or load balancer to NAT gateway results in new connections immediately using the IP address(es) associated with the NAT gateway resource. If a virtual machine has an established connection during the migration, the connection continues to use the old SNAT IP address that was assigned when the connection was established.
+
+Test and resolve issues with VMs holding on to old SNAT IP addresses by:
+
+- Ensure you've established a new connection and that existing connections aren't being reused in the OS or that the browser is caching the connections. For example, when using curl in PowerShell, make sure to specify the -DisableKeepalive parameter to force a new connection. If you're using a browser, connections may also be pooled.
+
+- It isn't necessary to reboot a virtual machine in a subnet configured to NAT gateway. However, if a virtual machine is rebooted, the connection state is flushed. When the connection state has been flushed, all connections begin using the NAT gateway resource's IP address(es). This behavior is a side effect of the virtual machine reboot and not an indicator that a reboot is required.
+
+If you're still having trouble, open a support case for further troubleshooting.
+
+### Virtual appliance UDRs and ExpressRoute override NAT gateway for routing outbound traffic
+
+When forced tunneling with a custom UDR is enabled to direct traffic to a virtual appliance or VPN through ExpressRoute, the UDR or ExpressRoute takes precedence over NAT gateway for directing internet bound traffic. To learn more, see [custom UDRs](../virtual-network/virtual-networks-udr-overview.md#custom-routes).
+
+The order of precedence for internet routing configurations is as follows:
+Virtual appliance UDR / ExpressRoute >> NAT gateway >> instance level public IP addresses >> outbound rules on Load balancer >> default outbound access
+
+Test and resolve issues with a virtual appliance UDR or VPN ExpressRoute overriding your NAT gateway by:
+
+1. [Testing that the NAT gateway public IP](./quickstart-create-nat-gateway-portal.md#test-nat-gateway) is used for outbound traffic. If a different IP is being used, it could be because of a custom UDR, follow the remaining steps on how to check for and remove custom UDRs.
+
+2. Check for UDRs in the virtual networkΓÇÖs route table, refer to [view route tables](../virtual-network/manage-route-table.md#view-route-tables).
+
+3. Remove the UDR from the route table by following [create, change, or delete an Azure route table](../virtual-network/manage-route-table.md#change-a-route-table).
+
+Once the custom UDR is removed from the routing table, the NAT gateway public IP should now take precedence in routing outbound traffic to the internet.
+
+### Private IPs are used to connect to Azure services by Private Link
+
+[Private Link](../private-link/private-link-overview.md) connects your Azure virtual networks privately to Azure PaaS services such as Azure Storage, Azure SQL, or Azure Cosmos DB over the Azure backbone network instead of over the internet. Private Link uses the private IP addresses of virtual machine instances in your virtual network to connect to these Azure platform services instead of the public IP of NAT gateway. As a result, when looking at the source IP address used to connect to these Azure services, you notice that the private IPs of your instances are used. See [Azure services listed here](../private-link/availability.md) for all services supported by Private Link.
+
+To check which Private Endpoints you have set up with Private Link:
+
+1. From the Azure portal, search for Private Link in the search box.
+
+2. In the Private Link center, select Private Endpoints or Private Link services to see what configurations have been set up. For more information, see [Manage private endpoint connections](../private-link/manage-private-endpoint.md#manage-private-endpoint-connections-on-azure-paas-resources).
+
+Service endpoints can also be used to connect your virtual network to Azure PaaS services. To check if you have service endpoints configured for your virtual network:
+
+1. From the Azure portal, navigate to your virtual network and select "Service endpoints" from Settings.
+
+2. All Service endpoints created are listed along with which subnets they're configured. For more information, see [logging and troubleshooting Service endpoints](../virtual-network/virtual-network-service-endpoints-overview.md#logging-and-troubleshooting).
+
+>[!NOTE]
+>Private Link is the recommended option over Service endpoints for private access to Azure hosted services.
+
+## Connection failures at the public internet destination
+
+Connection failures at the internet destination endpoint could be due to multiple possible factors. Factors that can affect connectivity success are:
+
+* Firewall or other traffic management components at the destination.
+
+* API rate limiting imposed by the destination side.
+
+* Volumetric DDoS mitigations or transport layer traffic shaping.
+
+Use NAT gateway [metrics](nat-metrics.md) in Azure monitor to diagnose connection issues:
+
+* Look at packet count at the source and the destination (if available) to determine how many connection attempts were made.
+
+* Look at dropped packets to see how many packets dropped by NAT gateway.
+
+What else to check for:
+
+* Check for [SNAT exhaustion](#snat-exhaustion-due-to-nat-gateway-configuration).
+
+* Validate connectivity to an endpoint in the same region or elsewhere for comparison.
+
+* If you're creating high volume or transaction rate testing, explore if reducing the rate reduces the occurrence of failures.
+
+* If changing rate impacts the rate of failures, check if API rate limits, or other constraints on the destination side might have been reached.
+
+### Other transient outbound connectivity issues
+
+Outbound Passive FTP may not work for NAT gateway with multiple public IP addresses, depending on your FTP server configuration.
+
+Passive FTP establishes different connections for control and data channels. When a NAT gateway with multiple public IP addresses sends traffic outbound, it randomly selects one of its public IP addresses for the source IP address. FTP may fail when data and control channels use different source IP addresses, depending on your FTP server configuration.
+
+To prevent possible passive FTP connection failures, do the following steps:
+
+1. Check that your NAT gateway is attached to a single public IP address rather than multiple IP addresses or a prefix.
+
+2. Make sure that the passive port range from your NAT gateway is allowed to pass any firewalls that may be at the destination endpoint.
+
+### Extra network captures
+
+If your investigation is inconclusive, open a support case for further troubleshooting and collect the following information for a quicker resolution. Choose a single virtual machine in your NAT gateway configured subnet to perform the following tests:
+
+* Use **`ps ping`** from one of the backend VMs within the virtual network to test the probe port response (example: **`ps ping 10.0.0.4:3389`**) and record results.
+
+* If no response is received in these ping tests, run a simultaneous Netsh trace on the backend VM, and the virtual network test VM while you run PsPing then stop the Netsh trace.
+
+## Outbound connectivity best practices
+
+Azure monitors and operates its infrastructure with great care. However, transient failures can still occur from deployed applications, there's no guarantee that transmissions are lossless. NAT gateway is the preferred option to connect outbound from Azure deployments in order to ensure highly reliable and resilient outbound connectivity. In addition to using NAT gateway to connect outbound, use the guidance later in the article for how to ensure that applications are using connections efficiently.
+
+### Modify the application to use connection pooling
+
+When you pool your connections, you avoid opening new network connections for calls to the same address and port. You can implement a connection pooling scheme in your application where requests are internally distributed across a fixed set of connections and reused when possible. This setup constrains the number of SNAT ports in use and creates a predictable environment. Connection pooling helps reduce latency and resource utilization and ultimately improve the performance of your applications.
+
+To learn more on pooling HTTP connections, see [Pool HTTP connections](/aspnet/core/performance/performance-best-practices#pool-http-connections-with-httpclientfactory) with HttpClientFactory.
+
+### Modify the application to reuse connections
+
+Rather than generating individual, atomic TCP connections for each request, configure your application to reuse connections. Connection reuse results in more performant TCP transactions and is especially relevant for protocols like HTTP/1.1, where connection reuse is the default. This reuse applies to other protocols that use HTTP as their transport such as REST.
+
+### Modify the application to use less aggressive retry logic
+
+When SNAT ports are exhausted or application failures occur, aggressive or brute force retries without delay and back-off logic cause exhaustion to occur or persist. You can reduce demand for SNAT ports by using a less aggressive retry logic.
+
+Depending on the configured idle timeout, if retries are too aggressive, connections may not have enough time to close and release SNAT ports for reuse.
+
+For extra guidance and examples, see [Retry pattern](../app-service/troubleshoot-intermittent-outbound-connection-errors.md).
+
+### Use keepalives to reset the outbound idle timeout
+
+For more information about keepalives, see [TCP idle timeout timers set higher than the default value](#tcp-idle-timeout-timers-set-higher-than-the-default-value).
+
+### Use Private link to reduce SNAT port usage for connecting to other Azure services
+
+When possible, Private Link should be used to connect directly from your virtual networks to Azure platform services in order to [reduce the demand](./troubleshoot-nat.md) on SNAT ports. Reducing the demand on SNAT ports can help reduce the risk of SNAT port exhaustion.
+
+To create a Private Link, see the following Quickstart guides to get started:
+
+* [Create a Private Endpoint](../private-link/create-private-endpoint-portal.md?tabs=dynamic-ip)
+
+* [Create a Private Link](../private-link/create-private-link-service-portal.md)
+
+## Next steps
+
+We always strive to enhance our customers' experience. If you encounter NAT gateway issues that not addressed or resolved by this article, provide feedback through GitHub at the bottom of this page.
+
+To learn more about NAT gateway, see:
+
+* [Azure NAT Gateway](./nat-overview.md)
+
+* [NAT gateway resource](./nat-gateway-resource.md)
+
+* [Metrics and alerts for NAT gateway resources](./nat-metrics.md)
nat-gateway Troubleshoot Nat https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/troubleshoot-nat.md
+
+ Title: Troubleshoot Azure NAT Gateway
+
+description: Troubleshoot issues with NAT Gateway.
++++ Last updated : 08/29/2022+++
+# Troubleshoot Azure NAT Gateway
+
+This article provides guidance on how to correctly configure your NAT gateway and troubleshoot common configuration and deployment related issues.
+
+* [NAT gateway configuration basics](#nat-gateway-configuration-basics)
+
+* [NAT gateway in a failed state](#nat-gateway-in-a-failed-state)
+
+* [Add or remove NAT gateway](#add-or-remove-nat-gateway)
+
+* [Add or remove subnet](#add-or-remove-subnet)
+
+* [Add or remove public IPs](#add-or-remove-public-ip-addresses)
+
+## NAT gateway configuration basics
+
+Check the following configurations to ensure that NAT gateway can be used to direct traffic outbound:
+
+1. At least one public IP address or one public IP prefix is attached to NAT gateway. At least one public IP address must be associated with the NAT gateway for it to provide outbound connectivity.
+
+2. At least one subnet is attached to a NAT gateway. You can attach multiple subnets to a NAT gateway for going outbound, but those subnets must exist within the same virtual network. NAT gateway can't span beyond a single virtual network.
+
+3. No [NSG rules](../virtual-network/network-security-groups-overview.md#outbound) or [UDRs](./troubleshoot-nat-connectivity.md#virtual-appliance-udrs-and-expressroute-override-nat-gateway-for-routing-outbound-traffic) are blocking NAT gateway from directing traffic outbound to the internet.
+
+### How to validate connectivity
+
+[NAT gateway](./nat-overview.md#azure-nat-gateway-basics) supports IPv4 UDP and TCP protocols. ICMP isn't supported and is expected to fail.
+
+To validate end-to-end connectivity of NAT gateway, follow these steps:
+1. Validate that your [NAT gateway public IP address is being used](./quickstart-create-nat-gateway-portal.md#test-nat-gateway).
+
+2. Conduct TCP connection tests and UDP-specific application layer tests.
+
+3. Look at NSG flow logs to analyze outbound traffic flows from NAT gateway.
+
+Refer to the table below for which tools to use to validate NAT gateway connectivity.
+
+| Operating system | Generic TCP connection test | TCP application layer test | UDP |
+|||||
+| Linux | nc (generic connection test) | curl (TCP application layer test) | application specific |
+| Windows | [PsPing](/sysinternals/downloads/psping) | PowerShell [Invoke-WebRequest](/powershell/module/microsoft.powershell.utility/invoke-webrequest) | application specific |
+
+### How to analyze outbound connectivity
+
+To analyze outbound traffic from NAT gateway, use NSG flow logs. NSG flow logs provide connection information for your virtual machines. The connection information contains the source IP and port and the destination IP and port and the state of the connection. The traffic flow direction and the size of the traffic in number of packets and bytes sent is also logged. The source IP and port specified in the NSG flow log will be that of the virtual machine and not of the NAT gateway.
+
+* To learn more about NSG flow logs, see [NSG flow log overview](../network-watcher/network-watcher-nsg-flow-logging-overview.md).
+
+* For guides on how to enable NSG flow logs, see [Enabling NSG flow logs](../network-watcher/network-watcher-nsg-flow-logging-overview.md#enabling-nsg-flow-logs).
+
+* For guides on how to read NSG flow logs, see [Working with NSG flow logs](../network-watcher/network-watcher-nsg-flow-logging-overview.md#working-with-flow-logs).
+
+## NAT gateway in a failed state
+
+You may experience outbound connectivity failure if your NAT gateway resource is in a failed state. To get your NAT gateway out of a failed state, follow these instructions:
+
+1. Once you identify the resource that is in a failed state, go to [Azure Resource Explorer](https://resources.azure.com/) and identify the resource in this state.
+
+2. Update the toggle on the right-hand top corner to Read/Write.
+
+3. Select on Edit for the resource in failed state.
+
+4. Select on PUT followed by GET to ensure the provisioning state was updated to Succeeded.
+
+5. You can then proceed with other actions as the resource is out of failed state.
+
+## Add or remove NAT gateway
+
+### Can't delete NAT gateway
+
+NAT gateway must be detached from all subnets within a virtual network before the resource can be removed or deleted. See [Remove NAT gateway from an existing subnet and delete the resource](./manage-nat-gateway.md?tabs=manage-nat-portal#remove-a-nat-gateway-from-an-existing-subnet-and-delete-the-resource) for step by step guidance.
+
+## Add or remove subnet
+
+### NAT gateway can't be attached to subnet already attached to another NAT gateway
+
+A subnet within a virtual network can't have more than one NAT gateway attached to it for connecting outbound to the internet. An individual NAT gateway resource can be associated to multiple subnets within the same virtual network. NAT gateway can't span beyond a single virtual network.
+
+### Basic SKU resources can't exist in the same subnet as NAT gateway
+
+NAT gateway isn't compatible with basic resources, such as Basic Load Balancer or Basic Public IP. Basic resources must be placed on a subnet not associated with a NAT Gateway. Basic Load Balancer and Basic Public IP can be upgraded to standard to work with NAT gateway.
+
+* To upgrade a basic load balancer to standard, see [upgrade from basic public to standard public load balancer](../load-balancer/upgrade-basic-standard.md).
+
+* To upgrade a basic public IP to standard, see [upgrade from basic public to standard public IP](../virtual-network/ip-services/public-ip-upgrade-portal.md).
+
+### NAT gateway can't be attached to a gateway subnet
+
+NAT gateway can't be deployed in a gateway subnet. A gateway subnet is used by a VPN gateway for sending encrypted traffic between an Azure virtual network and on-premises location. See [VPN gateway overview](../vpn-gateway/vpn-gateway-about-vpngateways.md) to learn more about how gateway subnets are used by VPN gateway.
+
+### Can't attach NAT gateway to a subnet that contains a virtual machine NIC in a failed state
+
+When associating a NAT gateway to a subnet that contains a virtual machine network interface (NIC) in a failed state, you'll receive an error message indicating that this action can't be performed. You must first resolve the VM NIC failed state before you can attach a NAT gateway to the subnet.
+
+To get your virtual machine NIC out of a failed state, you can use one of the two following methods.
+
+#### Use PowerShell to get your virtual machine NIC out of a failed state
+
+1. Determine the provisioning state of your NICs using the [Get-AzNetworkInterface PowerShell command](/powershell/module/az.network/get-aznetworkinterface#example-2-get-all-network-interfaces-with-a-specific-provisioning-state) and setting the value of the "provisioningState" to "Succeeded".
+
+2. Perform [GET/SET PowerShell commands](/powershell/module/az.network/set-aznetworkinterface#example-1-configure-a-network-interface) on the network interface to update the provisioning state.
+
+3. Check the results of this operation by checking the provisioning state of your NICs again (follow commands from step 1).
+
+#### Use Azure Resource Explorer to get your virtual machine NIC out of a failed state
+
+1. Go to [Azure Resource Explorer](https://resources.azure.com/) (recommended to use Microsoft Edge browser)
+
+2. Expand Subscriptions (takes a few seconds for it to appear on the left)
+
+3. Expand your subscription that contains the VM NIC in the failed state
+
+4. Expand resourceGroups
+
+5. Expand the correct resource group that contains the VM NIC in the failed state
+
+6. Expand providers
+
+7. Expand Microsoft.Network
+
+8. Expand networkInterfaces
+
+9. Select on the NIC that is in the failed provisioning state
+
+10. Select the Read/Write button at the top
+
+11. Select the green GET button
+
+12. Select the blue EDIT button
+
+13. Select the green PUT button
+
+14. Select Read Only button at the top
+
+15. The VM NIC should now be in a succeeded provisioning state, you can close your browser
+
+## Add or remove public IP addresses
+
+### Can't exceed 16 public IP addresses on NAT gateway
+
+NAT gateway can't be associated with more than 16 public IP addresses. You can use any combination of public IP addresses and prefixes with NAT gateway up to a total of 16 IP addresses. To add or remove a public IP, see [add or remove a public IP address](/azure/virtual-network/nat-gateway/manage-nat-gateway?tabs=manage-nat-portal#add-or-remove-a-public-ip-address).
+
+The following IP prefix sizes can be used with NAT gateway:
+
+* /28 (sixteen addresses)
+
+* /29 (eight addresses)
+
+* /30 (four addresses)
+
+* /31 (two addresses)
+
+### IPv6 coexistence
+
+[NAT gateway](nat-overview.md) supports IPv4 UDP and TCP protocols. NAT gateway can't be associated to an IPv6 Public IP address or IPv6 Public IP Prefix. NAT gateway can be deployed on a dual stack subnet, but will still only use IPv4 Public IP addresses for directing outbound traffic. Deploy NAT gateway on a dual stack subnet when you need IPv6 resources to exist in the same subnet as IPv4 resources. See [Configure dual stack outbound connectivity with NAT gateway and public Load balancer](/azure/virtual-network/nat-gateway/tutorial-dual-stack-outbound-nat-load-balancer?tabs=dual-stack-outbound-portal) to learn how to provide IPv4 and IPv6 outbound connectivity from your dual stack subnet.
+
+### Can't use basic SKU public IPs with NAT gateway
+
+NAT gateway is a standard SKU resource and can't be used with basic SKU resources, including basic public IP addresses. You can upgrade your basic SKU public IP address in order to use with your NAT gateway using the following guidance: [Upgrade a public IP address](../virtual-network/ip-services/public-ip-upgrade-portal.md)
+
+### Can't mismatch zones of public IP addresses and NAT gateway
+
+NAT gateway is a [zonal resource](./nat-availability-zones.md) and can either be designated to a specific zone or to ΓÇÿno zoneΓÇÖ. When NAT gateway is placed in ΓÇÿno zoneΓÇÖ, Azure places the NAT gateway into a zone for you, but you don't have visibility into which zone the NAT gateway is located.
+
+NAT gateway can be used with public IP addresses designated to a specific zone, no zone, all zones (zone-redundant) depending on its own availability zone configuration. Follow guidance below:
+
+| NAT gateway availability zone designation | Public IP address / prefix designation that can be used |
+|||
+| No zone | Zone-redundant, No zone, or Zonal (the public IP zone designation can be any zone within a region in order to work with a no zone NAT gateway) |
+| Designated to a specific zone | The public IP address zone must match the zone of the NAT gateway |
+
+>[!NOTE]
+>If you need to know the zone that your NAT gateway resides in, make sure to designate it to a specific availability zone.
+
+## Next steps
+
+We're always looking to improve the experience of our customers. If you're experiencing issues with NAT gateway that aren't listed or resolved by this article, submit feedback through GitHub via the bottom of this page. We'll address your feedback as soon as possible.
+
+To learn more about NAT gateway, see:
+
+* [Azure NAT Gateway](nat-overview.md)
+
+* [NAT gateway resource](nat-gateway-resource.md)
+
+* [Manage NAT gateway](./manage-nat-gateway.md)
+
+* [Metrics and alerts for NAT gateway resources](nat-metrics.md).
nat-gateway Tutorial Dual Stack Outbound Nat Load Balancer https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-dual-stack-outbound-nat-load-balancer.md
+
+ Title: 'Tutorial: Configure dual-stack outbound connectivity with a NAT gateway and a public load balancer'
+
+description: Learn how to configure outbound connectivity for a dual stack network with a NAT gateway and a public load balancer.
++++ Last updated : 02/05/2023+++
+# Tutorial: Configure dual stack outbound connectivity with a NAT gateway and a public load balancer
+
+In this tutorial, learn how to configure NAT gateway and a public load balancer to a dual stack subnet in order to allow for outbound connectivity for v4 workloads using NAT gateway and v6 workloads using Public Load balancer.
+
+NAT gateway supports the use of IPv4 public IP addresses for outbound connectivity whereas load balancer supports both IPv4 and IPv6 public IP addresses. When NAT gateway with an IPv4 public IP is present with a load balancer using an IPv4 public IP address, NAT gateway takes precedence over load balancer for providing outbound connectivity. When a NAT gateway is deployed in a dual-stack network with a IPv6 load balancer, IPv4 outbound traffic is handled by the NAT gateway, and IPv6 outbound traffic is handled by the load balancer.
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Create a virtual network
+> * Create a NAT gateway with an IPv4 public address
+> * Add IPv6 to the virtual network
+> * Create a public load balancer with an IPv6 public address
+> * Create a dual-stack virtual machine
+> * Validate outbound connectivity from your dual stack virtual machine
+
+## Prerequisites
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+# [**CLI**](#tab/dual-stack-outbound--cli)
++
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+- This tutorial requires version 2.0.28 or later of the Azure CLI. If using Azure Cloud Shell, the latest version is already installed.
+++
+## Create virtual network
+
+In this section, create a virtual network for the virtual machine and load balancer.
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. Sign-in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+1. Select **+ Create**.
+
+1. In the **Basics** tab of **Create virtual network**, enter or select the following information.
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **Create new**. </br> Enter **TutorialIPv6NATLB-rg**. </br> Select **OK**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet**. |
+ | Region | Select **West US 2**. |
+
+1. Select the **IP Addresses** tab, or **Next: IP Addresses**.
+
+1. Leave the default IPv4 address space of **10.1.0.0/16**. If the default is absent or different, enter an IPv4 address space of **10.1.0.0/16**.
+
+1. Select **default** under **Subnet name**. If default is missing, select **+ Add subnet**.
+
+1. In **Subnet name**, enter **myBackendSubnet**.
+
+1. Leave the default IPv4 subnet of **10.1.0.0/24**.
+
+1. Select **Save**. If creating a subnet, select **Add**.
+
+1. Select the **Security** tab or select **Next: Security**.
+
+1. In **BastionHost**, select **Enable**.
+
+1. Enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Bastion name | **myBastion** |
+ | AzureBastionSubnet address space | Enter **10.1.1.0/26**. |
+ | Public IP address | Select **Create new**. </br> Enter **myPublicIP-Bastion** in **Name**. </br> Select **OK**. |
+
+1. Select the **Review + create**.
+
+1. Select **Create**.
+
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+### Create a resource group
+
+An Azure resource group is a logical container where Azure resources are deployed and managed.
+
+Create a resource group with [az group create](/cli/azure/group#az-group-create).
+
+```azurecli-interactive
+az group create \
+ --name TutorialIPv6NATLB-rg \
+ --location westus2
+```
+
+### Create network and subnets
+
+Use [az network vnet create](/cli/azure/network/vnet#az_network_vnet_create) to create the virtual network.
+
+```azurecli-interactive
+az network vnet create \
+ --resource-group TutorialIPv6NATLB-rg \
+ --location westus2 \
+ --name myVNet \
+ --address-prefixes '10.1.0.0/16'
+```
+
+Use [az network vnet subnet create](/cli/azure/network/vnet/subnet#az_network_vnet_subnet_create) to create the IPv4 subnet for the virtual network and the Azure Bastion subnet.
+
+```azurecli-interactive
+az network vnet subnet create \
+ --name myBackendSubnet \
+ --resource-group TutorialIPv6NATLB-rg \
+ --vnet-name myVNet \
+ --address-prefixes '10.1.0.0/24'
+```
+
+```azurecli-interactive
+az network vnet subnet create \
+ --name AzureBastionSubnet \
+ --resource-group TutorialIPv6NATLB-rg \
+ --vnet-name myVNet \
+ --address-prefixes '10.1.1.0/26'
+```
+
+### Create bastion host
+
+Use [az network public-ip create](/cli/azure/network/public-ip#az_network_public_ip_create) to create a public IP address for the bastion host.
+
+```azurecli-interactive
+az network public-ip create \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myPublicIP-Bastion \
+ --sku standard \
+ --zone 1 2 3
+```
+
+Use [az network bastion create](/cli/azure/network/bastion#az_network_bastion_create) to create the bastion host.
+
+```azurecli-interactive
+az network bastion create \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myBastion \
+ --public-ip-address myPublicIP-Bastion \
+ --vnet-name myVNet \
+ --location westus2
+```
+++
+It takes a few minutes for the bastion host to deploy. You can proceed to the next steps when the virtual network is deployed.
+
+## Create NAT gateway
+
+The NAT gateway provides the outbound connectivity for the IPv4 portion of the virtual network. Use the following example to create a NAT gateway.
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways** in the search results.
+
+1. Select **+ Create**.
+
+1. In the **Basics** tab of **Create network address translation (NAT) gateway**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialIPv6NATLB-rg**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway**. |
+ | Region | Select **West US 2**. |
+ | Availability zone | Select a zone or **No Zone**. |
+ | TCP idle timeout (minutes) | Leave the default of **4**. |
+
+1. Select **Next: Outbound IP**.
+
+1. In **Public IP addresses**, select **Create a new public IP address**.
+
+1. Enter **myPublicIP-NAT** in **Name**. Select **OK**.
+
+1. Select **Next: Subnet**.
+
+1. In **Virtual network**, select **myVNet**.
+
+1. In the list of subnets, select the box for **myBackendSubnet**.
+
+1. Select **Review + create**.
+
+1. Select **Create**.
++
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+Use [az network public-ip create](/cli/azure/network/public-ip#az_network_public_ip_create) to create a public IPv4 address for the NAT gateway.
+
+```azurecli-interactive
+az network public-ip create \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myPublicIP-NAT \
+ --sku standard \
+ --zone 1 2 3
+```
+
+Use [az network nat gateway create](/cli/azure/network/nat/gateway#az-network-nat-gateway-create) to create the NAT gateway.
+
+```azurecli-interactive
+az network nat gateway create \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myNATgateway \
+ --public-ip-addresses myPublicIP-NAT \
+ --idle-timeout 4
+```
+
+Use [az network vnet subnet update](/cli/azure/network/vnet/subnet#az_network_vnet_subnet_update) to associate the NAT gateway with **myBackendSubnet**.
+
+```azurecli-interactive
+az network vnet subnet update \
+ --resource-group TutorialIPv6NATLB-rg \
+ --vnet-name myVNet \
+ --name myBackendSubnet \
+ --nat-gateway myNATgateway
+```
+++
+## Add IPv6 to virtual network
+
+The addition of IPv6 to the virtual network must be done after the NAT gateway is associated with **myBackendSubnet**. Use the following example to add and IPv6 address space and subnet to the virtual network you created in the previous steps.
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+1. Select **myVNet**.
+
+1. In **Settings**, select **Address space**.
+
+1. In the box that displays **Add additional address range**, enter **2404:f800:8000:122::/63**.
+
+1. Select **Save**.
+
+1. Select **Subnets** in **Settings**.
+
+1. Select **myBackendSubnet** in the list of subnets.
+
+1. Select the box next to **Add IPv6 address space**.
+
+1. Enter **2404:f800:8000:122::/64** in **IPv6 address space**.
+
+1. Select **Save**.
+
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+Use [az network vnet update](/cli/azure/network/vnet#az-network-vnet-update) to add the IPv6 address space to the virtual network.
+
+```azurecli-interactive
+az network vnet update \
+ --address-prefixes 10.1.0.0/16 2404:f800:8000:122::/63 \
+ --name myVNet \
+ --resource-group TutorialIPv6NATLB-rg
+```
+
+Use [az network vnet subnet update](/cli/azure/network/vnet/subnet#az_network_vnet_subnet_update) to add the IPv6 subnet to the virtual network.
+
+```azurecli-interactive
+az network vnet subnet update \
+ --address-prefixes 10.1.0.0/24 2404:f800:8000:122::/64 \
+ --name myBackendSubnet \
+ --vnet-name myVNet \
+ --resource-group TutorialIPv6NATLB-rg
+```
++
+## Create dual-stack virtual machine
+
+The network configuration of the virtual machine has IPv4 and IPv6 configurations. Create the virtual machine with an internal IPv4 address. Then add the IPv6 configuration to the network interface of the virtual machine.
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+1. Select **+ Create** then **Azure virtual machine**.
+
+1. In the **Basics** tab of **Create a virtual machine**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialIPv6NATLB-rg**. |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM**. |
+ | Region | Select **(US) West US 2**. |
+ | Availability options | Leave the default of **No infrastructure redundancy required**. |
+ | Security type | Leave the default of **Standard**. |
+ | Image | Select **Windows Server 2022 Datacenter - x64 Gen2**. |
+ | Size | Select a size. |
+ | **Administrator account** | |
+ | Username | Enter a username. |
+ | Password | Enter a password. |
+ | Confirm password | Confirm password. |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None**. |
+
+1. Select the **Networking** tab, or **Next: Disks** then **Next: Networking**.
+
+1. In the **Networking tab**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Network interface** | |
+ | Virtual network | Select **myVNet**. |
+ | Subnet | Select **myBackendSubnet (10.1.0.0/24,2404:f800:8000:122::/64)**. |
+ | Public IP | Select **None**. |
+ | NIC network security group | Select **Basic**. |
+ | Public inbound ports | Select **None**. |
+
+1. Select **Review + create**.
+
+1. Select **Create**.
+
+Wait for the virtual machine to finish deploying before continuing on to the next steps.
+
+### Add IPv6 to virtual machine
+
+The support IPv6, the virtual machine must have a IPv6 network configuration added to the network interface. Use the following example to add a IPv6 network configuration to the virtual machine.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+1. Select **myVM**.
+
+1. In **Settings** select **Networking**.
+
+1. Select the name of the network interface in the **Network Interface:** field. The name of the network interface is the virtual machine name plus a random number. In this example, it's **myVM202**.
+
+1. In the network interface properties, select **IP configurations** in **Settings**.
+
+1. Select **+ Add**.
+
+1. Enter or select the following information in **Add IP configuration**:
+
+ | Setting | Value |
+ | - | -- |
+ | Name | Enter **ipv6config**. |
+ | IP version | Select **IPv6**. |
+
+1. Leave the rest of the settings at the defaults and select **OK**.
+
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+### Create NSG
+
+Use [az network nsg create](/cli/azure/network/nsg#az-network-nsg-create) to create a network security group for the virtual machine.
+
+```azurecli-interactive
+az network nsg create \
+ --name myNSG \
+ --resource-group TutorialIPv6NATLB-rg
+```
+
+Use [az network nsg rule create](/cli/azure/network/nsg/rule#az-network-nsg-rule-create) to create a rule for RDP connectivity to the virtual machine.
+
+```azurecli-interactive
+az network nsg rule create \
+ --resource-group TutorialIPv6NATLB-rg \
+ --nsg-name myNSG \
+ --name myNSGRuleRDP \
+ --protocol '*' \
+ --direction inbound \
+ --source-address-prefix '*' \
+ --source-port-range '*' \
+ --destination-address-prefix '*' \
+ --destination-port-range 3389 \
+ --access allow \
+ --priority 200
+```
+
+### Create network interface
+
+Use [az network nic create](/cli/azure/network/nic#az-network-nic-create) to create the network interface for the virtual machine.
+
+```azurecli-interactive
+az network nic create \
+ --name myNIC \
+ --resource-group TutorialIPv6NATLB-rg \
+ --vnet-name myVNet \
+ --subnet myBackendSubnet \
+ --private-ip-address-version IPv4
+```
+
+### Add IPv6 to network interface
+
+The support IPv6, the virtual machine must have a IPv6 network configuration added to the network interface. IPv6 can't be the primary IP configuration for a virtual machine network interface. For more information, see [Overview of IPv6](../virtual-network/ip-services/ipv6-overview.md).
+
+Use [az network nic ip-config create](/cli/azure/network/nic/ip-config#az_network_nic_ip_config_create) to add the IPv6 configuration to the network interface.
+
+```azurecli-interactive
+az network nic ip-config create \
+ --name ipconfig-IPv6 \
+ --nic-name myNIC \
+ --resource-group TutorialIPv6NATLB-rg \
+ --vnet-name myVNet \
+ --subnet myBackendSubnet \
+ --private-ip-address-version IPv6
+```
+
+### Create the virtual machine
+
+Use [az vm create](/cli/azure/vm#az-vm-create) to create the virtual machine.
+
+```azurecli-interactive
+az vm create \
+ --name myVM \
+ --resource-group TutorialIPv6NATLB-rg \
+ --admin-username azureuser \
+ --image Win2022Datacenter \
+ --nics myNIC
+ ```
++
+## Create public load balancer
+
+The public load balancer has a front-end IPv6 address and outbound rule for the backend pool of the load balancer. The outbound rule controls the behavior of the external IPv6 connections for virtual machines in the backend pool. Use the following example to create an IPv6 public load balancer.
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. In the search box at the top of the portal, enter **Load balancer**. Select **Load balancers** in the search results.
+
+1. Select **+ Create**.
+
+1. In the **Basics** tab of **Create load balancer**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialIPv6NATLB-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myLoadBalancer**. |
+ | Region | Select **West US 2**. |
+ | SKU | Leave the default of **Standard**. |
+ | Type | Select **Public**. |
+
+1. Select **Next: Frontend IP configuration**.
+
+1. Select **+ Add a frontend IP configuration**.
+
+1. Enter or select the following information in **Add frontend IP configuration**:
+
+ | Setting | Value |
+ | - | -- |
+ | Name | Enter **myFrontend-IPv6**. |
+ | IP version | Select **IPv6**. |
+ | IP type | Select **IP address**. |
+ | Public IP address | Select **Create new**. </br> In **Name** enter **myPublicIP-IPv6**. </br> Select **OK**. |
+
+1. Select **Add**.
+
+1. Select **Next: Backend pools**.
+
+1. Select **+ Add a backend pool**.
+
+1. Enter or select the following information in **Add backend pool**:
+
+ | Setting | Value |
+ | - | -- |
+ | Name | Enter **myBackendPool**. |
+ | Virtual network | Select **myVNet (TutorialIPv6NATLB-rg)**. |
+ | Backend Pool Configuration | Leave the default of **NIC**. |
+
+1. Select **Save**.
+
+1. Select **Next: Inbound rules** then **Next: Outbound rules**.
+
+1. Select **Add an outbound rule**.
+
+1. Enter or select the following information in **Add outbound rule**:
+
+ | Setting | Value |
+ | - | -- |
+ | Name | Enter **myOutboundRule**. |
+ | IP Version | Select **IPv6**. |
+ | Frontend IP address | Select **myFrontend-IPv6**. |
+ | Protocol | Leave the default of **All**. |
+ | Idle timeout (minutes) | Leave the default of **4**. |
+ | TCP Reset | Leave the default of **Enabled**. |
+ | Backend pool | Select **myBackendPool**. |
+ | **Port allocation** | |
+ | Port allocation | Select **Manually choose number of outbound ports**. |
+ | **Outbound ports** | |
+ | Choose by | Select **Ports per instance**. |
+ | Ports per instance | Enter **20000**. |
+
+1. Select **Add**.
+
+1. Select **Review + create**.
+
+1. Select **Create**.
+
+Wait for the load balancer to finish deploying before proceeding to the next steps.
+
+### Add virtual machine to load balancer
+
+1. In the search box at the top of the portal, enter **Load balancer**. Select **Load balancers** in the search results.
+
+1. Select **myLoadBalancer**.
+
+1. In **Settings** select **Backend pools**.
+
+1. Select **myBackendPool**.
+
+1. In **Virtual network** select **myVNet (TutorialIPv6NATLB-rg)**.
+
+1. In **IP configurations** select **+ Add**.
+
+1. Select the checkbox for **myVM** that corresponds with the **IP configuration** of **ipv6config**. Don't select **ipconfig1**.
+
+1. Select **Add**.
+
+1. Select **Save**.
++
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+Use [az network public-ip create](/cli/azure/network/public-ip#az_network_public_ip_create) to create a public IPv6 address for the frontend IP address of the load balancer.
+
+```azurecli-interactive
+az network public-ip create \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myPublicIP-IPv6 \
+ --sku standard \
+ --version IPv6 \
+ --zone 1 2 3
+```
+
+Use [az network lb create](/cli/azure/network/lb#az-network-lb-create) to create the load balancer.
+
+```azurecli-interactive
+az network lb create \
+ --name myLoadBalancer \
+ --resource-group TutorialIPv6NATLB-rg \
+ --backend-pool-name myBackendPool \
+ --frontend-ip-name myFrontend-IPv6 \
+ --location westus2 \
+ --public-ip-address myPublicIP-IPv6 \
+ --sku Standard
+```
+
+Use [az network lb outbound-rule create](/cli/azure/network/lb/outbound-rule#az-network-lb-outbound-rule-create) to create the outbound rule for the backend pool of the load balancer. The outbound rule enables outbound connectivity for virtual machines in the backend pool of the load balancer.
+
+```azurecli-interactive
+az network lb outbound-rule create \
+ --address-pool myBackendPool \
+ --frontend-ip-configs myFrontend-IPv6 \
+ --lb-name myLoadBalancer \
+ --name myOutBoundRule \
+ --protocol All \
+ --resource-group TutorialIPv6NATLB-rg \
+ --outbound-ports 20000 \
+ --enable-tcp-reset true
+```
+
+### Add virtual machine to load balancer
+
+Use [az network nic ip-config address-pool add](/cli/azure/network/nic/ip-config/address-pool#az-network-nic-ip-config-address-pool-add) to add the network interface of the virtual machine to the backend pool of the load balancer.
+
+```azurecli-interactive
+az network nic ip-config address-pool add \
+ --address-pool myBackendPool \
+ --ip-config-name ipconfig-IPv6 \
+ --nic-name myNIC \
+ --resource-group TutorialIPv6NATLB-rg \
+ --lb-name myLoadBalancer
+```
+++
+## Validate outbound connectivity
+
+Connect to the virtual machine with Azure Bastion to verify the IPv4 and IPv6 outbound traffic.
+
+### Obtain IPv4 and IPv6 public IP addresses
+
+Before you can validate outbound connectivity, make not of the IPv4, and IPv6 public IP addresses you created previously. Use the following example to obtain the public IP addresses.
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. In the search box at the top of the portal, enter **Public IP address**. Select **Public IP addresses** in the search results.
+
+1. Select **myPublicIP-NAT**.
+
+1. Make note of the address in **IP address**. In this example, it's **20.230.191.5**.
+
+1. Return to **Public IP addresses**.
+
+1. Select **myPublicIP-IPv6**.
+
+1. Make note of the address in **IP address**. In this example, it's **2603:1030:c02:8::14**.
++
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+Use [az network public-ip show](/cli/azure/network/public-ip#az-network-public-ip-show) to obtain the IPv4 and IPv6 public IP addresses.
+
+### IPv4
+
+```azurecli-interactive
+az network public-ip show \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myPublicIP-NAT \
+ --query ipAddress \
+ --output tsv
+```
+
+```output
+azureuser@Azure:~$ az network public-ip show \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myPublicIP-NAT \
+ --query ipAddress \
+ --output tsv
+40.90.217.214
+```
+
+### IPv6
+
+```azurecli-interactive
+az network public-ip show \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myPublicIP-IPv6 \
+ --query ipAddress \
+ --output tsv
+```
+
+```output
+azureuser@Azure:~$ az network public-ip show \
+ --resource-group TutorialIPv6NATLB-rg \
+ --name myPublicIP-IPv6 \
+ --query ipAddress \
+ --output tsv
+2603:1030:c04:3::4d
+```
+++
+Make note of both IP addresses. Use the IPs to verify the outbound connectivity for each stack.
+
+### Test connectivity
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. Sign-in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+1. Select **myVM**.
+
+1. In the **Overview** of **myVM**, select **Connect** then **Bastion**.
+
+1. Enter the username and password you created when you created the virtual machine.
+
+1. Select **Connect**.
+
+1. On the desktop of **myVM**, open **Microsoft Edge**.
+
+1. To confirm the IPv4 address, enter `http://v4.testmyipv6.com` in the address bar.
+
+1. You should see the IPv4 address displayed. In this example, the IP of **20.230.191.5** is displayed.
+
+ :::image type="content" source="./media/tutorial-dual-stack-outbound-nat-load-balancer/portal-verify-ipv4.png" alt-text="Screenshot of outbound IPv4 public IP address from portal steps.":::
+
+1. In the address bar, enter `http://v6.testmyipv6.com`
+
+1. You should see the IPv6 address displayed. In this example, the IP of **2603:1030:c02:8::14** is displayed.
+
+ :::image type="content" source="./media/tutorial-dual-stack-outbound-nat-load-balancer/portal-verify-ipv6.png" alt-text="Screenshot of outbound IPv6 public IP address from portal steps.":::
+
+1. Close the bastion connection to **myVM**.
++
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+1. Sign-in to the [Azure portal](https://portal.azure.com).
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+1. Select **myVM**.
+
+1. In the **Overview** of **myVM**, select **Connect** then **Bastion**.
+
+1. Enter the username and password you created when you created the virtual machine.
+
+1. Select **Connect**.
+
+1. On the desktop of **myVM**, open **Microsoft Edge**.
+
+1. To confirm the IPv4 address, enter `http://v4.testmyipv6.com` in the address bar.
+
+1. You should see the IPv4 address displayed. In this example, the IP of **40.90.217.214** displayed.
+
+ :::image type="content" source="./media/tutorial-dual-stack-outbound-nat-load-balancer/cli-verify-ipv4.png" alt-text="Screenshot of outbound IPv4 public IP address from CLI steps.":::
+
+1. In the address bar, enter `http://v6.testmyipv6.com`
+
+1. You should see the IPv6 address displayed. In this example, the IP of **2603:1030:c04:3::4d** is displayed.
+
+ :::image type="content" source="./media/tutorial-dual-stack-outbound-nat-load-balancer/cli-verify-ipv6.png" alt-text="Screenshot of outbound IPv6 public IP address from CLI steps.":::
+
+1. Close the bastion connection to **myVM**.
++
+## Clean up resources
+
+When your finished with the resources created in this article, delete the resource group and all of the resources it contains.
+
+# [**Portal**](#tab/dual-stack-outbound-portal)
+
+1. In the search box at the top of the portal, enter **TutorialIPv6NATLB-rg**. Select **TutorialIPv6NATLB-rg** in the search results in **Resource groups**.
+
+1. Select **Delete resource group**.
+
+1. Enter **TutorialIPv6NATLB-rg** for **TYPE THE RESOURCE GROUP NAME** and select **Delete**.
+
+# [**CLI**](#tab/dual-stack-outbound--cli)
+
+Use [az group delete](/cli/azure/group#az-group-delete) to delete the resource group and the resources it contains.
+
+```azurecli-interactive
+az group delete \
+ --name TutorialIPv6NATLB-rg
+```
+++
+## Next steps
+
+Advance to the next article to learn how to:
+> [!div class="nextstepaction"]
+> [Integrate NAT gateway in a hub and spoke network](tutorial-hub-spoke-route-nat.md)
nat-gateway Tutorial Hub Spoke Nat Firewall https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-hub-spoke-nat-firewall.md
+
+ Title: 'Tutorial: Integrate NAT gateway with Azure Firewall in a hub and spoke network'
+
+description: Learn how to integrate a NAT gateway and Azure Firewall in a hub and spoke network.
++++ Last updated : 01/17/2023+++
+# Tutorial: Integrate NAT gateway with Azure Firewall in a hub and spoke network for outbound connectivity
+
+In this tutorial, youΓÇÖll learn how to integrate a NAT gateway with an Azure Firewall in a hub and spoke network
+
+Azure Firewall provides [2,496 SNAT ports per public IP address](../firewall/integrate-with-nat-gateway.md) configured per backend Virtual Machine Scale Set instance (minimum of two instances). You can associate up to 250 public IP addresses to Azure Firewall. Depending on your architecture requirements and traffic patterns, you may require more SNAT ports than what Azure Firewall can provide. You may also require the use of fewer public IPs while also requiring more SNAT ports. A better method for outbound connectivity is to use NAT gateway. NAT gateway provides 64,512 SNAT ports per public IP address and can be used with up to 16 public IP addresses.
+
+NAT gateway can be integrated with Azure Firewall by configuring NAT gateway directly to the Azure Firewall subnet in order to provide a more scalable method of outbound connectivity. For production deployments, a hub and spoke network is recommended, where the firewall is in its own virtual network. The workload servers are peered virtual networks in the same region as the hub virtual network where the firewall resides. In this architectural setup, NAT gateway can provide outbound connectivity from the hub virtual network for all spoke virtual networks peered.
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Create a hub virtual network and deploy an Azure Firewall and Azure Bastion during deployment
+> * Create a NAT gateway and associate it with the firewall subnet in the hub virtual network
+> * Create a spoke virtual network
+> * Create a virtual network peering
+> * Create a route table for the spoke virtual network
+> * Create a firewall policy for the hub virtual network
+> * Create a virtual machine to test the outbound connectivity through the NAT gateway
+
+## Prerequisites
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+## Create the hub virtual network
+
+The hub virtual network contains the firewall subnet that is associated with the Azure Firewall and NAT gateway. Use the following example to create the hub virtual network.
+
+1. Sign in to the [Azure portal](https://portal.azure.com)
+
+2. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+3. Select **+ Create**.
+
+4. In the **Basics** tab of **Create virtual network**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **Create new**. </br> Enter **TutorialNATHubSpokeFW-rg**. </br> Select **OK**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet-Hub**. |
+ | Region | Select **South Central US**. |
+
+5. Select **Next: IP Addresses**.
+
+6. In the **IP Addresses** tab in **IPv4 address space**, select the trash can to delete the address space that is auto populated.
+
+7. In **IPv4 address space** enter **10.1.0.0/16**.
+
+8. Select **+ Add subnet**.
+
+9. In **Add subnet** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Subnet name | Enter **subnet-private**. |
+ | Subnet address range | Enter **10.1.0.0/24**. |
+
+10. Select **Add**.
+
+11. Select **Next: Security**.
+
+12. In the **Security** tab in **BastionHost**, select **Enable**.
+
+13. Enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Bastion name | Enter **myBastion**. |
+ | AzureBastionSubnet address space | Enter **10.1.1.0/26**. |
+ | Public IP address | Select **Create new**. </br> In **Name** enter **myPublicIP-Bastion**. </br> Select **OK**. |
+
+14. In **Firewall** select **Enable**.
+
+15. Enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Firewall name | Enter **myFirewall**. |
+ | Firewall subnet address space | Enter **10.1.2.0/26**. |
+ | Public IP address | Select **Create new**. </br> In **Name** enter **myPublicIP-Firewall**. </br> Select **OK**. |
+
+16. Select **Review + create**.
+
+17. Select **Create**.
+
+It will take a few minutes for the bastion host and firewall to deploy. When the virtual network is created as part of the deployment, you can proceed to the next steps.
+
+## Create the NAT gateway
+
+All outbound internet traffic will traverse the NAT gateway to the internet. Use the following example to create a NAT gateway for the hub and spoke network and associate it with the **AzureFirewallSubnet**.
+
+1. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways** in the search results.
+
+2. Select **+ Create**.
+
+3. In the **Basics** tab of **Create network address translation (NAT) gateway** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpokeFW-rg**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway**. |
+ | Region | Select **South Central US**. |
+ | Availability zone | Select a **Zone** or **No zone**. |
+ | TCP idle timeout (minutes) | Leave the default of **4**. |
+
+ For more information about availability zones, see [NAT gateway and availability zones](nat-availability-zones.md).
+
+5. Select **Next: Outbound IP**.
+
+6. In **Outbound IP** in **Public IP addresses**, select **Create a new public IP address**.
+
+7. Enter **myPublicIP-NAT** in **Name**.
+
+8. Select **OK**.
+
+9. Select **Next: Subnet**.
+
+10. In **Virtual Network** select **myVNet-Hub**.
+
+11. Select **AzureFirewallSubnet** in **Subnet name**.
+
+12. Select **Review + create**.
+
+13. Select **Create**.
+
+## Create spoke virtual network
+
+The spoke virtual network contains the test virtual machine used to test the routing of the internet traffic to the NAT gateway. Use the following example to create the spoke network.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **+ Create**.
+
+3. In the **Basics** tab of **Create virtual network**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpokeFW-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet-Spoke**. |
+ | Region | Select **South Central US**. |
+
+4. Select **Next: IP Addresses**.
+
+5. In the **IP Addresses** tab in **IPv4 address space**, select the trash can to delete the address space that is auto populated.
+
+6. In **IPv4 address space** enter **10.2.0.0/16**.
+
+7. Select **+ Add subnet**.
+
+8. In **Add subnet** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Subnet name | Enter **subnet-private**. |
+ | Subnet address range | Enter **10.2.0.0/24**. |
+
+9. Select **Add**.
+
+10. Select **Review + create**.
+
+12. Select **Create**.
+
+## Create peering between the hub and spoke
+
+A virtual network peering is used to connect the hub to the spoke and the spoke to the hub. Use the following example to create a two-way network peering between the hub and spoke.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **myVNet-Hub**.
+
+3. Select **Peerings** in **Settings**.
+
+4. Select **+ Add**.
+
+5. Enter or select the following information in **Add peering**:
+
+ | Setting | Value |
+ | - | -- |
+ | **This virtual network** | |
+ | Peering link name | Enter **myVNet-Hub-To-myVNet-Spoke**. |
+ | Traffic to remote virtual network | Leave the default of **Allow (default)**. |
+ | Traffic forwarded from remote virtual network | Leave the default of **Allow (default)**. |
+ | Virtual network gateway or Route Server | Leave the default of **None**. |
+ | **Remote virtual network** | |
+ | Peering link name | Enter **myVNet-Spoke-To-myVNet-Hub**. |
+ | Virtual network deployment model | Leave the default of **Resource manager**. |
+ | Subscription | Select your subscription. |
+ | Virtual network | Select **myVNet-Spoke**. |
+ | Traffic to remote virtual network | Leave the default of **Allow (default)**. |
+ | Traffic forwarded from remote virtual network | Leave the default of **Allow (default)**. |
+ | Virtual network gateway or Route Server | Leave the default of **None**. |
+
+6. Select **Add**.
+
+7. Select **Refresh** and verify **Peering status** is **Connected**.
+
+## Create spoke network route table
+
+A route table will force all traffic leaving the spoke virtual network to the hub virtual network. The route table is configured with the private IP address of the Azure Firewall as the virtual appliance.
+
+### Obtain private IP address of firewall
+
+The private IP address of the firewall is needed for the route table created later in this article. Use the following example to obtain the firewall private IP address.
+
+1. In the search box at the top of the portal, enter **Firewall**. Select **Firewall** in the search results.
+
+2. Select **myFirewall**.
+
+3. In the **Overview** of **myFirewall**, note the IP address in the field **Firewall private IP**. The IP address should be **10.1.2.4**.
+
+### Create route table
+
+Create a route table to force all inter-spoke and internet egress traffic through the firewall in the hub virtual network.
+
+1. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+2. Select **+ Create**.
+
+3. In **Create Route table** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpokeFW-rg**. |
+ | **Instance details** | |
+ | Region | Select **South Central US**. |
+ | Name | Enter **myRouteTable-Spoke**. |
+ | Propagate gateway routes | Select **No**. |
+
+4. Select **Review + create**.
+
+5. Select **Create**.
+
+6. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+7. Select **myRouteTable-Spoke**.
+
+8. In **Settings** select **Routes**.
+
+9. Select **+ Add** in **Routes**.
+
+10. Enter or select the following information in **Add route**:
+
+ | Setting | Value |
+ | - | -- |
+ | Route name | Enter **Route-To-Hub**. |
+ | Address prefix destination | Select **IP Addresses**. |
+ | Destination IP addresses/CIDR ranges | Enter **0.0.0.0/0**. |
+ | Next hop type | Select **Virtual appliance**. |
+ | Next hop address | Enter **10.1.2.4**. |
+
+11. Select **Add**.
+
+12. Select **Subnets** in **Settings**.
+
+13. Select **+ Associate**.
+
+14. Enter or select the following information in **Associate subnet**:
+
+ | Setting | Value |
+ | - | -- |
+ | Virtual network | Select **myVNet-Spoke (TutorialNATHubSpokeFW-rg)**. |
+ | Subnet | Select **subnet-private**. |
+
+15. Select **OK**.
+
+## Configure firewall
+
+Traffic from the spoke through the hub must be allowed through and firewall policy and a network rule. Use the following example to create the firewall policy and network rule.
+
+### Create firewall policy
+
+1. In the search box at the top of the portal, enter **Firewall**. Select **Firewalls** in the search results.
+
+2. Select **myFirewall**.
+
+3. In the **Overview** select **Migrate to firewall policy**.
+
+4. In **Migrate to firewall policy** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpokeFW-rg**. |
+ | **Policy details** | |
+ | Name | Enter **myFirewallPolicy**. |
+ | Region | Select **South Central US**. |
+
+5. Select **Review + create**.
+
+6. Select **Create**.
+
+### Configure network rule
+
+1. In the search box at the top of the portal, enter **Firewall**. Select **Firewall Policies** in the search results.
+
+2. Select **myFirewallPolicy**.
+
+3. In **Settings** select **Network rules**.
+
+4. Select **+ Add a rule collection**.
+
+5. In **Add a rule collection** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Name | Enter **SpokeToInternet**. |
+ | Rule collection type | Select **Network**. |
+ | Priority | Enter **100**. |
+ | Rule collection action | Select **Allow**. |
+ | Rule collection group | Select **DefaultNetworkRuleCollectionGroup**. |
+ | Rules | |
+ | Name | Enter **AllowWeb**. |
+ | Source type | **IP Address**. |
+ | Source | Enter **10.2.0.0/24**. |
+ | Protocol | Select **TCP**. |
+ | Destination Ports | Enter **80**,**443**. |
+ | Destination Type | Select **IP Address**. |
+ | Destination | Enter * |
+
+6. Select **Add**.
+
+## Create test virtual machine
+
+A Windows Server 2022 virtual machine is used to test the outbound internet traffic through the NAT gateway. Use the following example to create a Windows Server 2022 virtual machine.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **+ Create** then **Azure virtual machine**.
+
+3. In **Create a virtual machine** enter or select the following information in the **Basics** tab:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpokeFW-rg**. |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM-Spoke**. |
+ | Region | Select **South Central US**. |
+ | Availability options | Select **No infrastructure redundancy required**. |
+ | Security type | Select **Standard**. |
+ | Image | Select **Windows Server 2022 Datacenter - x64 Gen2**. |
+ | VM architecture | Leave the default of **x64**. |
+ | Size | Select a size. |
+ | **Administrator account** | |
+ | Authentication type | Select **Password**. |
+ | Username | Enter a username. |
+ | Password | Enter a password. |
+ | Confirm password | Reenter password. |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None**. |
+
+4. Select **Next: Disks** then **Next: Networking**.
+
+5. In the Networking tab, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Network interface** | |
+ | Virtual network | Select **myVNet-Spoke**. |
+ | Subnet | Select **subnet-private (10.2.0.0/24)**. |
+ | Public IP | Select **None**. |
+
+6. Leave the rest of the options at the defaults and select **Review + create**.
+
+7. Select **Create**.
+
+## Test NAT gateway
+
+You'll connect to the Windows Server 2022 virtual machines you created in the previous steps to verify that the outbound internet traffic is leaving the NAT gateway.
+
+### Obtain NAT gateway public IP address
+
+Obtain the NAT gateway public IP address for verification of the steps later in the article.
+
+1. In the search box at the top of the portal, enter **Public IP**. Select **Public IP addresses** in the search results.
+
+2. Select **myPublic-NAT**.
+
+3. Make note of value in **IP address**. The example used in this article is **20.225.88.213**.
+
+### Test NAT gateway from spoke
+
+Use Microsoft Edge on the Windows Server 2022 virtual machine to connect to https://whatsmyip.com to verify the functionality of the NAT gateway.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **myVM-Spoke**.
+
+3. Select **Connect** then **Bastion**.
+
+4. Enter the username and password you entered when the virtual machine was created.
+
+5. Select **Connect**.
+
+6. Open **Microsoft Edge** when the desktop finishes loading.
+
+7. In the address bar, enter **https://whatsmyip.com**.
+
+8. Verify the outbound IP address displayed is the same as the IP of the NAT gateway you obtained previously.
+
+ :::image type="content" source="./media/tutorial-hub-spoke-nat-firewall/outbound-ip-address.png" alt-text="Screenshot of outbound IP address.":::
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete the created resources with the following steps:
+
+1. In the search box at the top of the portal, enter **Resource group**. Select **Resource groups** in the search results.
+
+2. Select **TutorialNATHubSpokeFW-rg**.
+
+3. In the **Overview** of **TutorialNATHubSpokeFW-rg**, select **Delete resource group**.
+
+4. In **TYPE THE RESOURCE GROUP NAME:**, enter **TutorialNATHubSpokeFW-rg**.
+
+5. Select **Delete**.
+
+## Next steps
+
+Advance to the next article to learn how to integrate a NAT gateway with an Azure Load Balancer:
+> [!div class="nextstepaction"]
+> [Integrate NAT gateway with an internal load balancer](tutorial-nat-gateway-load-balancer-internal-portal.md)
nat-gateway Tutorial Hub Spoke Route Nat https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-hub-spoke-route-nat.md
+
+ Title: 'Tutorial: Use a NAT gateway with a hub and spoke network'
+
+description: Learn how to integrate a NAT gateway into a hub and spoke network with a network virtual appliance.
++++ Last updated : 01/17/2023+++
+# Tutorial: Use a NAT gateway with a hub and spoke network
+
+A hub and spoke network is one of the building blocks of a highly available multiple location network infrastructure. The most common deployment of a hub and spoke network is done with the intention of routing all inter-spoke and outbound internet traffic through the central hub. The purpose is to inspect all of the traffic traversing the network with a Network Virtual Appliance (NVA) for security scanning and packet inspection.
+
+For outbound traffic to the internet, the network virtual appliance would typically have one network interface with an assigned public IP address. The NVA after inspecting the outbound traffic forwards the traffic out the public interface and to the internet. Azure NAT Gateway eliminates the need for the public IP address assigned to the NVA. Associating a NAT gateway with the public subnet of the NVA changes the routing for the public interface to route all outbound internet traffic through the NAT gateway. The elimination of the public IP address increases security and allows for the scaling of outbound source network address translation (SNAT) with multiple public IP addresses and or public IP prefixes.
+
+> [!IMPORTANT]
+> The NVA used in this article is for demonstration purposes only and is simulated with an Ubuntu virtual machine. The solution doesn't include a load balancer for high availability of the NVA deployment. Replace the Ubuntu virtual machine in this article with an NVA of your choice. Consult the vendor of the chosen NVA for routing and configuration instructions. A load balancer and availability zones is recommended for a highly available NVA infrastructure.
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Create a NAT gateway.
+> * Create a hub and spoke virtual network.
+> * Create a simulated Network Virtual Appliance (NVA).
+> * Force all traffic from the spokes through the hub.
+> * Force all internet traffic in the hub and the spokes out the NAT gateway.
+> * Test the NAT gateway and inter-spoke routing.
+
+## Prerequisites
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+## Create a NAT gateway
+
+All outbound internet traffic will traverse the NAT gateway to the internet. Use the following example to create a NAT gateway for the hub and spoke network.
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+2. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways** in the search results.
+
+3. Select **+ Create**.
+
+4. In the **Basics** tab of **Create network address translation (NAT) gateway** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **Create new**. </br> Enter **TutorialNATHubSpoke-rg** in **Name**. </br> Select **OK**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway**. |
+ | Region | Select **South Central US**. |
+ | Availability zone | Select a **Zone** or **No zone**. |
+ | TCP idle timeout (minutes) | Leave the default of **4**. |
+
+5. Select **Next: Outbound IP**.
+
+6. In **Outbound IP** in **Public IP addresses**, select **Create a new public IP address**.
+
+7. Enter **myPublicIP-NAT** in **Name**.
+
+8. Select **OK**.
+
+9. Select **Review + create**.
+
+10. Select **Create**.
+
+## Create hub virtual network
+
+The hub virtual network is the central network of the solution. The hub network contains the NVA appliance and a public and private subnet. The NAT gateway is assigned to the public subnet during the creation of the virtual network. An Azure Bastion host is configured as part of the following example. The bastion host is used to securely connect to the NVA virtual machine and the test virtual machines deployed in the spokes later in the article.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **+ Create**.
+
+3. In the **Basics** tab of **Create virtual network**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet-Hub**. |
+ | Region | Select **South Central US**. |
+
+4. Select **Next: IP Addresses**.
+
+5. In the **IP Addresses** tab in **IPv4 address space**, select the trash can to delete the address space that is auto populated.
+
+6. In **IPv4 address space** enter **10.1.0.0/16**.
+
+7. Select **+ Add subnet**.
+
+8. In **Add subnet** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Subnet name | Enter **subnet-private**. |
+ | Subnet address range | Enter **10.1.0.0/24**. |
+
+9. Select **Add**.
+
+10. Select **+ Add subnet**.
+
+11. In **Add subnet** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Subnet name | Enter **subnet-public**. |
+ | Subnet address range | Enter **10.1.253.0/28**. |
+ | **NAT GATEWAY** | |
+ | NAT gateway | Select **myNATgateway**. |
+
+12. Select **Add**.
+
+13. Select **Next: Security**.
+
+14. In the **Security** tab in **BastionHost**, select **Enable**.
+
+15. Enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Bastion name | Enter **myBastion**. |
+ | AzureBastionSubnet address space | Enter **10.1.1.0/26**. |
+ | Public IP address | Select **Create new**. </br> In **Name** enter **myPublicIP-Bastion**. </br> Select **OK**. |
+
+16. Select **Review + create**.
+
+17. Select **Create**.
+
+It will take a few minutes for the bastion host to deploy. When the virtual network is created as part of the deployment, you can proceed to the next steps.
+
+## Create simulated NVA virtual machine
+
+The simulated NVA will act as a virtual appliance to route all traffic between the spokes and hub and traffic outbound to the internet. An Ubuntu virtual machine is used for the simulated NVA. Use the following example to create the simulated NVA and configure the network interfaces.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **+ Create** then **Azure virtual machine**.
+
+3. In **Create a virtual machine** enter or select the following information in the **Basics** tab:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM-NVA**. |
+ | Region | Select **(US) South Central US**. |
+ | Availability options | Select **No infrastructure redundancy required**. |
+ | Security type | Select **Standard**. |
+ | Image | Select **Ubuntu Server 20.04 LTS - x64 Gen2**. |
+ | VM architecture | Leave the default of **x64**. |
+ | Size | Select a size. |
+ | **Administrator account** | |
+ | Authentication type | Select **Password**. |
+ | Username | Enter a username. |
+ | Password | Enter a password. |
+ | Confirm password | Reenter password. |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None**. |
+
+4. Select **Next: Disks** then **Next: Networking**.
+
+5. In the Networking tab, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Network interface** | |
+ | Virtual network | Select **myVNet-Hub**. |
+ | Subnet | Select **subnet-public**. |
+ | Public IP | Select **None**. |
+
+6. Leave the rest of the options at the defaults and select **Review + create**.
+
+7. Select **Create**.
+
+### Configure virtual machine network interfaces
+
+The IP configuration of the primary network interface of the virtual machine is set to dynamic by default. Use the following example to change the primary network interface IP configuration to static and add a secondary network interface for the private interface of the NVA.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **myVM-NVA**.
+
+3. In the **Overview** select **Stop** if the virtual machine is running.
+
+4. Select **Networking** in **Settings**.
+
+5. In **Networking** select the network interface name next to **Network Interface:**. The interface name is the virtual machine name and random numbers and letters. In this example, the interface name is **myvm-nva271**.
+
+6. In the network interface properties, select **IP configurations** in **Settings**.
+
+7. In **IP forwarding** select **Enabled**.
+
+8. Select **Save**.
+
+9. When the save action completes, select **ipconfig1**.
+
+10. In **Assignment** in **ipconfig1** select **Static**.
+
+11. In **IP address** enter **10.1.253.10**.
+
+12. Select **Save**.
+
+13. When the save action completes, return to the networking configuration for **myVM-NVA**.
+
+14. In **Networking** of **myVM-NVA** select **Attach network interface**.
+
+15. Select **Create and attach network interface**.
+
+16. In **Create network interface** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Network interface** | |
+ | Name | Enter **myVM-NVA-private-nic**. |
+ | Subnet | Select **subnet-private (10.1.0.0/24)**. |
+ | NIC network security group | Select **Advanced**. |
+ | Configure network security group | Select **myVM-VNA-nsg**. |
+ | Private IP address assignment | Select **Static**. |
+ | Private IP address | Enter **10.1.0.10**. |
+
+17. Select **Create**.
+
+### Configure virtual machine software
+
+The routing for the simulated NVA uses IP tables and internal NAT in the Ubuntu virtual machine. Connect to the NVA virtual machine with Azure Bastion to configure IP tables and the routing configuration.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **myVM-NVA**.
+
+3. Start **myVM-NVA**.
+
+4. When the virtual machine is completed booting, continue with the next steps.
+
+5. Select **Connect** then **Bastion**.
+
+6. Enter the username and password you entered when the virtual machine was created.
+
+7. Select **Connect**.
+
+8. Enter the following information at the prompt of the virtual machine to enable IP forwarding:
+
+ ```bash
+ sudo vim /etc/sysctl.conf
+ ```
+
+9. In the Vim editor, remove the **`#`** from the line **`net.ipv4.ip_forward=1`**:
+
+ Press the **Insert** key.
+
+ ```bash
+ # Uncomment the next line to enable packet forwarding for IPv4
+ net.ipv4.ip_forward=1
+ ```
+
+ Press the **Esc** key.
+
+ Enter **`:wq`** and press **Enter**.
+
+10. Enter the following information to enable internal NAT in the virtual machine:
+
+ ```bash
+ sudo iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
+ sudo apt-get update
+ sudo apt install iptables-persistent
+ ```
+
+ Select **Yes** twice.
+
+ ```bash
+ sudo su
+ iptables-save > /etc/iptables/rules.v4
+ exit
+ ```
+
+11. Use Vim to edit the configuration with the following information:
+
+ ```bash
+ sudo vim /etc/rc.local
+ ```
+
+ Press the **Insert** key.
+
+ Add the following line to the configuration file:
+
+ ```bash
+ /sbin/iptables-restore < /etc/iptables/rules.v4
+ ```
+
+ Press the **Esc** key.
+
+ Enter **`:wq`** and press **Enter**.
+
+12. Reboot the virtual machine:
+
+ ```bash
+ sudo reboot
+ ```
+
+## Create hub network route table
+
+Route tables are used to overwrite Azure's default routing. Create a route table to force all traffic within the hub private subnet through the simulated NVA.
+
+1. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+2. Select **+ Create**.
+
+3. In **Create Route table** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Region | Select **South Central US**. |
+ | Name | Enter **myRouteTable-NAT-Hub**. |
+ | Propagate gateway routes | Leave the default of **Yes**. |
+
+4. Select **Review + create**.
+
+5. Select **Create**.
+
+6. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+7. Select **myRouteTable-NAT-Hub**.
+
+8. In **Settings** select **Routes**.
+
+9. Select **+ Add** in **Routes**.
+
+10. Enter or select the following information in **Add route**:
+
+ | Setting | Value |
+ | - | -- |
+ | Route name | Enter **default-via-NAT-Hub**. |
+ | Address prefix destination | Select **IP Addresses**. |
+ | Destination IP addresses/CIDR ranges | Enter **0.0.0.0/0**. |
+ | Next hop type | Select **Virtual appliance**. |
+ | Next hop address | Enter **10.1.0.10**. </br> **_This is the IP address you added to the private interface of the NVA in the previous steps._**. |
+
+11. Select **Add**.
+
+12. Select **Subnets** in **Settings**.
+
+13. Select **+ Associate**.
+
+14. Enter or select the following information in **Associate subnet**:
+
+ | Setting | Value |
+ | - | -- |
+ | Virtual network | Select **myVNet-Hub (TutorialNATHubSpoke-rg)**. |
+ | Subnet | Select **subnet-private**. |
+
+15. Select **OK**.
+
+## Create spoke one virtual network
+
+Create another virtual network in a different region for the first spoke of the hub and spoke network.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **+ Create**.
+
+3. In the **Basics** tab of **Create virtual network**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet-Spoke-1**. |
+ | Region | Select **East US 2**. |
+
+4. Select **Next: IP Addresses**.
+
+5. In the **IP Addresses** tab in **IPv4 address space**, select the trash can to delete the address space that is auto populated.
+
+6. In **IPv4 address space** enter **10.2.0.0/16**.
+
+7. Select **+ Add subnet**.
+
+8. In **Add subnet** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Subnet name | Enter **subnet-private**. |
+ | Subnet address range | Enter **10.2.0.0/24**. |
+
+9. Select **Add**.
+
+10. Select **Review + create**.
+
+11. Select **Create**.
+
+## Create peering between hub and spoke one
+
+A virtual network peering is used to connect the hub to spoke one and spoke one to the hub. Use the following example to create a two-way network peering between the hub and spoke one.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **myVNet-Hub**.
+
+3. Select **Peerings** in **Settings**.
+
+4. Select **+ Add**.
+
+5. Enter or select the following information in **Add peering**:
+
+ | Setting | Value |
+ | - | -- |
+ | **This virtual network** | |
+ | Peering link name | Enter **myVNet-Hub-To-myVNet-Spoke-1**. |
+ | Traffic to remote virtual network | Leave the default of **Allow (default)**. |
+ | Traffic forwarded from remote virtual network | Leave the default of **Allow (default)**. |
+ | Virtual network gateway or Route Server | Leave the default of **None**. |
+ | **Remote virtual network** | |
+ | Peering link name | Enter **myVNet-Spoke-1-To-myVNet-Hub**. |
+ | Virtual network deployment model | Leave the default of **Resource manager**. |
+ | Subscription | Select your subscription. |
+ | Virtual network | Select **myVNet-Spoke-1**. |
+ | Traffic to remote virtual network | Leave the default of **Allow (default)**. |
+ | Traffic forwarded from remote virtual network | Leave the default of **Allow (default)**. |
+ | Virtual network gateway or Route Server | Leave the default of **None**. |
+
+6. Select **Add**.
+
+7. Select **Refresh** and verify **Peering status** is **Connected**.
+
+## Create spoke one network route table
+
+Create a route table to force all inter-interspoke and internet egress traffic through the simulated NVA in the hub virtual network.
+
+1. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+2. Select **+ Create**.
+
+3. In **Create Route table** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Region | Select **East US 2**. |
+ | Name | Enter **myRouteTable-NAT-Spoke-1**. |
+ | Propagate gateway routes | Leave the default of **Yes**. |
+
+4. Select **Review + create**.
+
+5. Select **Create**.
+
+6. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+7. Select **myRouteTable-NAT-Spoke-1**.
+
+8. In **Settings** select **Routes**.
+
+9. Select **+ Add** in **Routes**.
+
+10. Enter or select the following information in **Add route**:
+
+ | Setting | Value |
+ | - | -- |
+ | Route name | Enter **default-via-NAT-Spoke-1**. |
+ | Address prefix destination | Select **IP Addresses**. |
+ | Destination IP addresses/CIDR ranges | Enter **0.0.0.0/0**. |
+ | Next hop type | Select **Virtual appliance**. |
+ | Next hop address | Enter **10.1.0.10**. </br> **_This is the IP address you added to the private interface of the NVA in the previous steps._**. |
+
+11. Select **Add**.
+
+12. Select **Subnets** in **Settings**.
+
+13. Select **+ Associate**.
+
+14. Enter or select the following information in **Associate subnet**:
+
+ | Setting | Value |
+ | - | -- |
+ | Virtual network | Select **myVNet-Spoke-1 (TutorialNATHubSpoke-rg)**. |
+ | Subnet | Select **subnet-private**. |
+
+15. Select **OK**.
+
+## Create spoke one test virtual machine
+
+A Windows Server 2022 virtual machine is used to test the outbound internet traffic through the NAT gateway and inter-spoke traffic in the hub and spoke network. Use the following example to create a Windows Server 2022 virtual machine.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **+ Create** then **Azure virtual machine**.
+
+3. In **Create a virtual machine** enter or select the following information in the **Basics** tab:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM-Spoke-1**. |
+ | Region | Select **(US) East US 2**. |
+ | Availability options | Select **No infrastructure redundancy required**. |
+ | Security type | Select **Standard**. |
+ | Image | Select **Windows Server 2022 Datacenter - x64 Gen2**. |
+ | VM architecture | Leave the default of **x64**. |
+ | Size | Select a size. |
+ | **Administrator account** | |
+ | Authentication type | Select **Password**. |
+ | Username | Enter a username. |
+ | Password | Enter a password. |
+ | Confirm password | Reenter password. |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None**. |
+
+4. Select **Next: Disks** then **Next: Networking**.
+
+5. In the Networking tab, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Network interface** | |
+ | Virtual network | Select **myVNet-Spoke-1**. |
+ | Subnet | Select **subnet-private (10.2.0.0/24)**. |
+ | Public IP | Select **None**. |
+ | NIC network security group | Select **Basic**. |
+ | Public inbound ports | Select **Allow selected ports**. |
+ | Select inbound ports | Select **HTTP (80)**. </br> Select **RDP (3389)**. |
+
+6. Leave the rest of the options at the defaults and select **Review + create**.
+
+7. Select **Create**.
+
+## Create the second spoke virtual network
+
+Create the second virtual network for the second spoke of the hub and spoke network.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **+ Create**.
+
+3. In the **Basics** tab of **Create virtual network**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet-Spoke-2**. |
+ | Region | Select **West US 2**. |
+
+4. Select **Next: IP Addresses**.
+
+5. In the **IP Addresses** tab in **IPv4 address space**, select the trash can to delete the address space that is auto populated.
+
+6. In **IPv4 address space** enter **10.3.0.0/16**.
+
+7. Select **+ Add subnet**.
+
+8. In **Add subnet** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Subnet name | Enter **subnet-private**. |
+ | Subnet address range | Enter **10.3.0.0/24**. |
+
+9. Select **Add**.
+
+10. Select **Review + create**.
+
+11. Select **Create**.
+
+## Create peering between hub and spoke two
+
+Create a two-way virtual network peer between the hub and spoke two.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **myVNet-Hub**.
+
+3. Select **Peerings** in **Settings**.
+
+4. Select **+ Add**.
+
+5. Enter or select the following information in **Add peering**:
+
+ | Setting | Value |
+ | - | -- |
+ | **This virtual network** | |
+ | Peering link name | Enter **myVNet-Hub-To-myVNet-Spoke-2**. |
+ | Traffic to remote virtual network | Leave the default of **Allow (default)**. |
+ | Traffic forwarded from remote virtual network | Leave the default of **Allow (default)**. |
+ | Virtual network gateway or Route Server | Leave the default of **None**. |
+ | **Remote virtual network** | |
+ | Peering link name | Enter **myVNet-Spoke-2-To-myVNet-Hub**. |
+ | Virtual network deployment model | Leave the default of **Resource manager**. |
+ | Subscription | Select your subscription. |
+ | Virtual network | Select **myVNet-Spoke-2**. |
+ | Traffic to remote virtual network | Leave the default of **Allow (default)**. |
+ | Traffic forwarded from remote virtual network | Leave the default of **Allow (default)**. |
+ | Virtual network gateway or Route Server | Leave the default of **None**. |
+
+6. Select **Add**.
+
+7. Select **Refresh** and verify **Peering status** is **Connected**.
+
+## Create spoke two network route table
+
+Create a route table to force all outbound internet and inter-spoke traffic through the simulated NVA in the hub virtual network.
+
+1. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+2. Select **+ Create**.
+
+3. In **Create Route table** enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Region | Select **West US 2**. |
+ | Name | Enter **myRouteTable-NAT-Spoke-2**. |
+ | Propagate gateway routes | Leave the default of **Yes**. |
+
+4. Select **Review + create**.
+
+5. Select **Create**.
+
+6. In the search box at the top of the portal, enter **Route table**. Select **Route tables** in the search results.
+
+7. Select **myRouteTable-NAT-Spoke-2**.
+
+8. In **Settings** select **Routes**.
+
+9. Select **+ Add** in **Routes**.
+
+10. Enter or select the following information in **Add route**:
+
+ | Setting | Value |
+ | - | -- |
+ | Route name | Enter **default-via-NAT-Spoke-2**. |
+ | Address prefix destination | Select **IP Addresses**. |
+ | Destination IP addresses/CIDR ranges | Enter **0.0.0.0/0**. |
+ | Next hop type | Select **Virtual appliance**. |
+ | Next hop address | Enter **10.1.0.10**. </br> **_This is the IP address you added to the private interface of the NVA in the previous steps._**. |
+
+11. Select **Add**.
+
+12. Select **Subnets** in **Settings**.
+
+13. Select **+ Associate**.
+
+14. Enter or select the following information in **Associate subnet**:
+
+ | Setting | Value |
+ | - | -- |
+ | Virtual network | Select **myVNet-Spoke-2 (TutorialNATHubSpoke-rg)**. |
+ | Subnet | Select **subnet-private**. |
+
+15. Select **OK**.
+
+## Create spoke two test virtual machine
+
+Create a Windows Server 2022 virtual machine for the test virtual machine in spoke two.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **+ Create** then **Azure virtual machine**.
+
+3. In **Create a virtual machine** enter or select the following information in the **Basics** tab:
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorialNATHubSpoke-rg**. |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM-Spoke-2**. |
+ | Region | Select **(US) West US 2**. |
+ | Availability options | Select **No infrastructure redundancy required**. |
+ | Security type | Select **Standard**. |
+ | Image | Select **Windows Server 2022 Datacenter - x64 Gen2**. |
+ | VM architecture | Leave the default of **x64**. |
+ | Size | Select a size. |
+ | **Administrator account** | |
+ | Authentication type | Select **Password**. |
+ | Username | Enter a username. |
+ | Password | Enter a password. |
+ | Confirm password | Reenter password. |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None**. |
+
+4. Select **Next: Disks** then **Next: Networking**.
+
+5. In the Networking tab, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | **Network interface** | |
+ | Virtual network | Select **myVNet-Spoke-2**. |
+ | Subnet | Select **subnet-private (10.3.0.0/24)**. |
+ | Public IP | Select **None**. |
+ | NIC network security group | Select **Basic**. |
+ | Public inbound ports | Select **Allow selected ports**. |
+ | Select inbound ports | Select **HTTP (80)**. </br> Select **RDP (3389)**. |
+
+6. Leave the rest of the options at the defaults and select **Review + create**.
+
+7. Select **Create**.
+
+## Test NAT gateway
+
+You'll connect to the Windows Server 2022 virtual machines you created in the previous steps to verify that the outbound internet traffic is leaving the NAT gateway.
+
+### Obtain NAT gateway public IP address
+
+Obtain the NAT gateway public IP address for verification of the steps later in the article.
+
+1. In the search box at the top of the portal, enter **Public IP**. Select **Public IP addresses** in the search results.
+
+2. Select **myPublic-NAT**.
+
+3. Make note of value in **IP address**. The example used in this article is **52.153.224.79**.
+
+### Test NAT gateway from spoke one
+
+Use Microsoft Edge on the Windows Server 2022 virtual machine to connect to https://whatsmyip.com to verify the functionality of the NAT gateway.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **myVM-Spoke-1**.
+
+3. Select **Connect** then **Bastion**.
+
+4. Enter the username and password you entered when the virtual machine was created.
+
+5. Select **Connect**.
+
+6. Open **Microsoft Edge** when the desktop finishes loading.
+
+7. In the address bar, enter **https://whatsmyip.com**.
+
+8. Verify the outbound IP address displayed is the same as the IP of the NAT gateway you obtained previously.
+
+ :::image type="content" source="./media/tutorial-hub-spoke-route-nat/outbound-ip-address.png" alt-text="Screenshot of outbound IP address.":::
+
+9. Open **Windows PowerShell**.
+
+10. Use the following example to install IIS. IIS will be used later to test inter-spoke routing.
+
+ ```powershell
+ Install-WindowsFeature Web-Server
+ ```
+
+11. Leave the bastion connection open to **myVM-Spoke-1**.
+
+### Test NAT gateway from spoke two
+
+Use Microsoft Edge on the Windows Server 2022 virtual machine to connect to https://whatsmyip.com to verify the functionality of the NAT gateway.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **myVM-Spoke-2**.
+
+3. Select **Connect** then **Bastion**.
+
+4. Enter the username and password you entered when the virtual machine was created.
+
+5. Select **Connect**.
+
+6. Open **Microsoft Edge** when the desktop finishes loading.
+
+7. In the address bar, enter **https://whatsmyip.com**.
+
+8. Verify the outbound IP address displayed is the same as the IP of the NAT gateway you obtained previously.
+
+ :::image type="content" source="./media/tutorial-hub-spoke-route-nat/outbound-ip-address.png" alt-text="Screenshot of outbound IP address.":::
+
+9. Open **Windows PowerShell**.
+
+10. Use the following example to install IIS. IIS will be used later to test inter-spoke routing.
+
+ ```powershell
+ Install-WindowsFeature Web-Server
+ ```
+
+11. Leave the bastion connection open to **myVM-Spoke-2**.
+
+## Test routing between the spokes
+
+Traffic from spoke one to spoke two and spoke two to spoke one will route through the simulated NVA in the hub virtual network. Use the following examples to verify the routing between spokes of the hub and spoke network.
+
+### Test routing from spoke one to spoke two
+
+Use Microsoft Edge to connect to the web server on **myVM-Spoke-2** you installed in the previous steps.
+
+1. Return to the open bastion connection to **myVM-Spoke-1**.
+
+2. Open **Microsoft Edge** if it's not open.
+
+3. In the address bar, enter **10.3.0.4**.
+
+4. Verify the default IIS page is displayed from **myVM-Spoke-2**.
+
+ :::image type="content" source="./media/tutorial-hub-spoke-route-nat/iis-myvm-spoke-1.png" alt-text="Screenshot of default IIS page on myVM-Spoke-1.":::
+
+5. Close the bastion connection to **myVM-Spoke-1**.
+
+### Test routing from spoke two to spoke one
+
+Use Microsoft Edge to connect to the web server on **myVM-Spoke-1** you installed in the previous steps.
+
+1. Return to the open bastion connection to **myVM-Spoke-2**.
+
+2. Open **Microsoft Edge** if it's not open.
+
+3. In the address bar, enter **10.2.0.4**.
+
+4. Verify the default IIS page is displayed from **myVM-Spoke-1**.
+
+ :::image type="content" source="./media/tutorial-hub-spoke-route-nat/iis-myvm-spoke-2.png" alt-text="Screenshot of default IIS page on myVM-Spoke-2.":::
+
+5. Close the bastion connection to **myVM-Spoke-1**.
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete the created resources with the following steps:
+
+1. In the search box at the top of the portal, enter **Resource group**. Select **Resource groups** in the search results.
+
+2. Select **myResourceGroup**.
+
+3. In the **Overview** of **myResourceGroup**, select **Delete resource group**.
+
+4. In **TYPE THE RESOURCE GROUP NAME:**, enter **TutorialNATHubSpoke-rg**.
+
+5. Select **Delete**.
+
+## Next steps
+
+Advance to the next article to learn how to use an Azure Gateway Load Balancer for highly available network virtual appliances:
+> [!div class="nextstepaction"]
+> [Gateway Load Balancer](../load-balancer/gateway-overview.md)
nat-gateway Tutorial Migrate Ilip Nat https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-migrate-ilip-nat.md
+
+ Title: 'Tutorial: Migrate a virtual machine public IP address to NAT gateway'
+
+description: Learn how to migrate your virtual machine public IP to a NAT gateway.
++++ Last updated : 5/25/2022+++
+# Tutorial: Migrate a virtual machine public IP address to Azure NAT Gateway
+
+In this article, you'll learn how to migrate your virtual machine's public IP address to a NAT gateway. You'll learn how to remove the IP address from the virtual machine. You'll reuse the IP address from the virtual machine for the NAT gateway.
+
+Azure NAT Gateway is the recommended method for outbound connectivity. Azure NAT Gateway is a fully managed and highly resilient Network Address Translation (NAT) service. A NAT gateway doesn't have the same limitations of SNAT port exhaustion as default outbound access. A NAT gateway replaces the need for a virtual machine to have a public IP address to have outbound connectivity.
+
+For more information about Azure NAT Gateway, see [What is Azure NAT Gateway](nat-overview.md)
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Remove the public IP address from the virtual machine.
+> * Associate the public IP address from the virtual machine with a NAT gateway.
+
+## Prerequisites
+
+* An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+* An Azure Virtual Machine with a public IP address assigned to its network interface. For more information on creating a virtual machine with a public IP, see [Quickstart: Create a Windows virtual machine in the Azure portal](../virtual-machines/windows/quick-create-portal.md).
+
+ * For the purposes of this article, the example virtual machine is named **myVM**. The example public IP address is named **myPublicIP**.
+
+> [!NOTE]
+> Removal of the public IP address prevents direct connections to the virtual machine from the internet. RDP or SSH access won't function to the virtual machine after you complete this migration. To securely manage virtual machines in your subscription, use Azure Bastion. For more information on Azure Bastion, see [What is Azure Bastion?](../bastion/bastion-overview.md).
+
+## Remove public IP from virtual machine
+
+In this section, you'll learn how to remove the public IP address from the virtual machine.
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+2. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines**.
+
+3. In **Virtual machines**, select **myVM** or your virtual machine.
+
+4. In the **Overview** of **myVM**, select **Public IP address**.
+
+ :::image type="content" source="./media/tutorial-migrate-ilip-nat/select-public-ip.png" alt-text="Screenshot of virtual machines public IP address.":::
+
+5. In **myPublicIP**, select the **Overview** page in the left-hand column.
+
+6. In **Overview**, select **Dissociate**.
+
+ :::image type="content" source="./media/tutorial-migrate-ilip-nat/remove-public-ip.png" alt-text="Screenshot of virtual machines public IP address overview and removal of IP address.":::
+
+7. Select **Yes** in **Dissociate public IP address**.
+
+### (Optional) Upgrade IP address
+
+The NAT gateway resource requires a standard SKU public IP address. In this section, you'll upgrade the IP you removed from the virtual machine in the previous section. If the IP address you removed is already a standard SKU public IP, you can proceed to the next section.
+
+1. In the search box at the top of the portal, enter **Public IP**. Select **Public IP addresses**.
+
+2. In **Public IP addresses**, select **myPublicIP** or your basic SKU IP address.
+
+3. In the **Overview** of **myPublicIP**, select the IP address upgrade banner.
+
+ :::image type="content" source="./media/tutorial-migrate-ilip-nat/select-upgrade-banner.png" alt-text="Screenshot of public IP address upgrade banner.":::
+
+4. In **Upgrade to Standard SKU**, select the box next to **I acknowledge**. Select the **Upgrade** button.
+
+ :::image type="content" source="./media/tutorial-migrate-ilip-nat/upgrade-public-ip.png" alt-text="Screenshot of upgrade public IP address selection.":::
+
+5. When the upgrade is complete, proceed to the next section.
+## Create NAT gateway
+
+In this section, youΓÇÖll create a NAT gateway with the IP address you previously removed from the virtual machine. You'll assign the NAT gateway to your pre-created subnet within your virtual network. The subnet name for this example is **default**.
+
+1. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways**.
+
+2. In **NAT gateways**, select **+ Create**.
+
+3. In **Create network address translation (NAT) gateway**, enter or select the following information in the **Basics** tab.
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **Create new**. </br> Enter **myResourceGroup**. </br> Select **OK**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway**. |
+ | Region | Select the region of your virtual network. In this example, it's **West US 2**. |
+ | Availability zone | Leave the default of **None**. |
+ | Idle timeout (minutes) | Enter **10**. |
+
+4. Select the **Outbound IP** tab, or select **Next: Outbound IP** at the bottom of the page.
+
+5. In **Public IP addresses** in the **Outbound IP** tab, select the IP address from the previous section in **Public IP addresses**. In this example, it's **myPublicIP**.
+
+6. Select the **Subnet** tab, or select **Next: Subnet** at the bottom of the page.
+
+7. In the pull-down box for **Virtual network**, select your virtual network.
+
+8. In **Subnet name**, select the checkbox for your subnet. In this example, it's **default**.
+
+9. Select the **Review + create** tab, or select **Review + create** at the bottom of the page.
+
+10. Select **Create**.
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete the NAT gateway with the following steps:
+
+1. From the left-hand menu, select **Resource groups**.
+
+2. Select the **myResourceGroup** resource group.
+
+3. Select **Delete resource group**.
+
+4. Enter **myResourceGroup** and select **Delete**.
+
+## Next steps
+
+In this article, you learned how to:
+
+* Remove a public IP address from a virtual machine.
+
+* Create a NAT gateway and use the public IP address from the virtual machine for the NAT gateway resource.
+
+Any virtual machine created within this subnet won't require a public IP address and will automatically have outbound connectivity. For more information about NAT gateway and the connectivity benefits it provides, see [Design virtual networks with NAT gateway](nat-gateway-resource.md).
+
+Advance to the next article to learn how to migrate default outbound access to Azure NAT Gateway:
+> [!div class="nextstepaction"]
+> [Migrate outbound access to NAT gateway](tutorial-migrate-outbound-nat.md)
nat-gateway Tutorial Migrate Outbound Nat https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-migrate-outbound-nat.md
+
+ Title: 'Tutorial: Migrate outbound access to NAT gateway'
+
+description: Learn how to migrate outbound access in your virtual network to a NAT gateway.
++++ Last updated : 5/25/2022+++
+# Tutorial: Migrate outbound access to Azure NAT Gateway
+
+In this article, you'll learn how to migrate your outbound connectivity from [default outbound access](../virtual-network/ip-services/default-outbound-access.md) to a NAT gateway. You'll learn how to change your outbound connectivity from load balancer outbound rules to a NAT gateway. You'll reuse the IP address from the outbound rule configuration for the NAT gateway.
+
+Azure NAT Gateway is the recommended method for outbound connectivity. A NAT gateway is a fully managed and highly resilient Network Address Translation (NAT) service. A NAT gateway doesn't have the same limitations of SNAT port exhaustion as default outbound access. A NAT gateway replaces the need for outbound rules in a load balancer for outbound connectivity.
+
+For more information about Azure NAT Gateway, see [What is Azure NAT Gateway](nat-overview.md)
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Migrate default outbound access to a NAT gateway.
+> * Migrate load balancer outbound connectivity and IP address to a NAT gateway.
+
+## Prerequisites
+
+* An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+* A standard public load balancer in your subscription. The load balancer must have a separate frontend IP address and outbound rules configured. For more information on creating an Azure Load Balancer, see [Quickstart: Create a public load balancer to load balance VMs using the Azure portal](../load-balancer/quickstart-load-balancer-standard-public-portal.md)
+ * The load balancer name used in the examples is **myLoadBalancer**.
+
+> [!NOTE]
+> Azure NAT Gateway provides outbound connectivity for standard internal load balancers. For more information on integrating a NAT gateway with your internal load balancers, see [Tutorial: Integrate a NAT gateway with an internal load balancer using Azure portal](tutorial-nat-gateway-load-balancer-internal-portal.md).
+
+## Migrate default outbound access
+
+In this section, youΓÇÖll learn how to change your outbound connectivity method from default outbound access to a NAT gateway.
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+2. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways**.
+
+3. In **NAT gateways**, select **+ Create**.
+
+4. In **Create network address translation (NAT) gateway**, enter or select the following information in the **Basics** tab.
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **Create new**. </br> Enter **myResourceGroup**. </br> Select **OK**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway**. |
+ | Region | Select the region of your virtual network. In this example, it's **West Europe**. |
+ | Availability zone | Leave the default of **None**. |
+ | Idle timeout (minutes) | Enter **10**. |
+
+5. Select the **Outbound IP** tab, or select **Next: Outbound IP** at the bottom of the page.
+
+6. In **Public IP addresses** in the **Outbound IP** tab, select **Create a new public IP address**.
+
+7. In **Add a public IP address**, enter **myNATgatewayIP** in **Name**. Select **OK**.
+
+8. Select the **Subnet** tab, or select **Next: Subnet** at the bottom of the page.
+
+9. In the pull-down box for **Virtual network**, select your virtual network.
+
+10. In **Subnet name**, select the checkbox next to your subnet.
+
+11. Select the **Review + create** tab, or select **Review + create** at the bottom of the page.
+
+12. Select **Create**.
+
+## Migrate load balancer outbound connectivity
+
+In this section, youΓÇÖll learn how to change your outbound connectivity method from outbound rules to a NAT gateway. You'll keep the same frontend IP address used for the outbound rules. You'll remove the outbound ruleΓÇÖs frontend IP configuration then create a NAT gateway with the same frontend IP address. A public load balancer is used throughout this section.
+
+### Remove outbound rule frontend IP configuration
+
+You remove the outbound rule and the associated frontend IP configuration from your load balancer. The load balancer name used in this example is **myLoadBalancer**.
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+2. In the search box at the top of the portal, enter **Load balancer**. Select **Load balancers** in the search results.
+
+3. Select **myLoadBalancer** or your load balancer.
+
+4. In **myLoadBalancer**, select **Frontend IP configuration** in **Settings**.
+
+5. Note the **IP address** in **Frontend IP configuration** that you wish to migrate to a **NAT gateway**. You'll need this information in the next section. In this example, it's **myFrontendIP-outbound**.
+
+6. Select **Delete** next to the IP configuration you wish to remove. In this example, it's **myFrontendIP-outbound**.
+
+ :::image type="content" source="./media/tutorial-migrate-outbound-nat/frontend-ip.png" alt-text="Screenshot of frontend IP address removal for NAT gateway.":::
++
+7. Select **Delete**.
+
+8. In **Delete myFrontendIP-outbound**, select the check box next to **I have read and understood that this frontend IP configuration as well as the associated resources listed above will be deleted**.
+
+9. Select **Delete**. This procedure will delete the frontend IP configuration and the outbound rule associated with the frontend.
+
+ :::image type="content" source="./media/tutorial-migrate-outbound-nat/delete-frontend-ip.png" alt-text="Screenshot of confirmation of frontend IP address removal for NAT gateway.":::
+
+### Create NAT gateway
+
+In this section, youΓÇÖll create a NAT gateway with the IP address previously used for outbound rule and assign it to your pre-created subnet within your virtual network. The subnet name for this example is **myBackendSubnet**.
+
+1. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways**.
+
+2. In **NAT gateways**, select **+ Create**.
+
+3. In **Create network address translation (NAT) gateway**, enter or select the following information in the **Basics** tab.
+
+ | Setting | Value |
+ | - | -- |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **Create new**. </br> Enter **myResourceGroup**. </br> Select **OK**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway**. |
+ | Region | Select the region of your virtual network. In this example, it's **West Europe**. |
+ | Availability zone | Leave the default of **None**. |
+ | Idle timeout (minutes) | Enter **10**. |
+
+4. Select the **Outbound IP** tab, or select **Next: Outbound IP** at the bottom of the page.
+
+5. In **Public IP addresses** in the **Outbound IP** tab, select the IP address you noted from the previous section. In this example, it's **myPublicIP-outbound**.
+
+6. Select the **Subnet** tab, or select **Next: Subnet** at the bottom of the page.
+
+7. In the pull-down box for **Virtual network**, select your virtual network.
+
+8. In **Subnet name**, select the checkbox for your subnet. In this example, it's **myBackendSubnet**.
+
+9. Select the **Review + create** tab, or select **Review + create** at the bottom of the page.
+
+10. Select **Create**.
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete
+the NAT gateway with the following steps:
+
+1. From the left-hand menu, select **Resource groups**.
+
+2. Select the **myResourceGroup** resource group.
+
+3. Select **Delete resource group**.
+
+4. Enter **myResourceGroup** and select **Delete**.
+
+## Next steps
+
+In this article, you learned how to:
+
+* Migrate default outbound access to a NAT gateway.
+
+* Migrate load balancer outbound connectivity and IP address to a NAT gateway.
+
+For more information about NAT gateway and the connectivity benefits it provides, see [Design virtual networks with NAT gateway](nat-gateway-resource.md).
+
+Advance to the next article to learn how to integrate a NAT gateway with a public load balancer:
+> [!div class="nextstepaction"]
+> [Integrate a NAT gateway with a public load balancer using the Azure portal](tutorial-nat-gateway-load-balancer-public-portal.md)
nat-gateway Tutorial Nat Gateway Load Balancer Internal Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-nat-gateway-load-balancer-internal-portal.md
+
+ Title: 'Tutorial: Integrate NAT gateway with an internal load balancer - Azure portal'
+
+description: In this tutorial, learn how to integrate a NAT gateway with an internal load Balancer using the Azure portal.
++++ Last updated : 05/24/2022+++
+# Tutorial: Integrate a NAT gateway with an internal load balancer using the Azure portal
+
+In this tutorial, you'll learn how to integrate a NAT gateway with an internal load balancer.
+
+By default, an Azure Standard Load Balancer is secure. Outbound connectivity is explicitly defined by enabling outbound SNAT (Source Network Address Translation).
+
+SNAT is enabled for an internal backend pool via another public load balancer, network routing, or a public IP defined on a virtual machine.
+
+The NAT gateway integration replaces the need for the deployment of a public load balancer, network routing, or a public IP defined on a virtual machine in the backend pool.
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Create an Azure Load Balancer
+> * Create two virtual machines for the backend pool of the Azure Load Balancer
+> * Create a NAT gateway
+> * Validate outbound connectivity of the virtual machines in the load balancer backend pool
+
+## Prerequisites
+
+An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+## Create the virtual network
+
+In this section, you'll create a virtual network and subnet.
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+1. On the upper-left side of the screen, select **Create a resource > Networking > Virtual network** or search for **Virtual network** in the search box.
+
+2. Select **Create**.
+
+3. In **Create virtual network**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription |
+ | Resource Group | Select **Create new**. Enter **TutorIntLBNAT-rg**. </br> Select **OK**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet** |
+ | Region | Select **(US) East US** |
+
+4. Select the **IP Addresses** tab or select the **Next: IP Addresses** button at the bottom of the page.
+
+5. In the **IP Addresses** tab, enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | IPv4 address space | Enter **10.1.0.0/16** |
+
+6. Under **Subnet name**, select the word **default**.
+
+7. In **Edit subnet**, enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Subnet name | Enter **myBackendSubnet** |
+ | Subnet address range | Enter **10.1.0.0/24** |
+
+8. Select **Save**.
+
+9. Select the **Security** tab or select the **Next: Security** button at the bottom of the page.
+
+10. Under **BastionHost**, select **Enable**. Enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Bastion name | Enter **myBastionHost** |
+ | AzureBastionSubnet address space | Enter **10.1.1.0/24** |
+ | Public IP Address | Select **Create new**. </br> For **Name**, enter **myBastionIP**. </br> Select **OK**. |
++
+11. Select the **Review + create** tab or select the **Review + create** button.
+
+12. Select **Create**.
+
+## Create load balancer
+
+In this section, you create a load balancer that load balances virtual machines.
+
+During the creation of the load balancer, you'll configure:
+
+* Frontend IP address
+* Backend pool
+* Inbound load-balancing rules
+
+1. In the search box at the top of the portal, enter **Load balancer**. Select **Load balancers** in the search results.
+
+2. In the **Load balancer** page, select **Create**.
+
+3. In the **Basics** tab of the **Create load balancer** page, enter, or select the following information:
+
+ | Setting | Value |
+ | | |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorIntLBNAT-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myLoadBalancer** |
+ | Region | Select **(US) East US**. |
+ | SKU | Leave the default **Standard**. |
+ | Type | Select **Internal**. |
+
+4. Select **Next: Frontend IP configuration** at the bottom of the page.
+
+5. In **Frontend IP configuration**, select **+ Add a frontend IP configuration**.
+
+6. Enter **LoadBalancerFrontend** in **Name**.
+
+7. Select **myVNet** in **Virtual network**.
+
+8. Select **myBackendSubnet** in **Subnet**.
+
+9. Select **Dynamic** for **Assignment**.
+
+10. Select **Zone-redundant** in **Availability zone**.
+
+ > [!NOTE]
+ > In regions with [Availability Zones](../availability-zones/az-overview.md?toc=%2fazure%2fvirtual-network%2ftoc.json#availability-zones), you have the option to select no-zone (default option), a specific zone, or zone-redundant. The choice will depend on your specific domain failure requirements. In regions without Availability Zones, this field won't appear. </br> For more information on availability zones, see [Availability zones overview](../availability-zones/az-overview.md).
+
+11. Select **Add**.
+
+12. Select **Next: Backend pools** at the bottom of the page.
+
+13. In the **Backend pools** tab, select **+ Add a backend pool**.
+
+14. Enter **myBackendPool** for **Name** in **Add backend pool**.
+
+15. Select **NIC** or **IP Address** for **Backend Pool Configuration**.
+
+16. Select **IPv4** or **IPv6** for **IP version**.
+
+17. Select **Add**.
+
+18. Select the **Next: Inbound rules** button at the bottom of the page.
+
+19. In **Load balancing rule** in the **Inbound rules** tab, select **+ Add a load balancing rule**.
+
+20. In **Add load balancing rule**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Name | Enter **myHTTPRule** |
+ | IP Version | Select **IPv4** or **IPv6** depending on your requirements. |
+ | Frontend IP address | Select **LoadBalancerFrontend**. |
+ | Backend pool | Select **myBackendPool**. |
+ | Protocol | Select **TCP**. |
+ | Port | Enter **80**. |
+ | Backend port | Enter **80**. |
+ | Health probe | Select **Create new**. </br> In **Name**, enter **myHealthProbe**. </br> Select **HTTP** in **Protocol**. </br> Leave the rest of the defaults, and select **OK**. |
+ | Session persistence | Select **None**. |
+ | Idle timeout (minutes) | Enter or select **15**. |
+ | TCP reset | Select **Enabled**. |
+ | Floating IP | Select **Disabled**. |
+
+21. Select **Add**.
+
+22. Select the blue **Review + create** button at the bottom of the page.
+
+23. Select **Create**.
+
+## Create virtual machines
+
+In this section, you'll create two VMs (**myVM1** and **myVM2**) in two different zones (**Zone 1** and **Zone 2**).
+
+These VMs are added to the backend pool of the load balancer that was created earlier.
+
+1. On the upper-left side of the portal, select **Create a resource** > **Compute** > **Virtual machine**.
+
+2. In **Create a virtual machine**, type or select the values in the **Basics** tab:
+
+ | Setting | Value |
+ |--|-|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription |
+ | Resource Group | Select **TutorIntLBNAT-rg** |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM1** |
+ | Region | Select **(US) East US** |
+ | Availability Options | Select **Availability zones** |
+ | Availability zone | Select **1** |
+ | Image | Select **Windows Server 2019 Datacenter** |
+ | Azure Spot instance | Leave the default |
+ | Size | Choose VM size or take default setting |
+ | **Administrator account** | |
+ | Username | Enter a username |
+ | Password | Enter a password |
+ | Confirm password | Reenter password |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None** |
+
+3. Select the **Networking** tab, or select **Next: Disks**, then **Next: Networking**.
+
+4. In the Networking tab, select or enter:
+
+ | Setting | Value |
+ |-|-|
+ | **Network interface** | |
+ | Virtual network | **myVNet** |
+ | Subnet | **myBackendSubnet** |
+ | Public IP | Select **None**. |
+ | NIC network security group | Select **Advanced**|
+ | Configure network security group | Select **Create new**. </br> In the **Create network security group**, enter **myNSG** in **Name**. </br> Under **Inbound rules**, select **+Add an inbound rule**. </br> Under **Destination port ranges**, enter **80**. </br> Under **Priority**, enter **100**. </br> In **Name**, enter **myNSGRule** </br> Select **Add** </br> Select **OK** |
+ | **Load balancing** |
+ | Place this virtual machine behind an existing load-balancing solution? | Select the check box. |
+ | **Load balancing settings** |
+ | Load balancing options | Select **Azure load balancer** |
+ | Select a load balancer | Select **myLoadBalancer** |
+ | Select a backend pool | Select **myBackendPool** |
+
+5. Select **Review + create**.
+
+6. Review the settings, and then select **Create**.
+
+7. Follow the steps 1 to 6 to create a VM with the following values and all the other settings the same as **myVM1**:
+
+ | Setting | VM 2 |
+ | - | -- |
+ | Name | **myVM2** |
+ | Availability zone | **2** |
+ | Network security group | Select the existing **myNSG**|
+
+## Create NAT gateway
+
+In this section, you'll create a NAT gateway and assign it to the subnet in the virtual network you created previously.
+
+1. On the upper-left side of the screen, select **Create a resource > Networking > NAT gateway** or search for **NAT gateway** in the search box.
+
+2. Select **Create**.
+
+3. In **Create network address translation (NAT) gateway**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription. |
+ | Resource Group | Select **TutorIntLBNAT-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myNATGateway** |
+ | Region | Select **(US) East US** |
+ | Availability Zone | Select **None**. |
+ | Idle timeout (minutes) | Enter **10**. |
+
+4. Select the **Outbound IP** tab, or select the **Next: Outbound IP** button at the bottom of the page.
+
+5. In the **Outbound IP** tab, enter or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | Public IP addresses | Select **Create a new public IP address**. </br> In **Name**, enter **myNATgatewayIP**. </br> Select **OK**. |
+
+6. Select the **Subnet** tab, or select the **Next: Subnet** button at the bottom of the page.
+
+7. In the **Subnet** tab, select **myVNet** in the **Virtual network** pull-down.
+
+8. Check the box next to **myBackendSubnet**.
+
+9. Select the **Review + create** tab, or select the blue **Review + create** button at the bottom of the page.
+
+10. Select **Create**.
+
+## Test NAT gateway
+
+In this section, we'll test the NAT gateway. We'll first discover the public IP of the NAT gateway. We'll then connect to the test virtual machine and verify the outbound connection through the NAT gateway.
+
+1. Select **Resource groups** in the left-hand menu, select the **TutorIntLBNAT-rg** resource group, and then from the resources list, select **myNATgatewayIP**.
+
+2. Make note of the public IP address:
+
+ :::image type="content" source="./media/tutorial-nat-gateway-load-balancer-internal-portal/find-public-ip.png" alt-text="Screenshot of discover public IP address of NAT gateway." border="true":::
+
+3. Select **Resource groups** in the left-hand menu, select the **TutorIntLBNAT-rg** resource group, and then from the resources list, select **myVM1**.
+
+4. On the **Overview** page, select **Connect**, then **Bastion**.
+
+5. Enter the username and password entered during VM creation.
+
+6. Open **Internet Explorer** on **myVM1**.
+
+7. Enter **https://whatsmyip.com** in the address bar.
+
+8. Verify the IP address displayed matches the NAT gateway address you noted in the previous step:
+
+ :::image type="content" source="./media/tutorial-nat-gateway-load-balancer-internal-portal/my-ip.png" alt-text="Screenshot of Internet Explorer showing external outbound IP." border="true":::
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete
+the virtual network, virtual machine, and NAT gateway with the following steps:
+
+1. From the left-hand menu, select **Resource groups**.
+
+2. Select the **TutorIntLBNAT-rg** resource group.
+
+3. Select **Delete resource group**.
+
+4. Enter **TutorIntLBNAT-rg** and select **Delete**.
+
+## Next steps
+
+For more information on Azure NAT Gateway, see:
+> [!div class="nextstepaction"]
+> [Azure NAT Gateway overview](nat-overview.md)
nat-gateway Tutorial Nat Gateway Load Balancer Public Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-nat-gateway-load-balancer-public-portal.md
+
+ Title: 'Tutorial: Integrate NAT gateway with a public load balancer - Azure portal'
+
+description: In this tutorial, learn how to integrate a NAT gateway with a public load Balancer using the Azure portal.
++++ Last updated : 05/24/2022+++
+# Tutorial: Integrate a NAT gateway with a public load balancer using the Azure portal
+
+In this tutorial, you'll learn how to integrate a NAT gateway with a public load balancer.
+
+By default, an Azure Standard Load Balancer is secure. Outbound connectivity is explicitly defined by enabling outbound SNAT (Source Network Address Translation). SNAT is enabled in a load-balancing rule or outbound rules.
+
+The NAT gateway integration replaces the need for outbound rules for backend pool outbound SNAT.
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Create an Azure Load Balancer
+> * Create two virtual machines for the backend pool of the Azure Load Balancer
+> * Create a NAT gateway
+> * Validate outbound connectivity of the virtual machines in the load balancer backend pool
+
+## Prerequisites
+
+An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+## Create the virtual network
+
+In this section, you'll create a virtual network and subnet.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. In **Virtual networks**, select **+ Create**.
+
+3. In **Create virtual network**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription |
+ | Resource Group | Select **Create new**. </br> In **Name** enter **TutorPubLBNAT-rg**. </br> Select **OK**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet** |
+ | Region | Select **(US) East US** |
+
+4. Select the **IP Addresses** tab or select the **Next: IP Addresses** button at the bottom of the page.
+
+5. In the **IP Addresses** tab, enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | IPv4 address space | Enter **10.1.0.0/16** |
+
+6. Under **Subnet name**, select the word **default**.
+
+7. In **Edit subnet**, enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Subnet name | Enter **myBackendSubnet** |
+ | Subnet address range | Enter **10.1.0.0/24** |
+
+8. Select **Save**.
+
+9. Select the **Security** tab or select the **Next: Security** button at the bottom of the page.
+
+10. Under **BastionHost**, select **Enable**. Enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Bastion name | Enter **myBastionHost** |
+ | AzureBastionSubnet address space | Enter **10.1.1.0/27** |
+ | Public IP Address | Select **Create new**. </br> For **Name**, enter **myBastionIP**. </br> Select **OK**. |
++
+11. Select the **Review + create** tab or select the **Review + create** button.
+
+12. Select **Create**.
+
+## Create load balancer
+
+In this section, you'll create a zone redundant load balancer that load balances virtual machines. With zone-redundancy, one or more availability zones can fail and the data path survives as long as one zone in the region remains healthy.
+
+During the creation of the load balancer, you'll configure:
+
+* Frontend IP address
+* Backend pool
+* Inbound load-balancing rules
+
+1. In the search box at the top of the portal, enter **Load balancer**. Select **Load balancers** in the search results.
+
+2. In the **Load balancer** page, select **Create**.
+
+3. In the **Basics** tab of the **Create load balancer** page, enter, or select the following information:
+
+ | Setting | Value |
+ | | |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **TutorPubLBNAT-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myLoadBalancer** |
+ | Region | Select **(US) East US**. |
+ | SKU | Leave the default **Standard**. |
+ | Type | Select **Public**. |
+ | Tier | Leave the default **Regional**. |
++
+4. Select **Next: Frontend IP configuration** at the bottom of the page.
+
+5. In **Frontend IP configuration**, select **+ Add a frontend IP configuration**.
+
+6. Enter **LoadBalancerFrontend** in **Name**.
+
+7. Select **IPv4** or **IPv6** for the **IP version**.
+
+ > [!NOTE]
+ > IPv6 isn't currently supported with Routing Preference or Cross-region load-balancing (Global Tier).
+
+8. Select **IP address** for the **IP type**.
+
+ > [!NOTE]
+ > For more information on IP prefixes, see [Azure Public IP address prefix](../virtual-network/ip-services/public-ip-address-prefix.md).
+
+9. Select **Create new** in **Public IP address**.
+
+10. In **Add a public IP address**, enter **myPublicIP** for **Name**.
+
+11. Select **Zone-redundant** in **Availability zone**.
+
+ > [!NOTE]
+ > In regions with [Availability Zones](../availability-zones/az-overview.md?toc=%2fazure%2fvirtual-network%2ftoc.json#availability-zones), you have the option to select no-zone (default option), a specific zone, or zone-redundant. The choice will depend on your specific domain failure requirements. In regions without Availability Zones, this field won't appear. </br> For more information on availability zones, see [Availability zones overview](../availability-zones/az-overview.md).
+
+12. Leave the default of **Microsoft Network** for **Routing preference**.
+
+13. Select **OK**.
+
+14. Select **Add**.
+
+15. Select **Next: Backend pools** at the bottom of the page.
+
+16. In the **Backend pools** tab, select **+ Add a backend pool**.
+
+17. Enter **myBackendPool** for **Name** in **Add backend pool**.
+
+18. Select **myVNet** in **Virtual network**.
+
+19. Select **NIC** or **IP Address** for **Backend Pool Configuration**.
+
+20. Select **IPv4** or **IPv6** for **IP version**.
+
+21. Select **Add**.
+
+22. Select the **Next: Inbound rules** button at the bottom of the page.
+
+23. In **Load balancing rule** in the **Inbound rules** tab, select **+ Add a load balancing rule**.
+
+24. In **Add load balancing rule**, enter or select the following information:
+
+ | Setting | Value |
+ | - | -- |
+ | Name | Enter **myHTTPRule** |
+ | IP Version | Select **IPv4** or **IPv6** depending on your requirements. |
+ | Frontend IP address | Select **LoadBalancerFrontend**. |
+ | Backend pool | Select **myBackendPool**. |
+ | Protocol | Select **TCP**. |
+ | Port | Enter **80**. |
+ | Backend port | Enter **80**. |
+ | Health probe | Select **Create new**. </br> In **Name**, enter **myHealthProbe**. </br> Select **HTTP** in **Protocol**. </br> Leave the rest of the defaults, and select **OK**. |
+ | Session persistence | Select **None**. |
+ | Idle timeout (minutes) | Enter or select **15**. |
+ | TCP reset | Select **Enabled**. |
+ | Floating IP | Select **Disabled**. |
+ | Outbound source network address translation (SNAT) | Leave the default of **(Recommended) Use outbound rules to provide backend pool members access to the internet.** |
+
+25. Select **Add**.
+
+26. Select the blue **Review + create** button at the bottom of the page.
+
+27. Select **Create**.
+
+## Create virtual machines
+
+In this section, you'll create two VMs (**myVM1** and **myVM2**) in two different zones (**Zone 1** and **Zone 2**).
+
+These VMs are added to the backend pool of the load balancer that was created earlier.
+
+1. On the upper-left side of the portal, select **Create a resource** > **Compute** > **Virtual machine**.
+
+2. In **Create a virtual machine**, type or select the values in the **Basics** tab:
+
+ | Setting | Value |
+ |--|-|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription |
+ | Resource Group | Select **TutorPubLBNAT-rg** |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM1** |
+ | Region | Select **(US) East US** |
+ | Availability Options | Select **Availability zones** |
+ | Availability zone | Select **1** |
+ | Image | Select **Windows Server 2019 Datacenter** |
+ | Azure Spot instance | Leave the default |
+ | Size | Choose VM size or take default setting |
+ | **Administrator account** | |
+ | Username | Enter a username |
+ | Password | Enter a password |
+ | Confirm password | Reenter password |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None** |
+
+3. Select the **Networking** tab, or select **Next: Disks**, then **Next: Networking**.
+
+4. In the Networking tab, select or enter:
+
+ | Setting | Value |
+ |-|-|
+ | **Network interface** | |
+ | Virtual network | **myVNet** |
+ | Subnet | **myBackendSubnet** |
+ | Public IP | Select **None**. |
+ | NIC network security group | Select **Advanced**|
+ | Configure network security group | Select **Create new**. </br> In the **Create network security group**, enter **myNSG** in **Name**. </br> Under **Inbound rules**, select **+Add an inbound rule**. </br> In **Destination port ranges**, enter **80**. </br> Under **Priority**, enter **100**. </br> In **Name**, enter **myNSGRule** </br> Select **Add** </br> Select **OK** |
+ | **Load balancing** |
+ | Place this virtual machine behind an existing load-balancing solution? | Select the check box.|
+ | **Load balancing settings** |
+ | Load-balancing options | Select **Azure load balancer** |
+ | Select a load balancer | Select **myLoadBalancer** |
+ | Select a backend pool | Select **myBackendPool** |
+
+5. Select **Review + create**.
+
+6. Review the settings, and then select **Create**.
+
+7. Follow the steps 1 to 7 to create a VM with the following values and all the other settings the same as **myVM1**:
+
+ | Setting | VM 2 |
+ | - | -- |
+ | Name | **myVM2** |
+ | Availability zone | **2** |
+ | Network security group | Select the existing **myNSG** |
+
+## Create NAT gateway
+
+In this section, you'll create a NAT gateway and assign it to the subnet in the virtual network you created previously.
+
+1. On the upper-left side of the screen, select **Create a resource > Networking > NAT gateway** or search for **NAT gateway** in the search box.
+
+2. Select **Create**.
+
+3. In **Create network address translation (NAT) gateway**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription. |
+ | Resource Group | Select **TutorPubLBNAT-rg**. |
+ | **Instance details** | |
+ | Name | Enter **myNATGateway** |
+ | Region | Select **(US) East US** |
+ | Availability Zone | Select **None**. |
+ | Idle timeout (minutes) | Enter **10**. |
+
+4. Select the **Outbound IP** tab, or select the **Next: Outbound IP** button at the bottom of the page.
+
+5. In the **Outbound IP** tab, enter or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | Public IP addresses | Select **Create a new public IP address**. </br> In **Name**, enter **myNATgatewayIP**. </br> Select **OK**. |
+
+6. Select the **Subnet** tab, or select the **Next: Subnet** button at the bottom of the page.
+
+7. In the **Subnet** tab, select **myVNet** in the **Virtual network** pull-down.
+
+8. Check the box next to **myBackendSubnet**.
+
+9. Select the **Review + create** tab, or select the blue **Review + create** button at the bottom of the page.
+
+10. Select **Create**.
+
+## Test NAT gateway
+
+In this section, we'll test the NAT gateway. We'll first discover the public IP of the NAT gateway. We'll then connect to the test virtual machine and verify the outbound connection through the NAT gateway.
+
+1. Select **Resource groups** in the left-hand menu, select the **TutorPubLBNAT-rg** resource group, and then from the resources list, select **myNATgatewayIP**.
+
+2. Make note of the public IP address:
+
+ :::image type="content" source="./media/tutorial-nat-gateway-load-balancer-public-portal/find-public-ip.png" alt-text="Screenshot discover public IP address of NAT gateway." border="true":::
+
+3. Select **Resource groups** in the left-hand menu, select the **TutorPubLBNAT-rg** resource group, and then from the resources list, select **myVM1**.
+
+4. On the **Overview** page, select **Connect**, then **Bastion**.
+
+5. Enter the username and password entered during VM creation.
+
+6. Open **Internet Explorer** on **myVM1**.
+
+7. Enter **https://whatsmyip.com** in the address bar.
+
+8. Verify the IP address displayed matches the NAT gateway address you noted in the previous step:
+
+ :::image type="content" source="./media/tutorial-nat-gateway-load-balancer-public-portal/my-ip.png" alt-text="Screenshot Internet Explorer showing external outbound IP." border="true":::
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete
+the virtual network, virtual machine, and NAT gateway with the following steps:
+
+1. From the left-hand menu, select **Resource groups**.
+
+2. Select the **TutorPubLBNAT-rg** resource group.
+
+3. Select **Delete resource group**.
+
+4. Enter **TutorPubLBNAT-rg** and select **Delete**.
+
+## Next steps
+
+For more information on Azure NAT Gateway, see:
+> [!div class="nextstepaction"]
+> [Azure NAT Gateway overview](nat-overview.md)
nat-gateway Tutorial Protect Nat Gateway Ddos https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/nat-gateway/tutorial-protect-nat-gateway-ddos.md
+
+ Title: 'Tutorial: Protect your NAT gateway with Azure DDoS Protection Standard'
+
+description: Learn how to create an NAT gateway in an Azure DDoS Protection Standard protected virtual network.
++++ Last updated : 01/24/2022++
+# Tutorial: Protect your NAT gateway with Azure DDoS Protection Standard
+
+This article helps you create a NAT gateway with a DDoS protected virtual network. Azure DDoS Protection Standard enables enhanced DDoS mitigation capabilities such as adaptive tuning, attack alert notifications, and monitoring to protect your NAT gateway from large scale DDoS attacks.
+
+> [!IMPORTANT]
+> Azure DDoS Protection incurs a cost when you use the Standard SKU. Overages charges only apply if more than 100 public IPs are protected in the tenant. Ensure you delete the resources in this tutorial if you aren't using the resources in the future. For information about pricing, see [Azure DDoS Protection Pricing]( https://azure.microsoft.com/pricing/details/ddos-protection/). For more information about Azure DDoS protection, see [What is Azure DDoS Protection?](../ddos-protection/ddos-protection-overview.md).
+
+In this tutorial, you learn how to:
+
+> [!div class="checklist"]
+> * Create a NAT gateway
+> * Create a DDoS protection plan
+> * Create a virtual network and associate the DDoS protection plan
+> * Create a test virtual machine
+> * Test the NAT gateway
+
+## Prerequisites
+
+- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
+
+## Create a NAT gateway
+
+Before you deploy the NAT gateway resource and the other resources, a resource group is required to contain the resources deployed. In the following steps, you'll create a resource group, NAT gateway resource, and a public IP address. You can use one or more public IP address resources, public IP prefixes, or both.
+
+For information about public IP prefixes and a NAT gateway, see [Manage NAT gateway](./manage-nat-gateway.md?tabs=manage-nat-portal#add-or-remove-a-public-ip-prefix).
+
+1. Sign in to the [Azure portal](https://portal.azure.com).
+
+2. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways** in the search results.
+
+3. Select **+ Create**.
+
+4. In **Create network address translation (NAT) gateway**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription. |
+ | Resource Group | Select **Create new**. </br> Enter **myResourceGroupNAT**. </br> Select **OK**. |
+ | **Instance details** | |
+ | NAT gateway name | Enter **myNATgateway** |
+ | Region | Select **West Europe** |
+ | Availability Zone | Select **No Zone**. |
+ | Idle timeout (minutes) | Enter **10**. |
+
+ For information about availability zones and NAT gateway, see [NAT gateway and availability zones](./nat-availability-zones.md).
+
+5. Select the **Outbound IP** tab, or select the **Next: Outbound IP** button at the bottom of the page.
+
+6. In the **Outbound IP** tab, enter or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | Public IP addresses | Select **Create a new public IP address**. </br> In **Name**, enter **myPublicIP**. </br> Select **OK**. |
+
+7. Select the **Review + create** tab, or select the blue **Review + create** button at the bottom of the page.
+
+8. Select **Create**.
+
+## Create a DDoS protection plan
+
+1. In the search box at the top of the portal, enter **DDoS protection**. Select **DDoS protection plans** in the search results and then select **+ Create**.
+
+1. In the **Basics** tab of **Create a DDoS protection plan** page, enter or select the following information:
+
+ | Setting | Value |
+ |--|--|
+ | **Project details** | |
+ | Subscription | Select your Azure subscription. |
+ | Resource group | Enter **myResourceGroupNAT**. |
+ | **Instance details** | |
+ | Name | Enter **myDDoSProtectionPlan**. |
+ | Region | Select **West Europe**. |
+
+1. Select **Review + create** and then select **Create** to deploy the DDoS protection plan.
+
+## Create a virtual network
+
+Before you deploy a virtual machine and can use your NAT gateway, you need to create the virtual network. This virtual network will contain the virtual machine created in later steps.
+
+1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual networks** in the search results.
+
+2. Select **Create**.
+
+3. In **Create virtual network**, enter or select this information in the **Basics** tab:
+
+ | **Setting** | **Value** |
+ ||--|
+ | **Project Details** | |
+ | Subscription | Select your Azure subscription |
+ | Resource Group | Select **myResourceGroupNAT**. |
+ | **Instance details** | |
+ | Name | Enter **myVNet** |
+ | Region | Select **(Europe) West Europe** |
+
+4. Select the **IP Addresses** tab or select the **Next: IP Addresses** button at the bottom of the page.
+
+5. Accept the default IPv4 address space of **10.1.0.0/16**.
+
+6. In the subnet section in **Subnet name**, select the **default** subnet.
+
+7. In **Edit subnet**, enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Subnet name | Enter **mySubnet** |
+ | Subnet address range | Enter **10.1.0.0/24** |
+ | **NAT GATEWAY** |
+ | NAT gateway | Select **myNATgateway**. |
+
+8. Select **Save**.
+
+9. Select the **Security** tab.
+
+10. In **BastionHost**, select **Enable**. Enter this information:
+
+ | Setting | Value |
+ |--|-|
+ | Bastion name | Enter **myBastionHost** |
+ | AzureBastionSubnet address space | Enter **10.1.1.0/26** |
+ | Public IP Address | Select **Create new**. </br> For **Name**, enter **myBastionIP**. </br> Select **OK**. |
+
+11. In **DDoS protection** select **Enable**. Select **myDDoSProtectionPlan** in DDoS protection plan.
+
+12. Select the **Review + create** tab or select the **Review + create** button.
+
+13. Select **Create**.
+
+It can take a few minutes for the deployment of the virtual network to complete. Proceed to the next steps when the deployment completes.
+
+## Create test virtual machine
+
+In this section, you'll create a virtual machine to test the NAT gateway and verify the public IP address of the outbound connection.
+
+1. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+2. Select **+ Create** > **Azure virtual machine**.
+
+2. In the **Create a virtual machine** page in the **Basics** tab, enter, or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | **Project details** | |
+ | Subscription | Select your subscription. |
+ | Resource group | Select **myResourceGroupNAT**. |
+ | **Instance details** | |
+ | Virtual machine name | Enter **myVM**. |
+ | Region | Select **(Europe) West Europe**. |
+ | Availability options | Select **No infrastructure redundancy required**. |
+ | Security type | Select **Standard**. |
+ | Image | Select **Windows Server 2022 Datacenter: Azure Edition - Gen2**. |
+ | Size | Select a size. |
+ | **Administrator account** | |
+ | Username | Enter a username for the virtual machine. |
+ | Password | Enter a password. |
+ | Confirm password | Confirm password. |
+ | **Inbound port rules** | |
+ | Public inbound ports | Select **None**. |
+
+3. Select the **Disks** tab, or select the **Next: Disks** button at the bottom of the page.
+
+4. Leave the default in the **Disks** tab.
+
+5. Select the **Networking** tab, or select the **Next: Networking** button at the bottom of the page.
+
+6. In the **Networking** tab, enter or select the following information:
+
+ | **Setting** | **Value** |
+ | -- | |
+ | **Network interface** | |
+ | Virtual network | Select **myVNet**. |
+ | Subnet | Select **mySubnet (10.1.0.0/24)**. |
+ | Public IP | Select **None**. |
+ | NIC network security group | Select **Basic**. |
+ | Public inbound ports | Select **None**. |
+
+7. Select the **Review + create** tab, or select the blue **Review + create** button at the bottom of the page.
+
+8. Select **Create**.
+
+## Test NAT gateway
+
+In this section, you'll test the NAT gateway. You'll first discover the public IP of the NAT gateway. You'll then connect to the test virtual machine and verify the outbound connection through the NAT gateway.
+
+1. In the search box at the top of the portal, enter **Public IP**. Select **Public IP addresses** in the search results.
+
+2. Select **myPublicIP**.
+
+3. Make note of the public IP address:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/find-public-ip.png" alt-text="Screenshot of discover public IP address of NAT gateway." border="true":::
+
+4. In the search box at the top of the portal, enter **Virtual machine**. Select **Virtual machines** in the search results.
+
+5. Select **myVM**.
+
+4. On the **Overview** page, select **Connect**, then **Bastion**.
+
+6. Enter the username and password entered during VM creation. Select **Connect**.
+
+7. Open **Microsoft Edge** on **myTestVM**.
+
+8. Enter **https://whatsmyip.com** in the address bar.
+
+9. Verify the IP address displayed matches the NAT gateway address you noted in the previous step:
+
+ :::image type="content" source="./media/quickstart-create-nat-gateway-portal/my-ip.png" alt-text="Screenshot of Internet Explorer showing external outbound IP." border="true":::
+
+## Clean up resources
+
+If you're not going to continue to use this application, delete
+the virtual network, virtual machine, and NAT gateway with the following steps:
+
+1. From the left-hand menu, select **Resource groups**.
+
+2. Select the **myResourceGroupNAT** resource group.
+
+3. Select **Delete resource group**.
+
+4. Enter **myResourceGroupNAT** and select **Delete**.
+
+## Next steps
+
+For more information on Azure NAT Gateway, see:
+> [!div class="nextstepaction"]
+> [Azure NAT Gateway overview](nat-overview.md)
network-watcher Nsg Flow Logs Policy Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/network-watcher/nsg-flow-logs-policy-portal.md
Title: Deploy and manage NSG flow logs using Azure Policy
+ Title: Manage NSG flow logs using Azure Policy
-description: Learn how to use built-in policies to manage the deployment of network security group (NSG) flow logs.
+description: Learn how to use built-in policies to manage the deployment of Azure Network Watcher NSG flow logs.
- Previously updated : 02/09/2022 Last updated : 04/30/2023 -+
-# Deploy and manage NSG flow logs using Azure Policy
+# Manage NSG flow logs using Azure Policy
-Azure Policy helps to enforce organizational standards and to assess compliance at scale. Common use cases for Azure Policy include implementing governance for resource consistency, regulatory compliance, security, cost, and management. In this article, we'll use two built-in policies available for NSG Flow Logs to manage your flow logs setup. The first policy flags any NSGs without flow logs enabled. The second policy automatically deploys Flow logs for NSGs without Flow logs enabled.
+Azure Policy helps to enforce organizational standards and to assess compliance at scale. Common use cases for Azure Policy include implementing governance for resource consistency, regulatory compliance, security, cost, and management. In this article, you learn how to use two built-in policies available for NSG flow Logs to manage your flow logs setup. The first policy flags any network security group without flow logs enabled. The second policy automatically deploys NSG flow logs without flow logs enabled.
-If you're creating an Azure Policy definition for the first time, you can read through:
-- [Azure Policy overview](../governance/policy/overview.md) -- [Tutorial for creating an Azure Policy assignment](../governance/policy/assign-policy-portal.md#create-a-policy-assignment).
+To learn more about Azure policy, see [What is Azure Policy?](../governance/policy/overview.md) and [Quickstart: Create a policy assignment to identify non-compliant resources](../governance/policy/assign-policy-portal.md).
## Locate the policies
Navigate to the Azure Policy page by searching for Policy in the top search bar
4. Select the three dots menu under "Policy Definitions" to see available policies
-5. Use the Type filter and choose "Built-in". Then search for "Flow log"
+5. Use the Type filter and choose "Built-in". Then search for "flow log"
-You should see the two built-in policies for Flow logs
+You should see the two built-in policies for flow logs
![Policy List](./media/network-watcher-builtin-policy/4_filter-for-flow-log-policies.png) 6. Choose the policy you want to assign -- *"Flow log should be configured for every network security group"* is the audit policy that flags non-compliant NSGs, that is NSGs without Flow logging enabled-- *"Deploy a flow log resource with target network security group"* is the policy with a deployment action, it enables Flow logs on all NSGs without Flow logs-
-There are separate instructions for each policy below.
+- *"Flow log should be configured for every network security group"* is the audit policy that flags non-compliant network security groups (network security groups without flow logging enabled)
+- *"Deploy a flow log resource with target network security group"* is the policy with a deployment action, it enables flow logs on all network security groups without flow logs
## Audit Policy ### How the policy works
-The policy checks all existing ARM objects of type ΓÇ£Microsoft.Network/networkSecurityGroupsΓÇ¥, that is, it looks at all NSGs in a given scope, and checks for the existence of linked Flow logs via the Flow Logs property of the NSG. If the property doesn't exist, the NSG is flagged.
+The policy checks all existing ARM objects of type ΓÇ£Microsoft.Network/networkSecurityGroupsΓÇ¥, that is, it looks at all network security groups in a given scope, and checks for the existence of linked flow logs via the flow Logs property of the network security group. If the property doesn't exist, the network security group is flagged.
-If you want to see the full definition of the policy, you can visit the [Definitions tab](https://portal.azure.com/#blade/Microsoft_Azure_Policy/PolicyMenuBlade/Definitions) and search for "Flow logs" to find the policy
+If you want to see the full definition of the policy, you can visit the [Definitions tab](https://portal.azure.com/#blade/Microsoft_Azure_Policy/PolicyMenuBlade/Definitions) and search for "flow logs" to find the policy
### Assignment
You should see something similar to the following screenshot once your policy ru
### Policy Structure
-The policy checks all existing ARM objects of type ΓÇ£Microsoft.Network/networkSecurityGroupsΓÇ¥, that is, it looks at all NSGs in a given scope, and checks for the existence of linked Flow logs via the Flow Logs property of the NSG. If the property doesn't exist, the policy deploys a Flow log.
+The policy checks all existing ARM objects of type ΓÇ£Microsoft.Network/networkSecurityGroupsΓÇ¥, that is, it looks at all network security groups in a given scope, and checks for the existence of linked flow logs via the flow logs property of the network security group. If the property doesn't exist, the policy deploys a flow log.
-If you want to see the full definition of the policy, you can visit the [Definitions tab](https://portal.azure.com/#blade/Microsoft_Azure_Policy/PolicyMenuBlade/Definitions) and search for "Flow logs" to find the policy.
+If you want to see the full definition of the policy, you can visit the [Definitions tab](https://portal.azure.com/#blade/Microsoft_Azure_Policy/PolicyMenuBlade/Definitions) and search for "flow logs" to find the policy.
### Assignment
If you want to see the full definition of the policy, you can visit the [Definit
The Network Watcher service is a regional service. These parameters allow the policy action of deploying flow logs to be executed. - NSG Region: Azure regions at which the policy is targeted-- Storage ID: Full resource ID of the storage account. Note: This storage account should be in the same region as the NSG. -- Network Watchers RG: Name of the resource group containing your Network Watcher resource. If you haven't renamed it, you can enter `NetworkWatcherRG` which is the default.
+- Storage ID: Full resource ID of the storage account. Note: This storage account should be in the same region as the network security group.
+- Network Watchers RG: Name of the resource group containing your Network Watcher resource. If you haven't renamed it, you can enter `NetworkWatcherRG`, which is the default Network Watcher resource group.
- Network Watcher name: Name of the regional network watcher service. Format: NetworkWatcher_RegionName. Example: NetworkWatcher_centralus. See the full list. ![DINE Policy parameters](./media/network-watcher-builtin-policy/5_2_1_dine-policy-details-alt.png)
The Network Watcher service is a regional service. These parameters allow the po
- Check mark on **Create Remediation task** if you want the policy to affect existing resources - **Create a Managed Identity** should be already checked - Select the same location as previous for your Managed Identity -- You'll need Contributor or Owner permission to use this policy. If you have these permissions, you shouldn't see any errors.
+- You need Contributor or Owner permission to use this policy. If you have these permissions, you shouldn't see any errors.
![DINE Policy remediation](./media/network-watcher-builtin-policy/5_2_2_dine-remediation.png)
-4. Select "Review + Create" to review your assignment
+4. Select "Review + Create" to review your assignment.
You should see something similar to the following screenshot. ![DINE Policy review](./media/network-watcher-builtin-policy/5_2_3_dine-review.png)
You should see something like the following screenshot once your policy. In case
## Next steps -- Learn about [Traffic Analytics Built-in Policies](./traffic-analytics-policy-portal.md)-- Use this [tutorial](./quickstart-configure-network-security-group-flow-logs-from-arm-template.md) Go deeper by using ARM templates to deploy Flow Logs and Traffic Analytics.-- Learn more about [Network Watcher](./index.yml)
+- To learn more about NSG flow logs, see [Flow logs for network security groups](./network-watcher-nsg-flow-logging-overview.md).
+- To learn about using built-in policies with traffic analytics, see [Manage traffic analytics using Azure Policy](./traffic-analytics-policy-portal.md).
+- To learn how to use an ARM template to deploy flow Logs and traffic analytics, see [Configure NSG flow logs using an Azure Resource Manager (ARM) template](./quickstart-configure-network-security-group-flow-logs-from-arm-template.md).
network-watcher Traffic Analytics Policy Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/network-watcher/traffic-analytics-policy-portal.md
Previously updated : 04/18/2023 Last updated : 04/30/2023
-# Manage Azure Network Watcher traffic analytics using Azure Policy
+# Manage traffic analytics using Azure Policy
-Azure Policy helps to enforce organizational standards and to assess compliance at-scale. Common use cases for Azure Policy include implementing governance for resource consistency, regulatory compliance, security, cost, and management. In this article, you learn how to use three built-in policies available for [traffic analytics](./traffic-analytics.md) to manage your setup.
+Azure Policy helps to enforce organizational standards and to assess compliance at-scale. Common use cases for Azure Policy include implementing governance for resource consistency, regulatory compliance, security, cost, and management. In this article, you learn how to use three built-in policies available for [Azure Network Watcher traffic analytics](./traffic-analytics.md) to manage your setup.
To learn more about Azure policy, see [What is Azure Policy?](../governance/policy/overview.md) and [Quickstart: Create a policy assignment to identify non-compliant resources](../governance/policy/assign-policy-portal.md).
openshift Howto Use Key Vault Secrets https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/openshift/howto-use-key-vault-secrets.md
Previously updated : 12/30/2022 Last updated : 05/01/2023 keywords: azure, openshift, red hat, key vault #Customer intent: I need to understand how to use Azure Key Vault Provider for Secrets Store CSI Driver on Azure Red Hat OpenShift.
keywords: azure, openshift, red hat, key vault
Azure Key Vault Provider for Secrets Store CSI Driver allows you to get secret contents stored in an [Azure Key Vault instance](../key-vault/general/basic-concepts.md) and use the [Secrets Store CSI Driver](https://secrets-store-csi-driver.sigs.k8s.io/introduction.html) to mount them into Kubernetes pods. This article explains how to use Azure Key Vault Provider for Secrets Store CSI Driver on Azure Red Hat OpenShift. > [!NOTE]
-> Azure Key Vault Provider for Secrets Store CSI Driver is an Open Source project that works with Azure Red Hat OpenShift. While the instructions presented in this article show an example of how the Secrets Store CSI driver can be implemented, they are intended as a general guide to using the driver with ARO. Support for this implementation of an Open Source project would be provided by the project.
+> As an alternative to the open source solution presented in this article, you can use [Azure Arc](../azure-arc/overview.md) to manage your ARO clusters along with its [Azure Key Vault Provider for Secrets Store CSI Driver extension](../azure-arc/kubernetes/tutorial-akv-secrets-provider.md). This method is fully supported by Microsoft and is recommended instead of the open source solution below.
## Prerequisites
operator-nexus Howto Baremetal Review Read Output https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/operator-nexus/howto-baremetal-review-read-output.md
- Title: How to view the output of an `az networkcloud run-read-command` in the Operator Nexus Cluster Manager Storage account
-description: Step by step guide on locating the output of a `az networkcloud run-read-command` in the Cluster Manager Storage account.
---- Previously updated : 03/23/2023---
-# How to view the output of an `az networkcloud baremetalmachine run-read-command` in the Cluster Manager Storage account
-
-This guide walks you through accessing the output file that is created in the Cluster Manager Storage account when an `az networkcloud baremetalmachine run-read-command` is executed on a server. The name of the file is identified in the `az rest` status output.
-
-1. Open the Cluster Manager Managed Resource Group for the Cluster where the server is housed and then select the **Storage account**.
-
-1. In the Storage account details, select **Storage browser** from the navigation menu on the left side.
-
-1. In the Storage browser details, select on **Blob containers**.
-
-1. Select the baremetal-run-command-output blob container.
-
-1. Select the output file from the run-read command. The file name can be identified from the `az rest --method get` command. Additionally, the **Last modified** timestamp aligns with when the command was executed.
-
-1. You can manage & download the output file from the **Overview** pop-out.
-
-For information on running the `run-read-command`, see:
--- [Troubleshoot BMM issues using the run-read command](howto-baremetal-run-read.md)
operator-nexus Howto Baremetal Run Read https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/operator-nexus/howto-baremetal-run-read.md
In the response, an HTTP status code of 202 is returned as the operation is perf
## Checking command status and viewing output - Sample output looks something as below. It prints the top 4K characters of the result to the screen for convenience and provides a short-lived link to the storage blob containing the command execution result. You can use the link to download the zipped output file (tar.gz). ```output
Sample output looks something as below. It prints the top 4K characters of the r
198.51.102.1 ping statistics 3 packets transmitted, 0 received, 100% packet loss, time 2049ms -- ================================ Script execution result can be found in storage account: https://<storage_account_name>.blob.core.windows.net/bmm-run-command-output/a8e0a5fe-3279-46a8-b995-51f2f98a18dd-action-bmmrunreadcmd.tar.gz?se=2023-04-14T06%3A37%3A00Z&sig=XXX&sp=r&spr=https&sr=b&st=2023-04-14T02%3A37%3A00Z&sv=2019-12-12 ```
-See [How To BareMetal Review Output Run-Read](howto-baremetal-review-read-output.md) for instructions on locating the output file in the Storage Account. You can also use the link to directly access the output zip file.
+## How to view the output of an `az networkcloud baremetalmachine run-read-command` in the Cluster Manager Storage account
+
+This guide walks you through accessing the output file that is created in the Cluster Manager Storage account when an `az networkcloud baremetalmachine run-read-command` is executed on a server. The name of the file is identified in the `az rest` status output.
+
+1. Open the Cluster Manager Managed Resource Group for the Cluster where the server is housed and then select the **Storage account**.
+
+1. In the Storage account details, select **Storage browser** from the navigation menu on the left side.
+
+1. In the Storage browser details, select on **Blob containers**.
+
+1. Select the baremetal-run-command-output blob container.
+
+1. Select the output file from the run-read command. The file name can be identified from the `az rest --method get` command. Additionally, the **Last modified** timestamp aligns with when the command was executed.
+
+1. You can manage & download the output file from the **Overview** pop-out.
postgresql Concepts Monitoring https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/postgresql/flexible-server/concepts-monitoring.md
Title: Monitoring and metrics - Azure Database for PostgreSQL - Flexible Server
-description: This article describes monitoring and metrics features in Azure Database for PostgreSQL - Flexible Server.
+description: Review the monitoring and metrics features in Azure Database for PostgreSQL - Flexible Server.
Last updated 11/30/2021
[!INCLUDE [applies-to-postgresql-flexible-server](../includes/applies-to-postgresql-flexible-server.md)]
-Monitoring data about your servers helps you troubleshoot and optimize for your workload. Azure Database for PostgreSQL provides various monitoring options to provide insight into the behavior of your server.
+Monitoring data about your servers helps you troubleshoot and optimize for your workload. Azure Database for PostgreSQL provides various monitoring options to provide insight into how your server is performing.
## Metrics
-Azure Database for PostgreSQL provides various metrics that give insight into the behavior of the resources supporting the PostgreSQL server. Each metric is emitted at a one-minute frequency, and has up to [93 days of history](../../azure-monitor/essentials/data-platform-metrics.md#retention-of-metrics). You can configure alerts on the metrics. Other options include setting up automated actions, performing advanced analytics, and archiving history. For more information, see the [Azure Metrics Overview](../../azure-monitor/essentials/data-platform-metrics.md).
+
+Azure Database for PostgreSQL provides various metrics that give insight into the behavior of the resources that support the Azure Database for PostgreSQL server. Each metric is emitted at a 1-minute interval and has up to [93 days of history](../../azure-monitor/essentials/data-platform-metrics.md#retention-of-metrics). You can configure alerts on the metrics. Other options include setting up automated actions, performing advanced analytics, and archiving the history. For more information, see the [Azure Metrics overview](../../azure-monitor/essentials/data-platform-metrics.md).
### List of metrics
-The following metrics are available for PostgreSQL flexible server:
-
-|Display Name |Metric ID |Unit |Description |
-|-||-|-|
-|**Active Connections** |active_connections |Count |The number of connections to your server. |
-|**Backup Storage Used** |backup_storage_used |Bytes |Amount of backup storage used. This metric represents the sum of storage consumed by all the full backups, differential backups, and log backups retained based on the backup retention period set for the server. The frequency of the backups is service managed. For geo-redundant storage, backup storage usage is twice that of the locally redundant storage.|
-|**Failed Connections** |connections_failed |Count |Failed connections. |
-|**Succeeded Connections** |connections_succeeded |Count |Succeeded connections. |
-|**CPU Credits Consumed** |cpu_credits_consumed |Count |Number of credits used by the flexible server. Applicable to Burstable tier. |
-|**CPU Credits Remaining** |cpu_credits_remaining |Count |Number of credits available to burst. Applicable to Burstable tier. |
-|**CPU percent** |cpu_percent |Percent |Percentage of CPU in use. |
-|**Disk Queue Depth** |disk_queue_depth |Count |Number of outstanding I/O operations to the data disk. |
-|**IOPS** |iops |Count |Number of I/O operations to disk per second. |
-|**Maximum Used Transaction IDs**|maximum_used_transactionIDs|Count |Maximum transaction ID in use. |
-|**Memory percent** |memory_percent |Percent |Percentage of memory in use. |
-|**Network Out** |network_bytes_egress |Bytes |Amount of outgoing network traffic. |
-|**Network In** |network_bytes_ingress |Bytes |Amount of incoming network traffic. |
-|**Read IOPS** |read_iops |Count |Number of data disk I/O read operations per second. |
-|**Read Throughput** |read_throughput |Bytes |Bytes read per second from disk. |
-|**Storage Free** |storage_free |Bytes |The amount of storage space available. |
-|**Storage percent** |storage_percent |Percentage|Percent of storage space used. The storage used by the service may include the database files, transaction logs, and the server logs. |
-|**Storage Used** |storage_used |Bytes |Amount of storage space used. The storage used by the service may include the database files, transaction logs, and the server logs. |
-|**Transaction Log Storage Used**|txlogs_storage_used |Bytes |Amount of storage space used by the transaction logs. |
-|**Write Throughput** |write_throughput |Bytes |Bytes written per second to disk. |
-|**Write IOPS** |write_iops |Count |Number of data disk I/O write operations per second. |
-
-## Enhanced Metrics
-
-Introducing Enhanced Metrics for Azure Database for PostgreSQL Flexible Server to enable more fine grained monitoring and alerting on databases. You can configure alerts on the metrics. In addition, some of these new Metrics now also include ΓÇÿDimensionΓÇÖ that will allow to split and filter the metrics data by using the allowed dimension such as Database Name, State etc.
-
-#### Enabling enhanced metrics
--- Most of these new metrics are _disabled_ by default, barring a few exceptions (per the list below) -- To enable these metrics, please turn ON the server parameter `metrics.collector_database_activity`. This parameter is dynamic, and will not require instance restart.-
-#### List of enhanced metrics
-
-##### Activity
-
-|Display Name |Metric ID |Unit |Description |Dimension |Default enabled |
-||-|-||||
-|**Sessions By State** (Preview) |sessions_by_state |Count |Overall state of the backends |State |No |
-|**Sessions By WaitEventType** (Preview)|sessions_by_wait_event_type |Count |Sessions by the type of event for which the backend is waiting |Wait Event Type|No |
-|**Oldest Backend** (Preview) |oldest_backend_time_sec |Seconds|The age in seconds of the oldest backend (irrespective of the state) |N/a |No |
-|**Oldest Query** (Preview) |longest_query_time_sec |Seconds|The age in seconds of the longest query that is currently running |N/a |No |
-|**Oldest Transaction** (Preview) |longest_transaction_time_sec|Seconds|The age in seconds of the longest transaction (including idle transactions) |N/a |No |
-|**Oldest xmin** (Preview) |oldest_backend_xmin |Count |The actual value of the oldest xmin. If xmin is not increasing it indicates there are some long running transactions that can potentially hold dead tuples from being removed |N/a |No |
-|**Oldest xmin Age** (Preview) |oldest_backend_xmin_age |Count |Age in units of the oldest xmin. It indicated how many transactions passed since oldest xmin |N/a |No |
-
-##### Database
-
-|Display Name |Metric ID |Unit |Description |Dimension |Default enabled |
-|-|-|--|-|-||
-|**Backends** (Preview) |numbackends |Count|Number of backends connected to this database |Database Name|No |
-|**Deadlocks** (Preview) |deadlocks |Count|Number of deadlocks detected in this database |Database Name|No |
-|**Disk Blocks Hit** (Preview) |blks_hit |Count|Number of times disk blocks were found already in the buffer cache, so that a read was not necessary|Database Name|No |
-|**Disk Blocks Read** (Preview) |blks_read |Count|Number of disk blocks read in this database |Database Name|No |
-|**Temporary Files** (Preview) |temp_files |Count|Number of temporary files created by queries in this database |Database Name|No |
-|**Temporary Files Size** (Preview) |temp_bytes |Bytes|Total amount of data written to temporary files by queries in this database |Database Name|No |
-|**Total Transactions** (Preview) |xact_total |Count|Number of total transactions executed in this database |Database Name|No |
-|**Transactions Committed** (Preview) |xact_commit |Count|Number of transactions in this database that have been committed |Database Name|No |
-|**Transactions Rolled back** (Preview) |xact_rollback|Count|Number of transactions in this database that have been rolled back |Database Name|No |
-|**Tuples Deleted** (Preview) |tup_deleted |Count|Number of rows deleted by queries in this database |Database Name|No |
-|**Tuples Fetched** (Preview) |tup_fetched |Count|Number of rows fetched by queries in this database |Database Name|No |
-|**Tuples Inserted** (Preview) |tup_inserted |Count|Number of rows inserted by queries in this database |Database Name|No |
-|**Tuples Returned** (Preview) |tup_returned |Count|Number of rows returned by queries in this database |Database Name|No |
-|**Tuples Updated** (Preview) |tup_updated |Count|Number of rows updated by queries in this database |Database Name|No |
-
-##### Logical Replication
-
-|Display Name |Metric ID |Unit |Description |Dimension|Default enabled |
-|-|-|--||||
-|**Max Logical Replication Lag** (Preview)|logical_replication_delay_in_bytes|Bytes|Maximum lag across all logical replication slots|N/a |Yes |
-
-##### Replication
-
-|Display Name |Metric ID |Unit |Description |Dimension|Default enabled |
-|--|-|-|--|||
-|**Max Physical Replication Lag** (Preview)|physical_replication_delay_in_bytes |Bytes |Maximum lag across all asynchronous physical replication slots|N/a |Yes |
-|**Read Replica Lag** (Preview) |physical_replication_delay_in_seconds|Seconds|Read Replica lag in seconds |N/a |Yes |
--
-##### Saturation
-
-|Display Name |Metric ID |Unit |Description |Dimension|Default enabled |
-||-|-|--|||
-|**Disk Bandwidth Consumed Percentage**|disk_bandwidth_consumed_percentage|Percent|Percentage of data disk bandwidth consumed per minute|N/a |Yes |
-|**Disk IOPS Consumed Percentage** |disk_iops_consumed_percentage |Percent|Percentage of data disk I/Os consumed per minute |N/a |Yes |
-
-##### Traffic
-
-|Display Name|Metric ID |Unit |Description |Dimension|Default enabled |
-|-||--||||
-|**Max Connections^** |max_connections|Count|Max Connections |N/a |Yes |
-
-^ **Max Connections** here represents the configured value for _max_connections_ server parameter, and this metric is pooled every 30 minutes.
-
-#### Considerations when using the enhanced metrics
--- There is **50 database** limit on metrics with `database name` dimension.
- * On **Burstable** SKU - this limit is 10 `database name` dimension
-- `database name` dimension limit is applied on OiD column (in other words _Order-of-Creation_ of the database)-- The `database name` in metrics dimension is **case insensitive**. Therefore the metrics for same database names in varying case (_ex. foo, FoO, FOO_) will be merged, and may not show accurate data.+
+The following metrics are available for a flexible server instance of Azure Database for PostgreSQL:
+
+|Display name|Metric ID|Unit|Description|
+|||||
+|**Active Connections**|`active_connections`|Count|Number of connections to your server.|
+|**Backup Storage Used**|`backup_storage_used`|Bytes|Amount of backup storage used. This metric represents the sum of storage that's consumed by all the full backups, differential backups, and log backups that are retained based on the backup retention period that's set for the server. The frequency of the backups is service managed. For geo-redundant storage, backup storage usage is twice the usage for locally redundant storage.|
+|**Failed Connections**|`connections_failed`|Count|Number of failed connections.|
+|**Succeeded Connections** |`connections_succeeded`|Count |Number of succeeded connections.|
+|**CPU Credits Consumed**|`cpu_credits_consumed` |Count |Number of credits used by the flexible server. Applies to the Burstable tier.|
+|**CPU Credits Remaining** |`cpu_credits_remaining`|Count |Number of credits available to burst. Applies to the Burstable tier. |
+|**CPU percent** |`cpu_percent`|Percent |Percentage of CPU in use.|
+|**Disk Queue Depth**|`disk_queue_depth` |Count |Number of outstanding I/O operations to the data disk.|
+|**IOPS**|`iops` |Count |Number of I/O operations to disk per second.|
+|**Maximum Used Transaction IDs**|`maximum_used_transactionIDs`|Count |Maximum number of transaction IDs in use. |
+|**Memory percent**|`memory_percent` |Percent |Percentage of memory in use. |
+|**Network Out** |`network_bytes_egress` |Bytes |Amount of outgoing network traffic.|
+|**Network In**|`network_bytes_ingress`|Bytes |Amount of incoming network traffic.|
+|**Read IOPS** |`read_iops`|Count |Number of data disk I/O read operations per second. |
+|**Read Throughput** |`read_throughput`|Bytes |Bytes read per second from disk. |
+|**Storage Free**|`storage_free` |Bytes |Amount of storage space that's available.|
+|**Storage percent** |`storage_percent`|Percentage|Percent of storage space that's used. The storage that's used by the service can include database files, transaction logs, and server logs.|
+|**Storage Used**|`storage_used` |Bytes |Amount of storage space that's used. The storage that's used by the service can include the database files, transaction logs, and the server logs.|
+|**Transaction Log Storage Used**|`txlogs_storage_used`|Bytes |Amount of storage space that's used by the transaction logs. |
+|**Write Throughput**|`write_throughput` |Bytes |Bytes written to disk per second.|
+|**Write IOPS**|`write_iops` |Count |Number of data disk I/O write operations per second.|
+
+## Enhanced metrics
+
+You can use enhanced metrics for Azure Database for PostgreSQL - Flexible Server to get fine-grained monitoring and alerting on databases. You can configure alerts on the metrics.
+
+Some enhanced metrics include a `Dimension` parameter that you can use to split and filter metrics data by using a dimension like database name or state.
+
+### Enable enhanced metrics
+
+- Most of these new metrics are *disabled* by default. A few exceptions are described in the next table.
+- To enable these metrics, set the server parameter `metrics.collector_database_activity` to `ON`. This parameter is dynamic and doesn't require an instance restart.
+
+### List of enhanced metrics
+
+You can choose from the following categories of enhanced metrics:
+
+- Activity
+- Database
+- Logical replication
+- Replication
+- Saturation
+- Traffic
+
+#### Activity
+
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Sessions By State** (Preview)|`sessions_by_state` |Count|Overall state of the back ends. |State|No|
+|**Sessions By WaitEventType** (Preview)|`sessions_by_wait_event_type` |Count|Sessions by the type of event for which the back end is waiting.|Wait Event Type|No|
+|**Oldest Backend** (Preview) |`oldest_backend_time_sec` |Seconds|Age in seconds of the oldest back end (irrespective of the state).|Doesn't apply|No|
+|**Oldest Query** (Preview) |`longest_query_time_sec`|Seconds|Age in seconds of the longest query that's currently running. |Doesn't apply|No|
+|**Oldest Transaction** (Preview) |`longest_transaction_time_sec`|Seconds|Age in seconds of the longest transaction (including idle transactions).|Doesn't apply|No|
+|**Oldest xmin** (Preview)|`oldest_backend_xmin`|Count|The actual value of the oldest `xmin`. If `xmin` isn't increasing, it indicates that there are some long-running transactions that can potentially hold dead tuples from being removed. |Doesn't apply|No|
+|**Oldest xmin Age** (Preview)|`oldest_backend_xmin_age`|Count|Age in units of the oldest `xmin`. Indicates how many transactions passed since the oldest `xmin`. |Doesn't apply|No|
+
+#### Database
+
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Backends** (Preview) |`numbackends`|Count|Number of back ends that are connected to this database.|DatabaseName|No|
+|**Deadlocks** (Preview)|`deadlocks` |Count|Number of deadlocks that are detected in this database.|DatabaseName|No|
+|**Disk Blocks Hit** (Preview)|`blks_hit` |Count|Number of times disk blocks were found already in the buffer cache, so that a read wasn't necessary.|DatabaseName|No|
+|**Disk Blocks Read** (Preview) |`blks_read`|Count|Number of disk blocks that were read in this database.|DatabaseName|No|
+|**Temporary Files** (Preview)|`temp_files` |Count|Number of temporary files that were created by queries in this database. |DatabaseName|No|
+|**Temporary Files Size** (Preview) |`temp_bytes` |Bytes|Total amount of data that's written to temporary files by queries in this database. |DatabaseName|No|
+|**Total Transactions** (Preview) |`xact_total` |Count|Number of total transactions that executed in this database. |DatabaseName|No|
+|**Transactions Committed** (Preview) |`xact_commit`|Count|Number of transactions in this database that have been committed.|DatabaseName|No|
+|**Transactions Rolled back** (Preview) |`xact_rollback`|Count|Number of transactions in this database that have been rolled back.|DatabaseName|No|
+|**Tuples Deleted** (Preview) |`tup_deleted`|Count|Number of rows that were deleted by queries in this database. |DatabaseName|No|
+|**Tuples Fetched** (Preview) |`tup_fetched`|Count|Number of rows that were fetched by queries in this database. |DatabaseName|No|
+|**Tuples Inserted** (Preview)|`tup_inserted` |Count|Number of rows that were inserted by queries in this database.|DatabaseName|No|
+|**Tuples Returned** (Preview)|`tup_returned` |Count|Number of rows that were returned by queries in this database.|DatabaseName|No|
+|**Tuples Updated** (Preview) |`tup_updated`|Count|Number of rows that were updated by queries in this database. |DatabaseName|No|
+
+#### Logical replication
+
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Max Logical Replication Lag** (Preview)|`logical_replication_delay_in_bytes`|Bytes|Maximum lag across all logical replication slots.|Doesn't apply|Yes |
+
+#### Replication
+
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Max Physical Replication Lag** (Preview)|`physical_replication_delay_in_bytes`|Bytes|Maximum lag across all asynchronous physical replication slots.|Doesn't apply|Yes |
+|**Read Replica Lag** (Preview)|`physical_replication_delay_in_seconds`|Seconds|Read replica lag in seconds. |Doesn't apply|Yes |
+
+#### Saturation
+
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Disk Bandwidth Consumed Percentage**|`disk_bandwidth_consumed_percentage`|Percent|Percentage of data disk bandwidth consumed per minute.|Doesn't apply|Yes |
+|**Disk IOPS Consumed Percentage** |`disk_iops_consumed_percentage` |Percent|Percentage of data disk I/Os consumed per minute. |Doesn't apply|Yes |
+
+#### Traffic
+
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Max Connections** ^|`max_connections`|Count|Number of maximum connections. |Doesn't apply|Yes |
+
+^ **Max Connections** represents the configured value for the `_max_connections_ server` parameter. This metric is pooled every 30 minutes.
+
+#### Considerations for using enhanced metrics
+
+- Enhanced metrics that use the DatabaseName dimension have a *50-database* limit.
+- On the *Burstable* SKU, the limit is 10 databases for metrics that use the DatabaseName dimension.
+- The DatabaseName dimension limit is applied on the object identifier (OID) column, which reflects the order of creation for the database.
+- The DatabaseName in the metrics dimension is *case insensitive*. The metrics for database names that are the same except for case (for example, *contoso_database* and *Contoso_database*) will be merged and might not show accurate data.
## Autovacuum metrics
-Autovaccum metrics can be used to monitor and tune autovaccum performance for Azure database for postgres flexible server. Each metric is emitted at a **30 minute** frequency, and has up to **93 days** of retention. Customers can configure alerts on the metrics and can also access the new metrics dimensions, to split and filter the metrics data on database name.
+Autovaccum metrics can be used to monitor and tune autovaccum performance for Azure Database for PostgresSQL - Flexible Server. Each metric is emitted at a *30-minute* interval and has up to *93 days* of retention. You can create alerts for specific metrics, and you can split and filter metrics data by using the DatabaseName dimension.
+
+### Enable autovacuum metrics
-#### Enabling Autovacuum metrics
-* Autovacuum metrics are disabled by default
-* To enable these metrics, please turn ON the server parameter `metrics.autovacuum_diagnostics`.
- * This parameter is dynamic, hence will not require instance restart.
+- Autovacuum metrics are disabled by default.
+- To enable these metrics, set the server parameter `metrics.autovacuum_diagnostics` to `ON`.
+- This parameter is dynamic, so an instance restart isn't required.
-#### List of Autovacuum metrics
+### List of autovacuum metrics
-|Display Name |Metric ID |Unit |Description |Dimension |Default enabled|
-|-|-|--|--|||
-|**Analyze Counter User Tables** (Preview) |analyze_count_user_tables |Count|Number of times user only tables have been manually analyzed in this database |DatabaseName|No |
-|**AutoAnalyze Counter User Tables** (Preview) |autoanalyze_count_user_tables |Count|Number of times user only tables have been analyzed by the autovacuum daemon in this database |DatabaseName|No |
-|**AutoVacuum Counter User Tables** (Preview) |autovacuum_count_user_tables |Count|Number of times user only tables have been vacuumed by the autovacuum daemon in this database |DatabaseName|No |
-|**Estimated Dead Rows User Tables** (Preview) |n_dead_tup_user_tables |Count|Estimated number of dead rows for user only tables in this database |DatabaseName|No |
-|**Estimated Live Rows User Tables** (Preview) |n_live_tup_user_tables |Count|Estimated number of live rows for user only tables in this database |DatabaseName|No |
-|**Estimated Modifications User Tables** (Preview)|n_mod_since_analyze_user_tables|Count|Estimated number of rows modified since user only tables were last analyzed |DatabaseName|No |
-|**User Tables Analyzed** (Preview) |tables_analyzed_user_tables |Count|Number of user only tables that have been analyzed in this database |DatabaseName|No |
-|**User Tables AutoAnalyzed** (Preview) |tables_autoanalyzed_user_tables|Count|Number of user only tables that have been analyzed by the autovacuum daemon in this database |DatabaseName|No |
-|**User Tables AutoVacuumed** (Preview) |tables_autovacuumed_user_tables|Count|Number of user only tables that have been vacuumed by the autovacuum daemon in this database |DatabaseName|No |
-|**User Tables Counter** (Preview) |tables_counter_user_tables |Count|Number of user only tables in this database |DatabaseName|No |
-|**User Tables Vacuumed** (Preview) |tables_vacuumed_user_tables |Count|Number of user only tables that have been vacuumed in this database |DatabaseName|No |
-|**Vacuum Counter User Tables** (Preview) |vacuum_count_user_tables |Count|Number of times user only tables have been manually vacuumed in this database (not counting VACUUM FULL)|DatabaseName|No |
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Analyze Counter User Tables** (Preview)|`analyze_count_user_tables`|Count|Number of times user-only tables have been manually analyzed in this database. |DatabaseName|No |
+|**AutoAnalyze Counter User Tables** (Preview)|`autoanalyze_count_user_tables`|Count|Number of times user-only tables have been analyzed by the autovacuum daemon in this database. |DatabaseName|No |
+|**AutoVacuum Counter User Tables** (Preview) |`autovacuum_count_user_tables` |Count|Number of times user-only tables have been vacuumed by the autovacuum daemon in this database. |DatabaseName|No |
+|**Estimated Dead Rows User Tables** (Preview)|`n_dead_tup_user_tables` |Count|Estimated number of dead rows for user-only tables in this database. |DatabaseName|No |
+|**Estimated Live Rows User Tables** (Preview)|`n_live_tup_user_tables` |Count|Estimated number of live rows for user-only tables in this database. |DatabaseName|No |
+|**Estimated Modifications User Tables** (Preview)|`n_mod_since_analyze_user_tables`|Count|Estimated number of rows that were modified since user-only tables were last analyzed. |DatabaseName|No |
+|**User Tables Analyzed** (Preview) |`tables_analyzed_user_tables`|Count|Number of user-only tables that have been analyzed in this database. |DatabaseName|No |
+|**User Tables AutoAnalyzed** (Preview) |`tables_autoanalyzed_user_tables`|Count|Number of user-only tables that have been analyzed by the autovacuum daemon in this database.|DatabaseName|No |
+|**User Tables AutoVacuumed** (Preview) |`tables_autovacuumed_user_tables`|Count|Number of user-only tables that have been vacuumed by the autovacuum daemon in this database.|DatabaseName|No |
+|**User Tables Counter** (Preview)|`tables_counter_user_tables` |Count|Number of user-only tables in this database.|DatabaseName|No |
+|**User Tables Vacuumed** (Preview) |`tables_vacuumed_user_tables`|Count|Number of user-only tables that have been vacuumed in this database. |DatabaseName|No |
+|**Vacuum Counter User Tables** (Preview) |`vacuum_count_user_tables` |Count|Number of times user-only tables have been manually vacuumed in this database (not counting `VACUUM FULL`).|DatabaseName|No |
-#### Considerations when using the autovacuum metrics
+### Considerations for using autovacuum metrics
-- There is **30 database** limit on metrics with `database name` dimension.
- * On **Burstable** SKU - this limit is 10 `database name` dimension
-- `database name` dimension limit is applied on OiD column (in other words _Order-of-Creation_ of the database)
+- Autovacuum metrics that use the DatabaseName dimension have a *30-database* limit.
+- On the *Burstable* SKU, the limit is 10 databases for metrics that use the DatabaseName dimension.
+- The DatabaseName dimension limit is applied on the OID column, which reflects the order of creation for the database.
## PgBouncer metrics
-PgBouncer metrics can be used for monitoring the performance of PgBouncer process, including details for active connections, Idle connections, Total pooled connections, number of connection pools etc. Each metric is emitted at a **30 minute** frequency and has up to **93 days** of history. Customers can configure alerts on the metrics and can also access the new metrics dimensions, to split and filter the metrics data on database name.
+You can use PgBouncer metrics to monitor the performance of the PgBouncer process, including details for active connections, idle connections, total pooled connections, and the number of connection pools. Each metric is emitted at a *30-minute* interval and has up to *93 days* of history. Customers can configure alerts on the metrics and also access the new metrics dimensions to split and filter metrics data by database name.
+
+### Enable PgBouncer metrics
+
+- PgBouncer metrics are disabled by default.
+- For PgBouncer metrics to work, both the server parameters `pgbouncer.enabled` and `metrics.pgbouncer_diagnostics` must be enabled.
+- These parameters are dynamic and don't require an instance restart.
+
+### List of PgBouncer metrics
-#### Enabling PgBouncer metrics
-* PgBouncer metrics are disabled by default.
-* For Pgbouncer metrics to work, both the server parameters `pgbouncer.enabled` and `metrics.pgbouncer_diagnostics` have to be enabled.
- * These parameters are dynamic, and will not require instance restart.
+|Display name|Metric ID|Unit|Description|Dimension|Default enabled|
+|||||||
+|**Active client connections** (Preview) |`client_connections_active` |Count|Connections from clients that are associated with an Azure Database for PostgreSQL connection. |DatabaseName|No |
+|**Waiting client connections** (Preview)|`client_connections_waiting`|Count|Connections from clients that are waiting for an Azure Database for PostgreSQL connection to service them.|DatabaseName|No |
+|**Active server connections** (Preview) |`server_connections_active` |Count|Connections to Azure Database for PostgreSQL that are in use by a client connection. |DatabaseName|No |
+|**Idle server connections** (Preview) |`server_connections_idle` |Count|Connections to Azure Database for PostgreSQL that are idle and ready to service a new client connection. |DatabaseName|No |
+|**Total pooled connections** (Preview)|`total_pooled_connections`|Count|Current number of pooled connections. |DatabaseName|No |
+|**Number of connection pools** (Preview)|`num_pools` |Count|Total number of connection pools. |DatabaseName|No |
-#### List of PgBouncer metrics
+### Considerations for using the PgBouncer metrics
-|Display Name |Metrics ID |Unit |Description |Dimension |Default enabled|
-|-|--|--|-|||
-|**Active client connections** (Preview) |client_connections_active |Count|Connections from clients which are associated with a PostgreSQL connection |DatabaseName|No |
-|**Waiting client connections** (Preview)|client_connections_waiting|Count|Connections from clients that are waiting for a PostgreSQL connection to service them|DatabaseName|No |
-|**Active server connections** (Preview) |server_connections_active |Count|Connections to PostgreSQL that are in use by a client connection |DatabaseName|No |
-|**Idle server connections** (Preview) |server_connections_idle |Count|Connections to PostgreSQL that are idle, ready to service a new client connection |DatabaseName|No |
-|**Total pooled connections** (Preview) |total_pooled_connections |Count|Current number of pooled connections |DatabaseName|No |
-|**Number of connection pools** (Preview)|num_pools |Count|Total number of connection pools |DatabaseName|No |
+- PgBouncer metrics that use the DatabaseName dimension have a *30-database* limit.
+- On the *Burstable* SKU, the limit is 10 databases that have the DatabaseName dimension.
+- The DatabaseName dimension limit is applied to the OID column, which reflects the order of creation for the database.
-#### Considerations when using the PgBouncer metrics
+## Database availability metric
-- There is **30 database** limit on metrics with `database name` dimension.
- * On **Burstable** SKU - this limit is 10 `database name` dimension.
-- `database name` dimension limit is applied on OiD column (in other words _Order-of-Creation_ of the database)
+Is-db-alive is an database server availability metric for Azure Postgres Flexible Server, that returns boolean `[1 for available]` and `[0 for not-available]`. Each metric is emitted at a *1 minute* frequency, and has up to *93 days* of retention. Customers can configure alerts on the metric.
-## Applying filters and splitting on metrics with dimension
+|Display Name |Metric ID |Unit |Description |Dimension |Default enabled|
+|-|-|-|--|||
+|**Database Is Alive** (Preview) |is-db-alive |Boolean|Indicates if the database is up or not |N/a |Yes |
-In the above list of metrics, some of the metrics have dimension such as `database name`, `state` etc. [Filtering](../../azure-monitor/essentials/metrics-charts.md#filters) and [Splitting](../../azure-monitor/essentials/metrics-charts.md#apply-splitting) are allowed for the metrics that have dimensions. These features show how various metric segments ("dimension values") affect the overall value of the metric. You can use them to identify possible outliers.
+#### Considerations when using the Database availability metrics
-* **Filtering** lets you choose which dimension values are included in the chart. For example, you might want to show idle connections when you chart the `Sessions-by-State` metric. You apply the filter on the __idle__ on __state__ dimension.
-* **Splitting** controls whether the chart displays separate lines for each value of a dimension or aggregates the values into a single line. For example, you can see one line for an `Sessions-by-State` metric across all sessions. Or you can see separate lines for each session grouped by their `state`. You apply splitting on the `State` dimension to see separate lines.
+- Aggregating this metric with `MAX()` will allow customers to determine weather the server has been up or down in the last minute.
+- Customers have option to further aggregate these metrics with any desired frequency (5m, 10m, 30m etc.) to suit their alerting requirements and avoid any false positive.
+- Other possible aggregations are `AVG()` and `MIN()`
-Here in this example below, we have done **splitting** by `State` dimension and **filtered** on a specific `state` types.
+## Filter and split on dimension metrics
-![Screenshot of sessions by state.](https://user-images.githubusercontent.com/19426853/196329577-dc1c1cc0-4fcb-4ab7-a466-025425d57844.png)
+In the preceding tables, some metrics have dimensions like DatabaseName or State. You can use [filtering](../../azure-monitor/essentials/metrics-charts.md#filters) and [splitting](../../azure-monitor/essentials/metrics-charts.md#apply-splitting) for the metrics that have dimensions. These features show how various metric segments (or *dimension values*) affect the overall value of the metric. You can use them to identify possible outliers.
-For more details on setting-up charts with dimensional metrics, see [Metric chart examples](../../azure-monitor/essentials/metric-chart-samples.md)
+- **Filtering**: Use filtering to choose which dimension values are included in the chart. For example, you might want to show idle connections when you chart the `Sessions-by-State` metric. You set the filter for Idle in the State dimension.
+- **Splitting**: Use splitting to control whether the chart displays separate lines for each value of a dimension or if it aggregates the values in a single line. For example, you can see one line for a `Sessions-by-State` metric across all sessions. You can see separate lines for each session grouped by State value. Apply splitting on the State dimension to see separate lines.
+
+The following example demonstrates splitting by the State dimension and filtering on specific State values:
++
+For more information about setting up charts for dimensional metrics, see [Metric chart examples](../../azure-monitor/essentials/metric-chart-samples.md).
## Server logs
-In addition to the metrics, Azure Database for PostgreSQL also allows you to configure and access PostgreSQL standard logs. To learn more about logs, visit the [logging concepts doc](concepts-logging.md).
+
+In addition to the metrics, you can use Azure Database for PostgreSQL to configure and access Azure Database for PostgreSQL standard logs. For more information, see [Logging concepts](concepts-logging.md).
+
+## Next steps
+
+- Learn more about how to [configure and access logs](howto-configure-and-access-logs.md).
+- Learn more about [Azure Monitor pricing](https://azure.microsoft.com/pricing/details/monitor/).
+- Learn more about [audit logs](concepts-audit.md).
postgresql How To Troubleshooting Guides https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/postgresql/flexible-server/how-to-troubleshooting-guides.md
In this article, you'll learn how to use Troubleshooting guides for Azure Databa
## Prerequisites To effectively troubleshoot specific issue, you need to make sure you have all the necessary data in place.
-Each troubleshooting guide requires a specific set of data, which is sourced from three separate features: [Diagnostic settings](howto-configure-and-access-logs.md), [Query Store](concepts-query-store.md), and [Enhanced Metrics](concepts-monitoring.md#enabling-enhanced-metrics).
+Each troubleshooting guide requires a specific set of data, which is sourced from three separate features: [Diagnostic settings](howto-configure-and-access-logs.md), [Query Store](concepts-query-store.md), and [Enhanced Metrics](concepts-monitoring.md#enable-enhanced-metrics).
All troubleshooting guides require logs to be sent to the Log Analytics workspace, but the specific category of logs to be captured may vary depending on the particular guide. Please follow the steps described in the [Configure and Access Logs in Azure Database for PostgreSQL - Flexible Server](howto-configure-and-access-logs.md) article to configure diagnostic settings and send the logs to the Log Analytics workspace.
postgresql Release Notes https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/postgresql/flexible-server/release-notes.md
This page provides latest news and updates regarding feature additions, engine v
## Release: April 2023 * Public preview of [Query Performance Insight](./concepts-query-performance-insight.md) for Azure Database for PostgreSQL ΓÇô Flexible Server. * General availability: [Power BI integration](./connect-with-power-bi-desktop.md) for Azure Database for PostgreSQL ΓÇô Flexible Server.
+* Public preview of [Troubleshooting guides](./concepts-troubleshooting-guides.md) for Azure Database for PostgreSQL ΓÇô Flexible Server.
## Release: March 2023 * General availability of [Read Replica](concepts-read-replicas.md) for Azure Database for PostgreSQL ΓÇô Flexible Server.
sap Bom Prepare https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/sap/automation/bom-prepare.md
The [SAP on Azure Deployment Automation Framework](deployment-framework.md) uses a Bill of Materials (BOM). The BOM helps configure your SAP systems.
-The automation framework's GitHub repository contains a set of [Sample BOMs](https://github.com/Azure/sap-automation/tree/main/deploy/ansible/BOM-catalog) that you can use to get started. It is also possible to create BOMs for other SAP Applications and databases.
+The automation framework's GitHub repository contains a set of [Sample BOMs](https://github.com/Azure/sap-automation/tree/main/training-materials/WORKSPACES/BOMS) that you can use to get started. It is also possible to create BOMs for other SAP Applications and databases.
If you want to generate a BOM that includes permalinks, [follow the steps for creating this type of BOM](#permalinks).
To generate a BOM with permalinks:
The following sample is a small part of an example BOM file for S/4HANA 1909 SP2.
-You can find multiple complete, usable BOM files in the [GitHub repository](https://github.com/Azure/sap-automation/tree/main/deploy/ansible/BOM-catalog) folder.
+You can find multiple complete, usable BOM files in the [GitHub repository](https://github.com/Azure/sap-automation/tree/main/training-materials/WORKSPACES/BOMS) folder.
```yml step|BOM Content
sap Run Ansible https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/sap/automation/run-ansible.md
The following tasks are executed on Linux virtual machines:
- Ensures that the Azure virtual machine agent is configured correctly - Ensures that all the repositories are registered and enabled - Ensures that all the packaged are installed
+- Creates to volume groups and logical volumes
+- Configures the kernel parameters
+- Configures routing for additional network interfaces (if required)
+- Crates the user accounts and groups
+- Configures the banners displayed when logged in
+- Configures the services required
+ # [Windows](#tab/windows) - Ensures that all the components are installed
+ - StorageDsc
+ - NetworkingDsc
+ - ComputerManagementDsc
+ - PSDesiredStateConfiguration
+ - WindowsDefender
+ - ServerManager
+ - SecurityPolicyDsc
+ - Visual C++ runtime libraries
+ - ODBC Drivers
+- Configures the swap file size
+- Initializes the disks
+- Configures Windows Firewall
+- Joins the virtual machine to the specified domain
+### SAP Specific Operating System Configuration
+
+The SAP Specific Operating System Configuration playbook is used to configure the operating system of the SAP virtual machines. The playbook performs the following tasks:
+
+# [Linux](#tab/linux)
+
+The following tasks are executed on Linux virtual machines:
+- Configures the hosts file
+- Ensures that all the SAP specific repositories are registered and enabled
+- Ensures that all the SAP specific packaged are installed
+- Performs the disk mount operations
+- Configures the SAP specific services
+- Implements configurations defined in the relevant SAP Notes
+
+# [Windows](#tab/windows)
+
+- Connects to the Windows file shares
++++
security Feature Availability https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/security/fundamentals/feature-availability.md
The following table displays the current Defender for Cloud feature availability
| <li> [Auto provisioning for agents and extensions](../../defender-for-cloud/monitoring-components.md) | GA | GA | | <li> [Asset inventory](../../defender-for-cloud/asset-inventory.md) | GA | GA | | <li> [Azure Monitor Workbooks reports in Microsoft Defender for Cloud's workbooks gallery](../../defender-for-cloud/custom-dashboards-azure-workbooks.md) | GA | GA |
-| <li> [Integration with Microsoft Defender for Cloud Apps](../../defender-for-cloud/other-threat-protections.md#display-recommendations-in-microsoft-defender-for-cloud-apps) | GA | Not Available |
| **Microsoft Defender plans and extensions** | | | | <li> [Microsoft Defender for servers](../../defender-for-cloud/defender-for-servers-introduction.md) | GA | GA | | <li> [Microsoft Defender for App Service](../../defender-for-cloud/defender-for-app-service-introduction.md) | GA | Not Available |
sentinel Whats New https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/sentinel/whats-new.md
description: This article describes new features in Microsoft Sentinel from the
Previously updated : 03/27/2023 Last updated : 05/01/2023 # What's new in Microsoft Sentinel
See these [important announcements](#announcements) about recent changes to feat
[!INCLUDE [reference-to-feature-availability](includes/reference-to-feature-availability.md)]
+## April 2023
+
+- [RSA announcements](https://techcommunity.microsoft.com/t5/microsoft-sentinel-blog/rsac-2023-microsoft-sentinel-empowering-the-soc-with-next-gen/ba-p/3803613)
+- [Manage multiple workspaces with workspace manager](#manage-multiple-workspaces-with-workspace-manager-preview)
+
+### Manage multiple workspaces with workspace manager (Preview)
+
+Centrally manage Microsoft Sentinel at scale with Workspace Manager. Whether you're working across workspaces or Azure AD tenants, workspace manager reduces the complexity.
+
+Learn more about [Microsoft Sentinel workspace manager](workspace-manager.md).
+ ## March 2023 - [Microsoft Sentinel for SAP® BTP solution (Preview)](#microsoft-sentinel-solution-for-sap-btp-preview)
To give you more flexibility in scheduling your analytics rule execution times a
[Learn more about advanced scheduling](detect-threats-custom.md#query-scheduling-and-alert-threshold).
-## January 2023
--- [New incident investigation experience (Preview)](#new-incident-investigation-experience-preview)-- [Monitor SAP system health (Preview)](#monitor-sap-system-health-and-role-preview)-- [Microsoft Purview Information Protection connector (Preview)](#microsoft-purview-information-protection-connector-preview)-
-### New incident investigation experience (Preview)
-
-SOC analysts need to understand the full scope of an attack as fast as possible to respond effectively.
-
-While triaging, investigating, and responding to a security incident, analysts require quick and seamless access to many pieces of information, actions, and tools. This access should optimally be within the incident investigation environment, with an absolute minimum of pivoting to other pages, products, or services&mdash;for example, to find Azure AD info or the geo-location of an IP, edit a bookmark, or add an entity to threat intelligence.
-
-**Microsoft Sentinel now offers a new incident investigation experience**. The new incident page design, along with many new features for investigation, response, and incident management, offers the analyst the information and tools necessary to understand the incident and the scope of breach, while making navigation easy and context switching less frequent. New features include, among others, top insights, a new activity log for incident audits and a Log Analytics query window to investigate logs.
-
-Learn more about the new investigation experience:
-- [Understand Microsoft Sentinel's incident investigation and case management capabilities](incident-investigation.md)-- [Navigate and investigate incidents in Microsoft Sentinel](investigate-incidents.md)-
-### Monitor SAP system health and role (Preview)
-
-To ensure proper functioning and performance of your SAP systems, you can now use the SAP data connector page to [monitor information about the health of your SAP systems](monitor-sap-system-health.md) and the status of the SAP roles for the system. You can also use an alert rule template to get information about the health of the SAP agent's data collection.
-
-### Microsoft Purview Information Protection connector (Preview)
-
-With the new [Microsoft Purview Information Protection connector](connect-microsoft-purview.md), you can stream data from Microsoft Purview Information Protection (formerly Microsoft Information Protection or MIP) to Microsoft Sentinel. You can use the data ingested from the Microsoft Purview labeling clients and scanners to track, analyze, report on the data, and use it for compliance purposes.
-
-> [!IMPORTANT]
-> This connector replaces the Azure Information Protection (AIP) data connector, aligned with the retirement of the AIP analytics and audit logs public preview as of **March 31, 2023**.
-
-The new connector streams audit logs into the standardized
-`MicrosoftPurviewInformationProtection` table, which has been adjusted to enhance the deprecated schema used by AIP, with more fields and easier access to parameters. Data is gathered through the [Office Management API](/office/office-365-management-api/office-365-management-activity-api-schema), which uses a structured schema. Review the list of supported [audit log record types and activities](microsoft-purview-record-types-activities.md).
-
-## December 2022
--- [Create and run playbooks on entities on-demand (Preview)](#create-and-run-playbooks-on-entities-on-demand-preview)-- [Customize more alert properties (Preview)](#customize-more-alert-properties-preview)-
-### Create and run playbooks on entities on-demand (Preview)
-
-SOC analysts can now take immediate action on a particular entity representing a threat actor, while in the middle of investigating an incident or hunting for threats, without leaving those contexts or having to pivot to other screens or apps.
-
-Similarly, SOC engineers can now encapsulate a series of automated actions in workflows that run on a specific entity, so that analysts can use these workflows in the scenarios above.
-
-These improvements for SOC efficiency and productivity are thanks to the **new entity trigger for playbooks**.
--- Learn more about [running playbooks on entities on-demand](respond-threats-during-investigation.md).-- Learn more about [creating playbooks based on the entity trigger](tutorial-respond-threats-playbook.md#create-a-playbook).-
-### Customize more alert properties (Preview)
-
-Alerts generated by a given analytics rule - and all incidents created as a result - inherit the name, description, severity, and tactics defined in the rule, without regard to the particular content of a specific instance of the alert.
-
-You've already been able to use the **alert details** feature to override these four default properties of alerts; now there are **nine more alert properties** that can be customized to override their defaults.
-
-See which ones, and learn how to use the updated mechanism, in [Customize alert details in Microsoft Sentinel](customize-alert-details.md).
## Announcements
+- [Microsoft Defender for Identity alerts now available in Government Community Cloud](#microsoft-defender-for-identity-alerts-now-available-in-government-community-cloud)
- [Microsoft Defender for Identity alerts will no longer refer to the MDA policies in the Alert ExternalLinks properties](#microsoft-defender-for-identity-alerts-will-no-longer-refer-to-the-mda-policies-in-the-alert-externallinks-properties) - [WindowsEvent table enhancements](#windowsevent-table-enhancements) - [Out-of-the-box content centralization changes](#out-of-the-box-content-centralization-changes)
See which ones, and learn how to use the updated mechanism, in [Customize alert
- [Account enrichment fields removed from Azure AD Identity Protection connector](#account-enrichment-fields-removed-from-azure-ad-identity-protection-connector) - [Name fields removed from UEBA UserPeerAnalytics table](#name-fields-removed-from-ueba-userpeeranalytics-table)
+### Microsoft Defender for Identity alerts now available in Government Community Cloud
+
+Microsoft Defender for Identity alerts are now available in Government Community Cloud (GCC).
+
+If you previously used the MDI alerts connector, with the introduction of the new alerts, the `UniqueExternalId` field is no longer populated. The ID represents the alert, and was formerly located in the `ExternalProperties` field. You can now be obtain the ID through the `AlertName` field, which contains the alert’s name.
+
+If you've used this ID in your custom queries, we recommend that you adjust your queries accordingly. Review the [Security alert name mapping and unique external IDs](/defender-for-identity/alerts-overview#security-alert-name-mapping-and-unique-external-ids).
+ ### Microsoft Defender for Identity alerts will no longer refer to the MDA policies in the Alert ExternalLinks properties Microsoft Defender for Identity alerts will no longer refer to the MDA policies in the Alert ExternalLinks properties due to a change in infrastructure performed on MDIs. Alerts will no longer contain any MDA links under **ExtendedLinks** with a **Label** that starts with **Defender for Cloud Apps**. This change will take effect April 30th, 2023. [Read more about this change](/defender-for-identity/whats-new#defender-for-identity-release-2198). 
Learn more about [ingest-time transformations](../azure-monitor/essentials/data-
### Out-of-the-box content centralization changes A new banner is appearing in Microsoft Sentinel gallery pages! This informational banner is rolling out to all tenants to explain upcoming changes regarding out-of-the-box (OOTB) content. In short, the **Content hub** will be the central source whether you're looking for standalone content or packaged solutions. Expect banners to appear in the templates section of **Workbooks**, **Hunting**, **Automation**, **Analytics** and **Data connectors** galleries. Here's an example of the banner in the **Workbooks** gallery. The banner reads, 'All Workbook templates, and additional out-of-the-box (OOTB) content are now centrally available in Content hub. Starting Q2 2023, only Workbook templates installed from the content hub will be available in this gallery. Learn more about the OOTB content centralization changes.' :::image-end:::
site-recovery Azure To Azure How To Enable Replication https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/azure-to-azure-how-to-enable-replication.md
Title: Configure replication for Azure VMs in Azure Site Recovery description: Learn how to configure replication to another region for Azure VMs, using Site Recovery.-++ Last updated 12/07/2022
site-recovery Azure To Azure How To Enable Zone To Zone Disaster Recovery https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/azure-to-azure-how-to-enable-zone-to-zone-disaster-recovery.md
Last updated 12/07/2022-+
site-recovery Azure To Azure Powershell https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/azure-to-azure-powershell.md
Last updated 12/07/2022-+
site-recovery Concepts Azure To Azure High Churn Support https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/concepts-azure-to-azure-high-churn-support.md
Title: Azure VM Disaster Recovery - High Churn support (Public Preview) description: Describes how to protect your Azure VMs having high churning workloads -+ Last updated 12/07/2022-+ # Azure VM Disaster Recovery - High Churn Support (Public Preview)
site-recovery Disaster Recovery For Edge Zone Via Vm Flow Tutorial https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/disaster-recovery-for-edge-zone-via-vm-flow-tutorial.md
Last updated 04/19/2023-+ # Tutorial: Set up disaster recovery for Azure Public MEC using VM Flow
site-recovery Disaster Recovery For Edge Zone Vm Tutorial https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/disaster-recovery-for-edge-zone-vm-tutorial.md
Title: Set up disaster recovery for VMs on Azure Public MEC using Vault flow description: Learn how to set up disaster recovery for virtual machines on Azure Public MEC (in preview for ASR functionality).-+ Last updated 04/18/2023-+ # Tutorial: Set up disaster recovery for VMs on Azure Public MEC using Vault flow
site-recovery Tutorial Replicate Vms Edge Zone To Another Zone https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/tutorial-replicate-vms-edge-zone-to-another-zone.md
Last updated 12/14/2022-+ # Replicate virtual machines running in an Azure Public MEC to another Azure Public MEC in the same region
site-recovery Tutorial Replicate Vms Edge Zone To Azure Region https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/site-recovery/tutorial-replicate-vms-edge-zone-to-azure-region.md
Last updated 12/14/2022-+
storage Storage Blob Upload Python https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/blobs/storage-blob-upload-python.md
Previously updated : 04/21/2023 Last updated : 05/01/2023
To upload a blob using a stream or a binary object, use the following method:
The following example uploads a file to a block blob using a `BlobClient` object: ## Upload a block blob from a stream The following example creates random bytes of data and uploads a `BytesIO` object to a block blob using a `BlobClient` object: ## Upload binary data to a block blob The following example uploads binary data to a block blob using a `BlobClient` object: ## Upload a block blob with index tags The following example uploads a block blob with index tags: +
+## Upload a block blob by staging blocks and committing
+
+You can have greater control over how to divide uploads into blocks by manually staging individual blocks of data. When all of the blocks that make up a blob are staged, you can commit them to Blob Storage.
+
+The following example reads data from a file and stages blocks to be committed as part of a blob:
+ ## Resources
storage Classic Account Migrate https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/common/classic-account-migrate.md
Previously updated : 04/13/2023 Last updated : 04/28/2023
Microsoft will retire classic storage accounts on August 31, 2024. To preserve t
This article describes how to migrate your classic storage accounts to the Azure Resource Manager deployment model. For more information, see [Migrate your classic storage accounts to Azure Resource Manager by August 31, 2024](classic-account-migration-overview.md).
+## Overview of the migration process
+
+Before you get started with the migration, read [Understand storage account migration from the classic deployment model to Azure Resource Manager](classic-account-migration-process.md) for an overview of the process.
+
+To migrate your classic storage accounts, you should:
+
+1. [Identify classic storage accounts in your subscription](#identify-classic-storage-accounts-in-your-subscription).
+1. [Locate and delete any disk artifacts in classic accounts](#locate-and-delete-any-disk-artifacts-in-a-classic-account).
+1. [Migrate your classic storage accounts](#migrate-a-classic-storage-account).
+1. [Update your applications to use Azure Resource Manager APIs](#update-your-applications-to-use-azure-resource-manager-apis).
+ ## Identify classic storage accounts in your subscription # [Portal](#tab/azure-portal)
Get-AzResource -ResourceType Microsoft.ClassicStorage/storageAccounts
+## Locate and delete any disk artifacts in a classic account
+
+Classic storage accounts may contain classic (unmanaged) disks, virtual machine images, and operating system (OS) images. To migrate the account, you will need to delete these artifacts first.
+
+> [!IMPORTANT]
+> If you do not delete classic disk artifacts first, the migration may fail.
+
+To learn about migrating unmanaged disks to managed disks, see [Migrating unmanaged disks to managed disks](../../virtual-machines/unmanaged-disks-deprecation.md).
+
+# [Portal](#tab/azure-portal)
+
+To delete disk artifacts from the Azure portal, follow these steps:
+
+1. Navigate to the Azure portal.
+1. In the **Search** bar at the top, search for **Disks (classic)**, **OS Images (classic)**, or **VM Images (classic)** to display classic disk artifacts.
+1. Locate the classic disk artifact to delete, and select it to view its properties.
+1. Select the **Delete** button to delete the disk artifact.
+
+ :::image type="content" source="media/classic-account-migrate/delete-disk-artifacts-portal.png" alt-text="Screenshot showing how to delete classic disk artifacts in Azure portal." lightbox="media/classic-account-migrate/delete-disk-artifacts-portal.png":::
+
+For more information about errors that may occur when deleting disk artifacts and how to address them, see [Troubleshoot errors when you delete Azure classic storage accounts, containers, or VHDs](/troubleshoot/azure/virtual-machines/storage-classic-cannot-delete-storage-account-container-vhd).
+
+# [PowerShell](#tab/azure-powershell)
+
+To learn how to locate and delete disk artifacts in classic storage accounts with PowerShell, see [Migrate to Resource Manager with PowerShell](../../virtual-machines/migration-classic-resource-manager-ps.md#step-52-migrate-a-storage-account).
+++ ## Migrate a classic storage account The process of migrating a classic storage account involves four steps:
Move-AzureStorageAccount -Commit -StorageAccountName $accountName
-### Locate and delete disk artifacts in a classic account
+## Update your applications to use Azure Resource Manager APIs
-Classic storage accounts may contain classic (unmanaged) disks, virtual machine images, and operating system (OS) images. To migrate the account, you may need to delete these artifacts first.
+After you migrate your classic storage account to Azure Resource Manager, you must update your applications and scripts to use Azure Resource Manager APIs. The [Azure Storage resource provider](/rest/api/storagerp/) is the implementation of Azure Resource Manager for Azure Storage.
-To delete disk artifacts from the Azure portal, follow these steps:
+Azure Storage provides SDKs for convenience in calling the Azure Storage resource provider APIs:
-1. Navigate to the Azure portal.
-1. In the **Search** bar at the top, search for **Disks (classic)**, **OS Images (classic)**, or **VM Images (classic)** to display classic disk artifacts.
-1. Locate the classic disk artifact to delete, and select it to view its properties.
-1. Select the **Delete** button to delete the disk artifact.
+- [Management client library for .NET](/dotnet/api/overview/azure/resourcemanager.storage-readme)
+- [Management client library for Java](/java/api/overview/azure/resourcemanager-storage-readme)
+- [Management client library for JavaScript](/javascript/api/overview/azure/arm-storage-readme)
+- [Management client library for Python](/python/api/overview/azure/mgmt-storage-readme)
- :::image type="content" source="media/classic-account-migrate/delete-disk-artifacts-portal.png" alt-text="Screenshot showing how to delete classic disk artifacts in Azure portal." lightbox="media/classic-account-migrate/delete-disk-artifacts-portal.png":::
+You can also use the latest versions of Azure PowerShell and Azure CLI to manage your migrated storage accounts:
-For more information about errors that may occur when deleting disk artifacts and how to address them, see [Troubleshoot errors when you delete Azure classic storage accounts, containers, or VHDs](/troubleshoot/azure/virtual-machines/storage-classic-cannot-delete-storage-account-container-vhd).
+- [Azure PowerShell](/powershell/azure/what-is-azure-powershell)
+- [Azure CLI](/cli/azure/what-is-azure-cli)
-For more information about how to locate and delete disk artifacts in classic storage accounts with PowerShell or Azure CLI, see one of the following articles:
+To learn more about resource providers in Azure Resource Manager, see [Resource providers and resource types](../../azure-resource-manager/management/resource-providers-and-types.md).
-- [Migrate to Resource Manager with PowerShell](../../virtual-machines/migration-classic-resource-manager-ps.md#step-52-migrate-a-storage-account)-- [Migrate VMs to Resource Manager using Azure CLI](../../virtual-machines/migration-classic-resource-manager-cli.md#step-5-migrate-a-storage-account) ## See also
storage Classic Account Migration Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/common/classic-account-migration-overview.md
Previously updated : 04/10/2023 Last updated : 05/01/2023
The [Azure Resource Manager](../../azure-resource-manager/management/overview.md) deployment model now offers extensive functionality for Azure Storage accounts. For this reason, we deprecated the management of classic storage accounts through Azure Service Manager (ASM) on August 31, 2021. Classic storage accounts will be fully retired on August 31, 2024. All data in classic storage accounts must be migrated to Azure Resource Manager storage accounts by that date.
-If you have classic storage accounts, start planning your migration now. Complete it by August 31, 2024, to take advantage of Azure Resource Manager. To learn more about the benefits of Azure Resource Manager, see [The benefits of using Resource Manager](../../azure-resource-manager/management/overview.md#the-benefits-of-using-resource-manager).
+If you have classic storage accounts, start planning your migration now. Complete it by August 31, 2024, to take advantage of Azure Resource Manager.
+
+To learn more about the classic versus Azure Resource Manager deployment models, see [Resource Manager and classic deployment](../../azure-resource-manager/management/deployment-models.md#changes-for-compute-network-and-storage).
Storage accounts created using the classic deployment model follow the [Modern Lifecycle Policy](https://support.microsoft.com/help/30881/modern-lifecycle-policy) for retirement. ## Why is a migration required?
-On August 31, 2024, we'll retire classic Azure storage accounts and they'll no longer be accessible. Before that date, you must migrate them to Azure Resource Manager, which provides all of the same functionality, as well as new features, including:
+On August 31, 2024, we'll retire classic Azure storage accounts and they'll no longer be accessible. Before that date, you must migrate your storage accounts to Azure Resource Manager, and update your applications to use [Azure Storage resource provider](/rest/api/storagerp/) APIs.
+
+The Azure Storage resource provider is the implementation of Azure Resource Manager for Azure Storage. To learn more about resource providers in Azure Resource Manager, see [Resource providers and resource types](../../azure-resource-manager/management/resource-providers-and-types.md).
+
+Azure Resource Manager storage accounts provide all of the same functionality, as well as new features, including:
+
+- A [consistent management layer](../../azure-resource-manager/management/overview.md#consistent-management-layer) that simplifies deployment by enabling you to create, update, and delete resources.
+- [Resource grouping](../../azure-resource-manager/management/overview.md#resource-groups), which allows you to deploy, monitor, manage, and apply access control policies to resources as a group.
+- All new features for Azure Storage are implemented for storage accounts in Azure Resource Manager deployments. Customers that are still using classic resources will not have access to new features and updates.
-- A management layer that simplifies deployment by enabling you to create, update, and delete resources.-- Resource grouping, which allows you to deploy, monitor, manage, and apply access control policies to resources as a group.-- All new features for Azure Storage are implemented for storage account in Azure Resource Manager deployments, so customers that are still using classic resources will no longer have access to new features and updates.
+For more information about the advantages of using Azure Resource Manager, see [The benefits of using Resource Manager](../../azure-resource-manager/management/overview.md#the-benefits-of-using-resource-manager).
## What happens if I don't migrate my accounts? Starting on September 1, 2024, customers will no longer be able to connect to classic storage accounts by using Azure Service Manager. Any data still contained in these accounts will no longer be accessible through Azure Service Manager.
+If your applications are using Azure Service Manager classic APIs to access classic accounts, then those applications will no longer be able to access those storage accounts after August 31, 2024.
+ > [!WARNING] > If you do not migrate your classic storage accounts to Azure Resource Manager by August 31, 2024, you will permanently lose access to the data in those accounts. ## What actions should I take?
-To migrate your classic storage accounts, you should:
+Before you get started with the migration, read [Understand storage account migration from the classic deployment model to Azure Resource Manager](classic-account-migration-process.md) for an overview of the process.
-1. Identify all classic storage accounts in your subscription.
-1. Migrate any classic storage accounts to Azure Resource Manager.
-1. Check your applications and logs to determine whether you're dynamically creating, updating, or deleting classic storage accounts from your code, scripts, or templates. If you are, then you need to update your applications to use Azure Resource Manager accounts instead.
+To migrate your classic storage accounts, you should:
-For step-by-step instructions, see [How to migrate your classic storage accounts to Azure Resource Manager](classic-account-migrate.md). For an in-depth overview of the migration process, see [Understand storage account migration from the classic deployment model to Azure Resource Manager](classic-account-migration-process.md).
+1. Identify all classic storage accounts in your subscription. To learn how, see [Identify classic storage accounts in your subscription](classic-account-migrate.md#identify-classic-storage-accounts-in-your-subscription).
+1. Delete any classic (unmanaged) disks or disk artifacts in your classic storage accounts. To learn how to delete classic disk artifacts, see [Locate and delete any disk artifacts in a classic account](classic-account-migrate.md#locate-and-delete-any-disk-artifacts-in-a-classic-account).
+1. Migrate any classic storage accounts to [Azure Resource Manager](../../azure-resource-manager/management/overview.md). For step-by-step instructions on performing the migration, see [How to migrate your classic storage accounts to Azure Resource Manager](classic-account-migrate.md).
+1. Check your applications and logs to determine whether you're dynamically creating, updating, or deleting classic storage accounts from your code, scripts, or templates. If you are, then you must update your applications to use Azure Resource Manager APIs for account management. For more information, see [Update your applications to use Azure Resource Manager APIs](classic-account-migrate.md#update-your-applications-to-use-azure-resource-manager-apis).
## How to get help
For step-by-step instructions, see [How to migrate your classic storage accounts
1. Search for **Help + support** in the [Azure portal](https://portal.azure.com#view/Microsoft_Azure_Support/HelpAndSupportBlade/~/overview). 1. Select **Create a support request**.
- 1. Under **Summary**, type a description of your issue.
1. Under **Issue type**, select **Technical**. 1. Under **Subscription**, select your subscription. 1. Under **Service**, select **My services**.
- 1. Under **Service type**, select **Storage Account Management**.
+ 1. Under **Service type**, search for and select **Storage Account Management**.
1. Under **Resource**, select the resource you want to migrate.
- 1. Under **Problem type**, select **Data Migration**.
- 1. Under **Problem subtype**, select **Migrate account to new resource group/subscription/region/tenant**.
+ 1. Under **Summary**, type a description of your issue.
+ 1. Under **Problem type**, select **Migrate a classic storage account to Azure Resource Manager**.
1. Select **Next**, then follow the instructions to submit your support request. ## FAQ
No, Microsoft can't migrate a customer's storage account on their behalf. Custom
### Will there be downtime when migrating my storage account from Classic to Resource Manager?
-There's no downtime to migrate a classic storage account to Resource Manager. However, there may be downtime for other scenarios linked to classic virtual machine (VM) migration.
+There's no downtime for data plane operations while you are migrating a classic storage account to Resource Manager. Management plane operations are blocked during the migration. For more information, see [Understand storage account migration from the classic deployment model to Azure Resource Manager](classic-account-migration-process.md).
+
+There may be downtime for scenarios linked to classic virtual machine (VM) migration or unmanaged disk migration. For more information about those scenarios, see [Migration classic VMs](../../virtual-machines/classic-vm-deprecation.md) and [Migrating unmanaged disks to managed disks](../../virtual-machines/unmanaged-disks-deprecation.md).
### What operations aren't available during the migration?
Also, during the migration, management operations aren't available on the storag
If you're creating or managing container objects with the Azure Storage resource provider, keep in mind that those operations are blocked while the migration is underway. For more information, see [Understand storage account migration from the classic deployment model to Azure Resource Manager](classic-account-migration-process.md).
+### How do I migrate storage accounts that contain classic disk artifacts?
+
+If your classic storage accounts contain classic (unmanaged) disks, virtual machine images, or operating system (OS) images, you'll need to delete these artifacts before you begin the migration. Failing to delete these artifacts may cause the migration to fail. To learn how to delete classic disk artifacts, see [Locate and delete any disk artifacts in a classic account](classic-account-migrate.md#locate-and-delete-any-disk-artifacts-in-a-classic-account).
+
+We recommend migrating unmanaged disks to managed disks. To learn about migrating unmanaged disks to managed disks, see [Migrating unmanaged disks to managed disks](../../virtual-machines/unmanaged-disks-deprecation.md).
+ ### Are storage account access keys regenerated as part of the migration? No, account access keys aren't regenerated during the migration. Your access keys and connection strings will continue to work unchanged after the migration is complete.
storage Classic Account Migration Process https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/common/classic-account-migration-process.md
Previously updated : 04/13/2023 Last updated : 04/28/2023
Before you start the migration:
If you're migrating Azure virtual machines (VMs) that include disks in classic storage accounts, be sure to familiarize yourself with the process of VM migration. For information about unsupported features and configurations, see [Overview of platform-supported migration of IaaS resources from classic to Azure Resource Manager](../../virtual-machines/migration-classic-resource-manager-overview.md#unsupported-features-and-configurations). For a list of errors that may occur in relation to classic disk artifacts, see [Common errors during Classic to Azure Resource Manager migration](../../virtual-machines/migration-classic-resource-manager-errors.md#list-of-errors). - Plan your migration during non-business hours to accommodate for any unexpected failures that might happen during migration.-- Evaluate any Azure role-based access control (Azure RBAC) roles that are configured on the classic storage account, and plan for after the migration is complete. There are four steps to the migration process, as shown in the following diagram:
The Validation step is the first step in the migration process. The goal of this
The Validation step analyzes the state of resources in the classic deployment model. It checks for failures and unsupported scenarios due to different configurations of the storage account in the classic deployment model.
-The Validation step doesn't check for VM disks that may be associated with the storage account. You must check your storage accounts manually to determine whether they support VM disks. For more information, see the following articles:
+The Validation step doesn't check for VM disks that may be associated with the storage account. You must check your storage accounts manually to determine whether they contain VM disks. For more information, see the following articles:
- [Migrate classic storage accounts to Azure Resource Manager](classic-account-migrate.md) - [Migrate VMs to Resource Manager with PowerShell](../../virtual-machines/migration-classic-resource-manager-ps.md#step-52-migrate-a-storage-account)
storage Redundancy Regions Gzrs https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/common/redundancy-regions-gzrs.md
+
+ Title: List of Azure regions that support geo-zone-redundant storage (GZRS)
+
+description: List of Azure regions that support geo-zone-redundant storage (GZRS)
+++++ Last updated : 04/28/2023+++++
+# Azure regions that support geo-zone-redundant storage (GZRS)
+
+This article lists the regions that support geo-zone-redundant storage (GZRS). For a list of regions that support zone-redundant storage (ZRS), see [Azure regions that support zone-redundant storage (ZRS)](redundancy-regions-zrs.md).
+
+## GZRS-supported Regions
++
+## See also
+
+- [Azure regions that support zone-redundant (ZRS) storage](redundancy-regions-zrs.md)
+- [Azure Storage redundancy](storage-redundancy.md)
storage Redundancy Regions Zrs https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/common/redundancy-regions-zrs.md
+
+ Title: List of Azure regions that support zone-redundant storage (ZRS)
+
+description: List of Azure regions that support zone-redundant storage (ZRS)
+++++ Last updated : 04/28/2023+++++
+# Azure regions that support zone-redundant storage (ZRS)
+
+This article lists the regions that support zone-redundant storage (ZRS). For a list of regions that support geo-zone-redundant storage (GZRS), see [Azure regions that support geo-zone-redundant storage (GZRS)](redundancy-regions-gzrs.md).
+
+## Standard storage accounts
++
+## Premium block blob accounts
++
+## See also
+
+- [Azure regions that support geo-zone-redundant (GZRS) storage](redundancy-regions-gzrs.md)
+- [Azure Storage redundancy](storage-redundancy.md)
storage Storage Redundancy https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/common/storage-redundancy.md
Previously updated : 08/18/2022 Last updated : 04/27/2023
ZRS is supported for all Azure Storage services through standard general-purpose
- Azure Table storage - Azure Queue storage
+For a list of regions that support zone-redundant storage (ZRS) for standard accounts, see [Azure regions that support zone-redundant storage (ZRS) for standard storage accounts](redundancy-regions-zrs.md#standard-storage-accounts).
#### Premium block blob accounts ZRS is supported for premium block blobs accounts. For more information about premium block blobs, see [Premium block blob storage accounts](../blobs/storage-blob-block-blob-premium.md).
-Premium block blobs are available in a subset of Azure regions:
--- (Asia Pacific) Australia East-- (Asia Pacific) East Asia-- (Asia Pacific) Japan East-- (Asia Pacific) Southeast Asia-- (Europe) France Central-- (Europe) North Europe-- (Europe) West Europe-- (Europe) UK South-- (North America) East US-- (North America) East US 2-- (North America) West US 2-- (North America) South Central US-- (South America) Brazil South
+For a list of regions that support zone-redundant storage (ZRS) for premium block blobs accounts, see [Azure regions that support zone-redundant storage (ZRS) for premium block blob accounts](redundancy-regions-zrs.md#premium-block-blob-accounts).
#### Premium file share accounts ZRS is supported for premium file shares (Azure Files) through the `FileStorage` storage account kind.
+For a list of regions that support zone-redundant storage (ZRS) for premium file share accounts, see [Azure Files zone-redundant storage for premium file shares](../files/redundancy-premium-file-shares.md).
## Redundancy in a secondary region
Only standard general-purpose v2 storage accounts support GZRS. GZRS is supporte
- Azure Table storage - Azure Queue storage
+For a list of regions that support geo-zone-redundant storage (GZRS), see [Azure regions that support geo-zone-redundant storage (GZRS)](redundancy-regions-gzrs.md).
## Read access to data in the secondary region
storage Storage How To Use Files Windows https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/storage/files/storage-how-to-use-files-windows.md
description: Learn to use Azure file shares with Windows and Windows Server. Use
Previously updated : 07/19/2022 Last updated : 05/01/2023
# Mount SMB Azure file share on Windows [Azure Files](storage-files-introduction.md) is Microsoft's easy-to-use cloud file system. Azure file shares can be seamlessly used in Windows and Windows Server. This article discusses the considerations for using an Azure file share with Windows and Windows Server.
-In order to use an Azure file share via the public endpoint outside of the Azure region it is hosted in, such as on-premises or in a different Azure region, the OS must support SMB 3.x. Older versions of Windows that support only SMB 2.1 can't mount Azure file shares via the public endpoint.
+In order to use an Azure file share via the public endpoint outside of the Azure region it's hosted in, such as on-premises or in a different Azure region, the OS must support SMB 3.x. Older versions of Windows that support only SMB 2.1 can't mount Azure file shares via the public endpoint.
| Windows version | SMB version | Azure Files SMB Multichannel | Maximum SMB channel encryption | |-|-|-|-|
In order to use an Azure file share via the public endpoint outside of the Azure
| Windows 10, version 22H2 | SMB 3.1.1 | Yes | AES-256-GCM | | Windows Server 2022 | SMB 3.1.1 | Yes | AES-256-GCM | | Windows 11, version 21H2 | SMB 3.1.1 | Yes | AES-256-GCM |
-| Windows 10, version 21H2 | SMB 3.1.1 | Yes | AES-256-GCM |
+| Windows 10, version 21H2 | SMB 3.1.1 | Yes | AES-128-GCM |
| Windows 10, version 21H1 | SMB 3.1.1 | Yes, with KB5003690 or newer | AES-128-GCM | | Windows Server, version 20H2 | SMB 3.1.1 | Yes, with KB5003690 or newer | AES-128-GCM | | Windows 10, version 20H2 | SMB 3.1.1 | Yes, with KB5003690 or newer | AES-128-GCM |
stream-analytics Quick Create Terraform https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/stream-analytics/quick-create-terraform.md
+
+ Title: 'Quickstart: Create an Azure Stream Analytics job using Terraform'
+description: In this article, you create an Azure Stream Analytics job using Terraform.
++++++ Last updated : 4/22/2023++
+# Quickstart: Create an Azure Stream Analytics job using Terraform
+
+This article shows how to create an [Azure Stream Analytics](stream-analytics-introduction.md) job using Terraform. Once the job is created, you validate the deployment.
++
+In this article, you learn how to:
+
+> [!div class="checklist"]
+> * Create a random value for the Azure resource group name using [random_pet](https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/pet).
+> * Create an Azure resource group using [azurerm_resource_group](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/resource_group).
+> * Create a random value for the Azure Stream Analytics job name using [random_pet](https://registry.terraform.io/providers/hashicorp/random/latest/docs/resources/pet).
+> * Create an Azure Stream Analytics job using [azurerm_stream_analytics_job](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/stream_analytics_job).
++
+## Prerequisites
+
+- [Install and configure Terraform](/azure/developer/terraform/quickstart-configure)
+
+## Implement the Terraform code
+
+> [!NOTE]
+> The sample code for this article is located in the [Azure Terraform GitHub repo](https://github.com/Azure/terraform/tree/master/quickstart/101-stream-analytics-job). You can view the log file containing the [test results from current and previous versions of Terraform](https://github.com/Azure/terraform/tree/master/quickstart//101-stream-analytics-job/TestRecord.md).
+>
+> See more [articles and sample code showing how to use Terraform to manage Azure resources](/azure/terraform)
+
+1. Create a directory in which to test and run the sample Terraform code and make it the current directory.
+
+1. Create a file named `providers.tf` and insert the following code:
+
+ [!code-terraform[master](~/terraform_samples/quickstart/101-stream-analytics-job//providers.tf)]
+
+1. Create a file named `main.tf` and insert the following code:
+
+ [!code-terraform[master](~/terraform_samples/quickstart/101-stream-analytics-job//main.tf)]
+
+1. Create a file named `variables.tf` and insert the following code:
+
+ [!code-terraform[master](~/terraform_samples/quickstart/101-stream-analytics-job//variables.tf)]
+
+1. Create a file named `outputs.tf` and insert the following code:
+
+ [!code-terraform[master](~/terraform_samples/quickstart/101-stream-analytics-job//outputs.tf)]
+
+## Initialize Terraform
++
+## Create a Terraform execution plan
++
+## Apply a Terraform execution plan
++
+## Verify the results
+
+#### [Azure CLI](#tab/azure-cli)
+
+1. Get the Azure resource group name.
+
+ ```console
+ resource_group_name=$(terraform output -raw resource_group_name)
+ ```
+
+1. Get the new Azure Stream Analytics job name.
+
+ ```console
+ stream_analytics_job_name=$(terraform output -raw stream_analytics_job_name)
+ ```
+
+1. Run [az stream-analytics job show](/cli/azure/stream-analytics/job#az-stream-analytics-job-show) to display information about the job.
+
+ ```azurecli
+ az stream-analytics job show \
+ --resource-group $resource_group_name \
+ --job-name $stream_analytics_job_name
+ ```
+
+#### [Azure PowerShell](#tab/azure-powershell)
+
+1. Get the Azure resource group name.
+
+ ```console
+ $resource_group_name=$(terraform output -raw resource_group_name)
+ ```
+
+1. Get the new Azure Stream Analytics job name.
+
+ ```console
+ $stream_analytics_job_name=$(terraform output -raw stream_analytics_job_name)
+ ```
+
+1. Run [Get-AzStreamAnalyticsJob](/powershell/module/az.streamanalytics/get-azstreamanalyticsjob) to display information about the job.
+
+ ```azurepowershell
+ Get-AzStreamAnalyticsJob `
+ -ResourceGroupName $resource_group_name `
+ -Name $stream_analytics_job_name
+ ```
+++
+## Clean up resources
++
+## Troubleshoot Terraform on Azure
+
+[Troubleshoot common problems when using Terraform on Azure](/azure/developer/terraform/troubleshoot)
+
+## Next steps
+
+> [!div class="nextstepaction"]
+> [Create a dedicated Azure Stream Analytics cluster using Azure portal](create-cluster.md)
virtual-machines Time Sync https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-machines/linux/time-sync.md
Previously updated : 05/04/2022 Last updated : 04/26/2023
Here, chrony will force a time update if the drift is greater than 1 second. To
systemctl restart chronyd ```
+### Time sync messages related to systemd-timesyncd
+
+In some cases, the systemd-timesyncd service might still be enabled and trying to do a sync upon a reboot, if you are still seeing messages in syslog that look similar to:
+
+````
+systemd-timesyncd[945]: Network configuration changed, trying to establish connection.
+Aug 1 12:59:45 vm-name systemd-timesyncd[945]: Network configuration changed, trying to establish connection.
+Aug 1 12:59:45 vm-name systemd-timesyncd[945]: Network configuration changed, trying to establish connection.
+Aug 1 12:59:45 vm-name systemd-timesyncd[945]: Network configuration changed, trying to establish connection.
+Aug 1 12:59:45 vm-name systemd-timesyncd[945]: Network configuration changed, trying to establish connection.
+Aug 1 12:59:45 vm-name systemd-timesyncd[945]: Synchronized to time server 185.125.190.56:123 (ntp.ubuntu.com)
+`````
+
+You can disable it by using:
+
+```bash
+systemctl disable systemd-timesyncd
+````
+In most cases, systemd-timesyncd will try during boot but once chrony starts up it will overwrite and become the default time sync source.
+ For more information about Ubuntu and NTP, see [Time Synchronization](https://ubuntu.com/server/docs/network-ntp). For more information about Red Hat and NTP, see [Configure NTP](https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/system_administrators_guide/ch-configuring_ntp_using_ntpd#s1-Configure_NTP).
On SUSE and Ubuntu releases before 19.10, time sync is configured using [systemd
### cloud-init
-Images that use cloud-init to provision the VM can use the ntp section to setup a time sync service. An example of cloud-init installing chrony and configuring it to use the PTP clock source for Ubuntu VMs:
+Images that use cloud-init to provision the VM can use the `ntp` section to setup a time sync service. An example of cloud-init installing chrony and configuring it to use the PTP clock source for Ubuntu VMs:
```yaml #cloud-config
virtual-machines Migration Classic Resource Manager Ps https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-machines/migration-classic-resource-manager-ps.md
Previously updated : 01/25/2023 Last updated : 04/14/2023
To migrate virtual machines in a virtual network, you migrate the virtual networ
> [!NOTE] > The virtual network name might be different from what is shown in the new portal. The new Azure portal displays the name as `[vnet-name]`, but the actual virtual network name is of type `Group [resource-group-name] [vnet-name]`. Before you start the migration, look up the actual virtual network name by using the command `Get-AzureVnetSite | Select -Property Name` or view it in the old Azure portal.
-This example sets the virtual network name to **myVnet**. Replace the example virtual network name with your own.
+This following example sets the virtual network name to Group **[resource-group-name]** **[vnet-name]**. Replace the example virtual network name with one that was returned from running the command in the **Note** section above..
```powershell
- $vnetName = "myVnet"
+ $vnetName = "Group [resource-group-name] [vnet-name]"
``` > [!NOTE]
virtual-machines Oracle Database Backup Azure Backup https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-machines/workloads/oracle/oracle-database-backup-azure-backup.md
**Applies to:** :heavy_check_mark: Linux VMs
-This article demonstrates the use of Azure Backup to take disk snapshots of the VM disks, which include the database files and fast recovery area. Using Azure Backup you can take full disk snapshots suitable as backups, which are stored in [Recovery Services Vault](../../../backup/backup-azure-recovery-services-vault-overview.md). Azure Backup also provides application-consistent backups, which ensure additional fixes aren't required to restore the data. Restoring application-consistent data reduces the restoration time, allowing you to quickly return to a running state.
+This article demonstrates the use of Azure Backup to take disk snapshots of the VM disks, which include the Oracle database files and the Oracle fast recovery area (FRA). Using Azure Backup you can take full disk snapshots suitable as backups, which are stored in [Recovery Services Vault](../../../backup/backup-azure-recovery-services-vault-overview.md). Azure Backup also provides application-consistent backups, which ensure additional fixes aren't required to restore the data. Restoring application-consistent data reduces the restoration time, allowing you to quickly return to a running state. Oracle database recovery is still necessary after restore, and this is facilitated using Oracle archived redo log files captured and stored in a separate Azure fileshare, as described below.
> [!div class="checklist"] >
To prepare the environment, complete these steps:
### Set up Azure Files Storage for the Oracle archived redo log files
-The Oracle database archive redo logfiles play a crucial role in database recovery as they store the committed transactions needed to roll forward from a database snapshot taken in the past. When in archivelog mode, the database archives the contents of online redo logfiles when they become full and switch. Together with a backup, they are required to achieve point-in-time recovery when the database has been lost.
+The Oracle database's archived redo logfiles play a crucial role in database recovery as they store the committed transactions needed to roll forward from a database snapshot taken in the past. When in archivelog mode, the database archives the contents of online redo logfiles when they become full and switch. Together with a backup, they are required to achieve point-in-time recovery when the database has been lost.
Oracle provides the capability to archive redo logfiles to different locations, with industry best practice recommending that at least one of those destinations be on remote storage, so it is separate from the host storage and protected with independent snapshots. Azure Files is a great fit for those requirements.
To use Azure Backup to back up the database, complete these steps:
## Restore the VM
+
+There are two main choices when restoring a VM:
+
+- restore the VM from which the backups were originally taken
+- restore (clone) a new VM without affecting the VM from which the backups were originally taken
+
+The first steps in this exercise, stopping, deleting, and then recovering the VM, are intended to simulate the first use-case, where we are restoring the VM from which the backups were originally taken. You also have the ability to clone the VM without interrupting or affecting the original VM, if you wish.
Restoring the entire VM allows you to restore the VM and its attached disks to a new VM from a selected restore point. This will restore all databases that run on the VM and each database will need to be recovered afterwards.
After the VM is restored, you should reassign the original IP address to the new
-## Restore an individual database
-As multiple Oracle databases can be run on an Azure VM, there may be times when you want to restore and recover an individual database without disrupting the other databases running on the VM.
-
-To restore an individual database, complete these steps:
-
-1. [Remove the database files](#remove-the-database-files).
-1. [Generate a restore script from the Recovery Services vault](#generate-a-restore-script-from-the-recovery-services-vault).
-1. [Mount the restore point](#mount-the-restore-point).
-1. [Restore the database files](#restore-the-database-files).
-
-### Remove the database files
-
-Later in this article, you'll learn how to test the recovery process. Before you can test the recovery process, you have to remove the database files.
-
-1. Switch back to the oracle user:
- ```bash
- su - oracle
- ```
-
-1. Shut down the Oracle instance:
-
- ```bash
- sqlplus / as sysdba
- SQL> shutdown abort
- ORACLE instance shut down.
- ```
-
-1. Remove the database datafiles and contolfiles to simulate a failure:
-
- ```bash
- cd /u02/oradata/ORATEST1
- rm -f *.dbf *.ctl
- ```
-
-### Generate a restore script from the Recovery Services vault
-
-# [Portal](#tab/azure-portal)
-
-1. In the Azure portal, search for the *myVault* Recovery Services vaults item and select it.
-
- ![Recovery Services vaults myVault backup items](./media/oracle-backup-recovery/recovery-service-06.png)
-
-1. On the **Overview** blade, select **Backup items** and the select **Azure Virtual Machine**, which should have anon-zero Backup Item Count listed.
-
- ![Recovery Services vaults Azure Virtual Machine backup item count](./media/oracle-backup-recovery/recovery-service-07.png)
-
-1. On the Backups Items (Azure Virtual Machines) page, your VM **vmoracle19c** is listed. Click the ellipsis on the right to bring up the menu and select **File Recovery**.
-
- ![Screenshot of the Recovery Services vaults file recovery page](./media/oracle-backup-recovery/recovery-service-08.png)
-
-1. On the **File Recovery (Preview)** pane, click **Download Script**. Then, save the download (.py) file to a folder on the client computer. A password is generated to the run the script. Copy the password to a file for use later.
-
- ![Download script file saves options](./media/oracle-backup-recovery/recovery-service-09.png)
-
-1. Copy the .py file to the VM.
-
- The following example shows how you to use a secure copy (scp) command to move the file to the VM. You also can copy the contents to the clipboard, and then paste the contents in a new file that is set up on the VM.
-
- > [!IMPORTANT]
- > In the following example, ensure that you update the IP address and folder values. The values must map to the folder where the file is saved.
- >
-
- ```bash
- scp vmoracle19c_xxxxxx_xxxxxx_xxxxxx.py azureuser@<publicIpAddress>:/tmp
- ```
-
-# [Azure CLI](#tab/azure-cli)
-
-To list recovery points for your VM, use az backup recovery point list. In this example, we select the most recent recovery point for the VM named vmoracle19c that's protected in the Recovery Services Vault called myVault:
-
-```azurecli
- az backup recoverypoint list \
- --resource-group rg-oracle \
- --vault-name myVault \
- --backup-management-type AzureIaasVM \
- --container-name vmoracle19c \
- --item-name vmoracle19c \
- --query [0].name \
- --output tsv
-```
-
-To obtain the script that connects, or mounts, the recovery point to your VM, use az backup restore files mount-rp. The following example obtains the script for the VM named vmoracle19c that's protected in the Recovery Services Vault called myVault.
-
-Replace myRecoveryPointName with the name of the recovery point that you obtained in the preceding command:
-
-```azurecli
- az backup restore files mount-rp \
- --resource-group rg-oracle \
- --vault-name myVault \
- --container-name vmoracle19c \
- --item-name vmoracle19c \
- --rp-name myRecoveryPointName
-```
-
-The script is downloaded and a password is displayed, as in the following example:
-
-```output
- File downloaded: vmoracle19c_eus_4598131610710119312_456133188157_6931c635931f402eb543ee554e1cf06f102c6fc513d933.py. Use password c4487e40c760d29
-```
-
-Copy the .py file to the VM.
-
-The following example shows how you to use a secure copy (scp) command to move the file to the VM. You also can copy the contents to the clipboard, and then paste the contents in a new file that is set up on the VM.
-
-> [!IMPORTANT]
-> In the following example, ensure that you update the IP address and folder values. The values must map to the folder where the file is saved.
->
-
-```bash
-scp vmoracle19c_xxxxxx_xxxxxx_xxxxxx.py azureuser@<publicIpAddress>:/tmp
-```
--
-### Mount the restore point
-
-1. Switch to the root user:
- ```bash
- sudo su -
- ``````
-1. Create a restore mount point and copy the script to it.
-
- In the following example, create a */restore* directory for the snapshot to mount to, move the file to the directory, and change the file so that it's owned by the root user and made executable.
-
- ```bash
- mkdir /restore
- chmod 777 /restore
- cd /restore
- cp /tmp/vmoracle19c_xxxxxx_xxxxxx_xxxxxx.py /restore
- chmod 755 /restore/vmoracle19c_xxxxxx_xxxxxx_xxxxxx.py
- ```
-
- Now execute the script to restore the backup. You will be asked to supply the password generated in Azure portal.
-
- ```bash
- ./vmoracle19c_xxxxxx_xxxxxx_xxxxxx.py
- ```
-
- The following example shows what you should see after you run the preceding script. When you're prompted to continue, enter **Y**.
-
- ```output
- Microsoft Azure VM Backup - File Recovery
- ______________________________________________
- Please enter the password as shown on the portal to securely connect to the recovery point. : b1ad68e16dfafc6
-
- Connecting to recovery point using ISCSI service...
-
- Connection succeeded!
-
- Please wait while we attach volumes of the recovery point to this machine...
-
- ************ Volumes of the recovery point and their mount paths on this machine ************
-
- Sr.No. | Disk | Volume | MountPath
-
- 1) | /dev/sdc | /dev/sdc1 | /restore/vmoracle19c-20201215123912/Volume1
-
- 2) | /dev/sdd | /dev/sdd1 | /restore/vmoracle19c-20201215123912/Volume2
-
- 3) | /dev/sdd | /dev/sdd2 | /restore/vmoracle19c-20201215123912/Volume3
-
- 4) | /dev/sdd | /dev/sdd15 | /restore/vmoracle19c-20201215123912/Volume5
-
- The following partitions failed to mount since the OS couldn't identify the filesystem.
-
- ************ Volumes from unknown filesystem ************
-
- Sr.No. | Disk | Volume | Partition Type
-
- 1) | /dev/sdb | /dev/sdb14 | BIOS Boot partition
-
- Please refer to '/restore/vmoracle19c-2020XXXXXXXXXX/Scripts/MicrosoftAzureBackupILRLogFile.log' for more details.
-
- ************ Open File Explorer to browse for files. ************
-
- After recovery, remove the disks and close the connection to the recovery point by clicking the 'Unmount Disks' button from the portal or by using the relevant unmount command in case of powershell or CLI.
-
- After unmounting disks, run the script with the parameter 'clean' to remove the mount paths of the recovery point from this machine.
-
- Please enter 'q/Q' to exit...
- ```
-
-1. Access to the mounted volumes is confirmed.
-
- To exit, enter **q**, and then search for the mounted volumes. To create a list of the added volumes, at a command prompt, enter **df -h**.
-
- ```output
- [root@vmoracle19c restore]# df -h
- Filesystem Size Used Avail Use% Mounted on
- devtmpfs 3.8G 0 3.8G 0% /dev
- tmpfs 3.8G 0 3.8G 0% /dev/shm
- tmpfs 3.8G 17M 3.8G 1% /run
- tmpfs 3.8G 0 3.8G 0% /sys/fs/cgroup
- /dev/sdd2 30G 9.6G 18G 36% /
- /dev/sdb1 126G 736M 119G 1% /u02
- /dev/sda1 497M 199M 298M 41% /boot
- /dev/sda15 495M 9.7M 486M 2% /boot/efi
- tmpfs 771M 0 771M 0% /run/user/54322
- /dev/sdc1 126G 2.9G 117G 3% /restore/vmoracle19c-20201215123912/Volume1
- /dev/sdd1 497M 199M 298M 41% /restore/vmoracle19c-20201215123912/Volume2
- /dev/sdd2 30G 9.6G 18G 36% /restore/vmoracle19c-20201215123912/Volume3
- /dev/sdd15 495M 9.7M 486M 2% /restore/vmoracle19c-20201215123912/Volume5
- ```
-
-### Restore The Database Files
-Perform the following steps for the database on the VM you want to restore:
-
-1. Restore the missing database files back to their location:
-
- ```bash
- cd /restore/vmoracle19c-2020XXXXXXXXXX/Volume1/oradata/ORATEST1
- cp * /u02/oradata/ORATEST1
- cd /u02/oradata/ORATEST1
- chown -R oracle:oinstall *
- ```
-Now the database has been restored you must recover the database. Please follow the steps in [Database Recovery](#recovery-after-an-individual-database-restore) to complete the recovery.
- ## Database Recovery ### Recovery after complete VM restore
Now the database has been restored you must recover the database. Please follow
SQL> recover automatic database using backup controlfile until cancel; ``` When the last available archive log file has been applied type `CANCEL` to end recovery.-
-1. Open the database
- > [!IMPORTANT]
- > The RESETLOGS option is required when the RECOVER command uses the USING BACKUP CONTROLFILE option. RESETLOGS creates a new incarnation of the database by resetting the redo history back to the beginning, because there is no way to determine how much of the previous database incarnation was skipped in the recovery.
-
- ```bash
- SQL> alter database open resetlogs;
- ```
-
-
-1. Check the database content has been recovered:
-
- ```bash
- SQL> select * from scott.scott_table;
- ```
-### Recovery after an individual database restore
-
-1. Switch back to the oracle user
- ```bash
- sudo su - oracle
- ```
-1. Start the database instance and mount the controlfile for reading:
- ```bash
- sqlplus / as sysdba
- SQL> startup mount
- SQL> quit
- ```
-
-1. Connect to the database with sysbackup:
- ```bash
- sqlplus / as sysbackup
- ```
-1. Initiate automatic database recovery:
-
- ```bash
- SQL> recover automatic database until cancel using backup controlfile;
- ```
- > [!IMPORTANT]
- > Please note that it is important to specify the USING BACKUP CONTROLFILE syntax to inform the RECOVER AUTOMATIC DATABASE command that recovery should not stop at the Oracle system change number (SCN) recorded in the restored database control file. The restored database control file was a snapshot, along with the rest of the database, and the SCN stored within it is from the point-in-time of the snapshot. There may be transactions recorded after this point and we want to recover to the point-in-time of the last transaction committed to the database.
-
+
When recovery completes successfully you will see the message `Media recovery complete`. However, when using the BACKUP CONTROLFILE clause the recover command will ignore online log files and it is possible there are changes in the current online redo log required to complete point in time recovery. In this situation you may see messages similar to these: ```output
Now the database has been restored you must recover the database. Please follow
To correct this you can identify which is the current online log that has not been archived, and supply the fully qualified filename to the prompt.
- Open a new ssh connection
- ```bash
- ssh azureuser@<IP Address>
- ```
- Switch to the oracle user and set the Oracle SID
- ```bash
- sudo su - oracle
- export ORACLE_SID=oratest1
- ```
-
- Connect to the database and run the following query to find the online logfile
- ```bash
- sqlplus / as sysdba
- SQL> column member format a45
- SQL> set linesize 500
- SQL> select l.SEQUENCE#, to_char(l.FIRST_CHANGE#,'999999999999999') as CHK_CHANGE, l.group#, l.archived, l.status, f.member
- from v$log l, v$logfile f
- where l.group# = f.group#;
- ```
-
- The output will look similar to this.
- ```output
- SEQUENCE# CHK_CHANGE GROUP# ARC STATUS MEMBER
- - - - -
- 13 2172929 1 NO CURRENT /u02/oradata/ORATEST1/redo01.log
- 12 2151934 3 YES INACTIVE /u02/oradata/ORATEST1/redo03.log
- 11 2071784 2 YES INACTIVE /u02/oradata/ORATEST1/redo02.log
- ```
- Copy the logfile path and file name for the CURRENT online log, in this example it is `/u02/oradata/ORATEST1/redo01.log`. Switch back to the ssh session running the recover command, input the logfile information and press return:
-
- ```output
- Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
- /u02/oradata/ORATEST1/redo01.log
- ```
-
- You should see the logfile is applied and recovery completes. Enter CANCEL to exit the recover command:
- ```output
- Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
- /u02/oradata/ORATEST1/redo01.log
- Log applied.
- Media recovery complete.
- ```
- 1. Open the database
-
> [!IMPORTANT] > The RESETLOGS option is required when the RECOVER command uses the USING BACKUP CONTROLFILE option. RESETLOGS creates a new incarnation of the database by resetting the redo history back to the beginning, because there is no way to determine how much of the previous database incarnation was skipped in the recovery.-
- ```bash
- SQL> alter database open resetlogs;
- ```
-
-1. Check the database content has been fully recovered:
-
- ```bash
- RMAN> SELECT * FROM scott.scott_table;
+ ```bash
+ SQL> alter database open resetlogs;
```
+
-1. Unmount the restore point.
-
- When all databases on the VM have been successfully recovered you may unmount the restore point. This can be done on the VM using the `unmount` command or in Azure portal from the File Recovery blade. You can also unmount the recovery volumes by running the Python script again with the **-clean** option.
-
- In the VM using unmount:
- ```bash
- sudo umount /restore/vmoracle19c-20210107110037/Volume*
- ```
-
- In the Azure portal, on the **File Recovery (Preview)** blade, click **Unmount Disks**.
+1. Check the database content has been recovered:
- ![Unmount disks command](./media/oracle-backup-recovery/recovery-service-10.png)
+ ```bash
+ SQL> select * from scott.scott_table;
+ ```
The backup and recovery of the Oracle Database on an Azure Linux VM is now finished.
virtual-network-manager Create Virtual Network Manager Cli https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/create-virtual-network-manager-cli.md
Title: 'Quickstart: Create a mesh network topology with Azure Virtual Network Manager via the Azure CLI'
-description: Use this quickstart to learn how to create a mesh network topology with Virtual Network Manager using the Azure CLI.
+description: Use this quickstart to learn how to create a mesh network topology with Virtual Network Manager by using the Azure CLI.
ms.devlang: azurecli
-# Quickstart: Create a mesh network topology with Azure Virtual Network Manager via the Azure CLI
+# Quickstart: Create a mesh network topology with Azure Virtual Network Manager by using the Azure CLI
Get started with Azure Virtual Network Manager by using the Azure CLI to manage connectivity for all your virtual networks.
-In this quickstart, you deploy three virtual networks and use Azure Virtual Network Manager to create a mesh network topology. Then you verify if the connectivity configuration got applied.
+In this quickstart, you deploy three virtual networks and use Azure Virtual Network Manager to create a mesh network topology. Then you verify that the connectivity configuration was applied.
> [!IMPORTANT]
-> Azure Virtual Network Manager is generally available for Virtual Network Manager and hub and spoke connectivity configurations.
+> Azure Virtual Network Manager is generally available for Virtual Network Manager and hub-and-spoke connectivity configurations. Mesh connectivity configurations and security admin rules remain in public preview.
>
-> Mesh connectivity configurations and security admin rules remain in public preview.
-> This preview version is provided without a service level agreement, and it's not recommended for production workloads. Certain features might not be supported or might have constrained capabilities.
-> For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
+> This preview version is provided without a service-level agreement, and we don't recommend it for production workloads. Certain features might not be supported or might have constrained capabilities. For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
## Prerequisites * An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
-* Make sure you have the [latest Azure CLI](/cli/azure/install-azure-cli) or you can use Azure Cloud Shell in the portal.
-* Run `az extension add -n virtual-network-manager` to add the Azure Virtual Network Manager extension.
+* The [latest Azure CLI](/cli/azure/install-azure-cli), or you can use Azure Cloud Shell in the portal.
+* The Azure Virtual Network Manager extension. To add it, run `az extension add -n virtual-network-manager`.
-## Sign in to your Azure account and select your subscription
+## Sign in to your Azure account and select your subscription
-To begin your configuration, sign in to your Azure account. If you use the Cloud Shell "Try It", you're signed in automatically. Use the following examples to help you connect:
+To begin your configuration, sign in to your Azure account. If you use the Cloud Shell **Try It** feature, you're signed in automatically.
```azurecli az login ```
-Select the subscription where network manager is deployed.
+Select the subscription where Virtual Network Manager is deployed:
```azurecli az account set \ --subscription "<subscription_id>" ```
-Update the Azure Virtual Network Manager extension for Azure CLI.
+
+Update the Virtual Network Manager extension for Azure CLI:
```azurecli az extension update --name virtual-network-manager ```
-## Create a resource group
-Before you can deploy Azure Virtual Network Manager, you have to create a resource group to host a network manager with [az group create](/cli/azure/group#az-group-create). This example creates a resource group named **myAVNMResourceGroup** in the **westus** location:
+## Create a resource group
+
+Before you can deploy Azure Virtual Network Manager, you have to create a resource group to host it by using [az group create](/cli/azure/group#az-group-create). This example creates a resource group named *myAVNMResourceGroup* in the West US location:
```azurecli az group create \
az group create \
--location "westus" ```
-## Create a Virtual Network Manager
+## Create a Virtual Network Manager instance
-Define the scope and access type this Network Manager instance have. Create the scope by using [az network manager create](/cli/azure/network/manager#az-network-manager-create). Replace the value *<subscription_id>* with the subscription you want Virtual Network Manager to manage virtual networks for. For management groups, replace *<mgName\>* with the management group to manage.
+Define the scope and access type for this Virtual Network Manager instance. Create the scope by using [az network manager create](/cli/azure/network/manager#az-network-manager-create). Replace the value `<subscription_id>` with the subscription that you want Virtual Network Manager to manage virtual networks for. Replace `<mgName\>` with the management group that you want to manage.
```azurecli az network manager create \
az network manager create \
--scope-accesses "Connectivity" "SecurityAdmin" \ --network-manager-scopes subscriptions="/subscriptions/<subscription_id>" ```+ ## Create a network group
-Virtual Network Manager applies configurations to groups of VNets by placing them in **Network Groups.** Create a network group with [az network manager group create](/cli/azure/network/manager/group#az-network-manager-group-create).
+Virtual Network Manager applies configurations to groups of virtual networks by placing them in network groups. Create a network group by using [az network manager group create](/cli/azure/network/manager/group#az-network-manager-group-create):
```azurecli az network manager group create \
az network manager group create \
--resource-group "myAVNMResourceGroup" \ --description "Network Group for Production virtual networks" ```+ ## Create virtual networks
-Create five virtual networks with [az network vnet create](/cli/azure/network/vnet#az-network-vnet-create). This example creates virtual networks named **VNetA**, **VNetB**,**VNetC** and **VNetD** in the **West US** location. Each virtual network has a tag of **networkType** used for dynamic membership. If you already have virtual networks you want create a mesh network with, you can skip to the next section.
+Create five virtual networks by using [az network vnet create](/cli/azure/network/vnet#az-network-vnet-create). This example creates virtual networks named *VNetA*, *VNetB*, *VNetC*, and *VNetD* in the West US location. Each virtual network has a tag of `networkType` that's used for dynamic membership. If you already have virtual networks that you want create a mesh network with, you can skip to the next section.
```azurecli az network vnet create \
az network vnet create \
--address-prefix "10.4.0.0/16" \ --tags "NetworkType=Test" ```+ ### Add a subnet to each virtual network
-Complete the configuration of the virtual networks by adding a /24 subnet to each one. Create a subnet configuration named **default** with [az network vnet subnet create](/cli/azure/network/vnet/subnet#az-network-vnet-subnet-create):
+Complete the configuration of the virtual networks by adding a */24* subnet to each one. Create a subnet configuration named *default* by using [az network vnet subnet create](/cli/azure/network/vnet/subnet#az-network-vnet-subnet-create):
```azurecli az network vnet subnet create \
az network vnet subnet create \
--vnet-name "VNetE" \ --address-prefix "10.4.0.0/24" ```+ ## Define membership for a mesh configuration
-Azure Virtual Network manager allows you two methods for adding membership to a network group. Static membership involves manually adding virtual networks, and dynamic membership involves using Azure Policy to dynamically add virtual networks based on conditions. Choose the option you wish to complete for your mesh configuration membership:
+Azure Virtual Network Manager allows two methods for adding membership to a network group. Static membership involves manually adding virtual networks, and dynamic membership involves using Azure Policy to dynamically add virtual networks based on conditions. Choose the option that you want to complete for your mesh configuration membership.
### Static membership option
-Using **static membership**, you manually add 3 VNets for your Mesh configuration to your Network Group with [az network manager group static-member create](/cli/azure/network/manager/group/static-member#az-network-manager-group-static-member-create). Replace <subscription_id> with the subscription these VNets were created under.
+By using static membership, you manually add three virtual networks for your mesh configuration to your network group via [az network manager group static-member create](/cli/azure/network/manager/group/static-member#az-network-manager-group-static-member-create). Replace `<subscription_id>` with the subscription that these virtual networks were created under.
```azurecli az network manager group static-member create \
az network manager group static-member create \
--resource-group "myAVNMResourceGroup" \ --resource-id "/subscriptions/<subscription_id>/resourceGroups/myAVNMResourceGroup/providers/Microsoft.Network/virtualnetworks/VNetC" ```+ ### Dynamic membership option
-Using [Azure Policy](concept-azure-policy-integration.md), you dynamically add the three VNets with a tag **networkType** value of *Prod* to the Network Group. These are the three virtual networks to become part of the mesh configuration.
+By using [Azure Policy](concept-azure-policy-integration.md), you can dynamically add the three virtual networks with a `networkType` value of `Prod` to the network group. These three virtual networks will become part of the mesh configuration.
+
+You can apply policies to a subscription or a management group, and you must always define them *at or above* the level where you create them. Only virtual networks within a policy scope are added to a network group.
-> [!NOTE]
-> Policies can be applied to a subscription or management group, and must always be defined *at or above* the level they're created. Only virtual networks within a policy scope are added to a Network Group.
+### Create a policy definition
-### Create a Policy definition
-Create a Policy definition with [az policy definition create](/cli/azure/policy/definition#az-policy-definition-create) for virtual networks tagged as **Prod**. Replace *<subscription_id>* with the subscription you want to apply this policy to. If you want to apply it to a management group, replace `--subscription <subscription_id>` with `--management-group <mgName>`
+Create a policy definition by using [az policy definition create](/cli/azure/policy/definition#az-policy-definition-create) for virtual networks tagged as `Prod`. Replace `<subscription_id>` with the subscription that you want to apply this policy to. If you want to apply it to a management group, replace `--subscription <subscription_id>` with `--management-group <mgName>`.
```azurecli az policy definition create \
az policy definition create \
--mode "Microsoft.Network.Data" ```
-### Apply a Policy definition
-Once a policy is defined, it must also be applied with [az policy assignment create](/cli/azure/policy/assignment#az-policy-assignment-create). Replace *<subscription_id>* with the subscription you want to apply this policy to. If you want to apply it to a management group, replace `--scope "/subscriptions/<subscription_id>"` with `--scope "/providers/Microsoft.Management/managementGroups/<mgName>`, and replace *<mgName\>* with your management group.
+### Apply a policy definition
+
+After you define a policy, you must apply it by using [az policy assignment create](/cli/azure/policy/assignment#az-policy-assignment-create). Replace `<subscription_id>` with the subscription that you want to apply this policy to. If you want to apply it to a management group, replace `--scope "/subscriptions/<subscription_id>"` with `--scope "/providers/Microsoft.Management/managementGroups/<mgName>`, and replace `<mgName\>` with your management group.
```azurecli
az policy assignment create \
## Create a configuration
-Now that the Network Group is created, and has the correct VNets, create a mesh network topology configuration with [az network manager connect-config create](/cli/azure/network/manager/connect-config#az-network-manager-connect-config-create). Replace <subscription_id> with your subscription.
+Now that you've created the network group and given it the correct virtual networks, create a mesh network topology configuration by using [az network manager connect-config create](/cli/azure/network/manager/connect-config#az-network-manager-connect-config-create). Replace `<subscription_id>` with your subscription.
```azurecli az network manager connect-config create \
az network manager connect-config create \
--network-manager-name "myAVNM" \ --resource-group "myAVNMResourceGroup" ```
-## Commit deployment
-For the configuration to take effect, commit the configuration to the target regions with [az network manager post-commit](/cli/azure/network/manager#az-network-manager-post-commit):
+## Commit the deployment
+
+For the configuration to take effect, commit the configuration to the target regions by using [az network manager post-commit](/cli/azure/network/manager#az-network-manager-post-commit):
```azurecli az network manager post-commit \
az network manager post-commit \
--target-locations "westus" \ --resource-group "myAVNMResourceGroup" ```
-## Verify configuration
-Virtual Networks display configurations applied to them with [az network manager list-effective-connectivity-config](/cli/azure/network/manager#az-network-manager-list-effective-connectivity-config):
+
+## Verify the configuration
+
+Virtual networks display configurations applied to them when you use [az network manager list-effective-connectivity-config](/cli/azure/network/manager#az-network-manager-list-effective-connectivity-config):
```azurecli az network manager list-effective-connectivity-config \
az network manager list-effective-connectivity-config \
--resource-group "myAVNMResourceGroup" \ --virtual-network-name "VNetD" ```
-For the virtual networks that are part of the connectivity configuration, you see an output similar to this:
+
+For the virtual networks that are part of the connectivity configuration, you get an output similar to this example:
```json {
For the virtual networks that are part of the connectivity configuration, you se
] } ```
-For virtual networks not part of the network group like **VNetD**, you see an output similar to this:
+
+For virtual networks that aren't part of the network group, like *VNetD*, an output similar to this example appears:
```json az network manager list-effective-connectivity-config --resource-group "myAVNMResourceGroup" --virtual-network-name "VNetD-test"
az network manager list-effective-connectivity-config --resource-group "myAV
"value": [] } ```+ ## Clean up resources
-If you no longer need the Azure Virtual Network Manager, you need to make sure all of following are true before you can delete the resource:
+If you no longer need the Azure Virtual Network Manager instance, make sure all of the following points are true before you delete the resource:
* There are no deployments of configurations to any region. * All configurations have been deleted. * All network groups have been deleted.
+To delete the resource:
+ 1. Remove the connectivity deployment by committing no configurations with [az network manager post-commit](/cli/azure/network/manager#az-network-manager-post-commit): ```azurecli
If you no longer need the Azure Virtual Network Manager, you need to make sure a
--resource-group "myAVNMResourceGroup" ```
-1. Remove the connectivity configuration with [az network manager connect-config delete](/cli/azure/network/manager/connect-config#az-network-manager-connect-config-delete):
+1. Remove the connectivity configuration by using [az network manager connect-config delete](/cli/azure/network/manager/connect-config#az-network-manager-connect-config-delete):
```azurecli az network manager connect-config delete \
If you no longer need the Azure Virtual Network Manager, you need to make sure a
--resource-group "myAVNMResourceGroup" ```
-1. Remove the network group with [az network manager group delete](/cli/azure/network/manager/group#az-network-manager-group-delete):
+1. Remove the network group by using [az network manager group delete](/cli/azure/network/manager/group#az-network-manager-group-delete):
```azurecli az network manager group delete \
If you no longer need the Azure Virtual Network Manager, you need to make sure a
--resource-group "myAVNMResourceGroup" ```
-1. Delete the network manager instance with [az network manager delete](/cli/azure/network/manager#az-network-manager-delete):
+1. Delete the network manager instance by using [az network manager delete](/cli/azure/network/manager#az-network-manager-delete):
```azurecli az network manager delete \
If you no longer need the Azure Virtual Network Manager, you need to make sure a
--resource-group "myAVNMResourceGroup" ```
-1. If you no longer need the resource created, delete the resource group with [az group delete](/cli/azure/group#az-group-delete):
+1. If you no longer need the resource that you created, delete the resource group by using [az group delete](/cli/azure/group#az-group-delete):
```azurecli az group delete \
If you no longer need the Azure Virtual Network Manager, you need to make sure a
## Next steps
-After you've created the Azure Virtual Network Manager, continue on to learn how to block network traffic by using the security admin configuration:
+Now that you've created an Azure Virtual Network Manager instance, learn how to block network traffic by using a security admin configuration:
> [!div class="nextstepaction"]
-[Block network traffic with security admin rules](how-to-block-network-traffic-portal.md)
-[Create a secured hub and spoke network](tutorial-create-secured-hub-and-spoke.md)
+> [Block network traffic with Azure Virtual Network Manager](how-to-block-network-traffic-portal.md)
virtual-network-manager Create Virtual Network Manager Portal https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/create-virtual-network-manager-portal.md
Title: 'Quickstart: Create a mesh network topology with Azure Virtual Network Manager using the Azure portal'
-description: Use this quickstart to learn how to create a mesh network topology with Virtual Network Manager using the Azure portal.
+description: Use this quickstart to learn how to create a mesh network topology with Virtual Network Manager by using the Azure portal.
Last updated 04/12/2023
-# Quickstart: Create a mesh network topology with Azure Virtual Network Manager using the Azure portal
+# Quickstart: Create a mesh network topology with Azure Virtual Network Manager by using the Azure portal
Get started with Azure Virtual Network Manager by using the Azure portal to manage connectivity for all your virtual networks.
-In this quickstart, you deploy three virtual networks and use Azure Virtual Network Manager to create a mesh network topology. Then you verify if the connectivity configuration got applied.
+In this quickstart, you deploy three virtual networks and use Azure Virtual Network Manager to create a mesh network topology. Then you verify that the connectivity configuration was applied.
> [!IMPORTANT]
-> Azure Virtual Network Manager is generally available for Virtual Network Manager and hub and spoke connectivity configurations.
+> Azure Virtual Network Manager is generally available for Virtual Network Manager and hub-and-spoke connectivity configurations. Mesh connectivity configurations and security admin rules remain in public preview.
>
-> Mesh connectivity configurations and security admin rules remain in public preview.
-> This preview version is provided without a service level agreement, and it's not recommended for production workloads. Certain features might not be supported or might have constrained capabilities.
-> For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
+> This preview version is provided without a service-level agreement, and we don't recommend it for production workloads. Certain features might not be supported or might have constrained capabilities. For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
## Prerequisites * An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
-## Create Virtual Network Manager
-Deploy a network manager instance with the defined scope and access you need.
+## Create a Virtual Network Manager instance
+
+Deploy a Virtual Network Manager instance with the defined scope and access that you need:
1. Sign in to the [Azure portal](https://portal.azure.com/).
-1. Select **+ Create a resource** and search for **Network Manager**. 1. Select **Network Manager > Create** to begin setting up Azure Virtual Network Manager.
+1. Select **+ Create a resource** and search for **Network Manager**. Then select **Network Manager** > **Create** to begin setting up Virtual Network Manager.
-1. On the **Basics** tab, enter or select the following information:
+1. On the **Basics** tab, enter or select the following information, and then select **Review + create**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/network-manager-basics-thumbnail.png" alt-text="Screenshot of Create a network manager Basics page." lightbox="./media/create-virtual-network-manager-portal/network-manager-basics-thumbnail.png":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/network-manager-basics-thumbnail.png" alt-text="Screenshot of basic information for creating a network manager." lightbox="./media/create-virtual-network-manager-portal/network-manager-basics-thumbnail.png":::
| Setting | Value | | - | -- |
- | Subscription | Select the subscription you want to deploy Azure Virtual Network Manager to. |
- | Resource group | Select **Create new** and enter **rg-learn-eastus-001**.
- | Name | Enter **vnm-learn-eastus-001**. |
- | Region | Enter **eastus** or a region of your choosing. Azure Virtual Network Manager can manage virtual networks in any region. The region selected is for where the Virtual Network Manager instance will be deployed. |
- | Description | *(Optional)* Provide a description about this Virtual Network Manager instance and the task it's managing. |
- | Scope and features | |
- | [Scope](concept-network-manager-scope.md#scope) | Select **Select scopes** and choose your subscription.</br> Select **Add to selected scope > Select**. </br> *Scope* is used to define the resources which Azure Virtual Network Manager can manage. You can choose subscriptions and management groups.
- | [Features](concept-network-manager-scope.md#features) | Select **Connectivity** and **Security Admin** from the dropdown list. </br> *Connectivity* - Enables the ability to create a full mesh or hub and spoke network topology between virtual networks within the scope. </br> *Security Admin* - Enables the ability to create global network security rules. |
+ | **Subscription** | Select the subscription where you want to deploy Virtual Network Manager. |
+ | **Resource group** | Select **Create new** and enter **rg-learn-eastus-001**.
+ | **Name** | Enter **vnm-learn-eastus-001**. |
+ | **Region** | Enter **eastus** or a region of your choosing. Virtual Network Manager can manage virtual networks in any region. The selected region is where the Virtual Network Manager instance will be deployed. |
+ | **Description** | *(Optional)* Provide a description about this Virtual Network Manager instance and the task it's managing. |
+ | [Scope](concept-network-manager-scope.md#scope) | Choose **Select scopes** and then select your subscription.</br> Select **Add to selected scope** > **Select**. </br> Scope information defines the resources that Virtual Network Manager can manage. You can choose subscriptions and management groups.
+ | [Features](concept-network-manager-scope.md#features) | Select **Connectivity** and **Security Admin** from the dropdown list. </br> **Connectivity** enables the creation of a full mesh or hub-and-spoke network topology between virtual networks within the scope. </br> **Security Admin** enables the creation of global network security rules. |
-1. Select **Review + create** and then select **Create** once validation has passed.
+1. Select **Create** after your configuration passes validation.
## Create virtual networks
-Create three virtual networks using the portal. Each virtual network has a tag of networkType used for dynamic membership. If you have existing virtual networks for your mesh configuration, you'll need to add tags listed in the table to your virtual networks and skip to the next section.
+Create three virtual networks by using the portal. Each virtual network has a `networkType` tag that's used for dynamic membership. If you have existing virtual networks for your mesh configuration, add the tags listed in the table to your virtual networks and skip to the next section.
-1. From the **Home** screen, select **+ Create a resource** and search for **Virtual networks**. Then select **Create** to begin configuring the virtual network.
+1. From the **Home** screen, select **+ Create a resource** and search for **Virtual networks**. Then select **Create** to begin configuring a virtual network.
1. On the **Basics** tab, enter or select the following information.
- :::image type="content" source="./media/create-virtual-network-manager-portal/create-vnet-basic.png" alt-text="Screenshot of create a virtual network basics page.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/create-vnet-basic.png" alt-text="Screenshot of basic information for creating a virtual network.":::
| Setting | Value | | - | -- |
- | Subscription | Select the subscription you want to deploy this virtual network into. |
- | Resource group | Select **rg-learn-eastus-001**.
- | Name | Enter a **vnet-learn-prod-eastus-001** for the virtual network name. |
- | Region | Select **(US) East US**. |
+ | **Subscription** | Select the subscription where you want to deploy this virtual network. |
+ | **Resource group** | Select **rg-learn-eastus-001**.
+ | **Virtual network name** | Enter **vnet-learn-prod-eastus-001**. |
+ | **Region** | Select **(US) East US**. |
-1. Select **Next** or the **IP addresses** tab and configure the following network address spaces:
+1. Select **Next** or the **IP addresses** tab, configure the following network address spaces, and then select **Review + create**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/create-vnet-ip.png" alt-text="Screenshot of create a virtual network IP addresses page.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/create-vnet-ip.png" alt-text="Screenshot of IP address information for creating a virtual network.":::
| Setting | Value | | -- | -- |
- | IPv4 address space | 10.0.0.0/16 |
- | Subnet name | default |
- | Subnet address space | 10.0.0.0/24 |
+ | **IPv4 address space** | 10.0.0.0/16 |
+ | **Subnet name** | default |
+ | **Subnet address space** | 10.0.0.0/24 |
-1. Select **Review + create** and then select **Create** once validation has passed to deploy the virtual network.
+1. After your configuration passes validation, select **Create** to deploy the virtual network.
-1. Repeat steps 2-5 to create more virtual networks with the following information:
+1. Repeat the preceding steps to create more virtual networks with the following information:
| Setting | Value | | - | -- |
- | Subscription | Select the same subscription you selected in step 3. |
- | Resource group | Select the **rg-learn-eastus-001**. |
- | Name | Enter **vnet-learn-prod-eastus-002** and **vnet-learn-test-eastus-003** for each additional virtual network. |
- | Region | Select **(US) East US** |
- | vnet-learn-prod-eastus-002 IP addresses | IPv4 address space: 10.1.0.0/16 </br> Subnet name: default </br> Subnet address space: 10.1.0.0/24|
- | vnet-learn-test-eastus-003 IP addresses | IPv4 address space: 10.2.0.0/16 </br> Subnet name: default </br> Subnet address space: 10.2.0.0/24|
+ | **Subscription** | Select the same subscription that you selected in step 2. |
+ | **Resource group** | Select **rg-learn-eastus-001**. |
+ | **Name** | Enter **vnet-learn-prod-eastus-002** and **vnet-learn-test-eastus-003** for each additional virtual network. |
+ | **Region** | Select **(US) East US**. |
+ | **vnet-learn-prod-eastus-002 IP addresses** | IPv4 address space: **10.1.0.0/16** </br> Subnet name: **default** </br> Subnet address space: **10.1.0.0/24**|
+ | **vnet-learn-test-eastus-003 IP addresses** | IPv4 address space: **10.2.0.0/16** </br> Subnet name: **default** </br> Subnet address space: **10.2.0.0/24**|
## Create a network group
-Virtual Network Manager applies configurations to groups of VNets by placing them in network groups. Create a network group as follows:
+Virtual Network Manager applies configurations to groups of virtual networks by placing them in network groups. To create a network group:
+
+1. Browse to the **rg-learn-eastus-001** resource group, and select the **vnm-learn-eastus-001** Virtual Network Manager instance.
-1. Browse to **rg-learn-eastus-001** resource group, and select the **vnm-learn-eastus-001** virtual network manager instance.
+1. Under **Settings**, select **Network groups**. Then select **Create**.
-1. Select **Network Groups** under **Settings**, then select **+ Create**.
+ :::image type="content" source="./media/create-virtual-network-manager-portal/add-network-group-2.png" alt-text="Screenshot of an empty list of network groups and the button for creating a network group.":::
- :::image type="content" source="./media/create-virtual-network-manager-portal/add-network-group-2.png" alt-text="Screenshot of add a network group.":::
+1. On the **Create a network group** pane, enter **ng-learn-prod-eastus-001** and select **Create**.
-1. On the **Create a network group** page, enter **ng-learn-prod-eastus-001** and Select **Create**.
+ :::image type="content" source="./media/create-virtual-network-manager-portal/create-network-group.png" alt-text="Screenshot of the pane for creating a network group." lightbox="./media/create-virtual-network-manager-portal/create-network-group.png":::
- :::image type="content" source="./media/create-virtual-network-manager-portal/create-network-group.png" alt-text="Screenshot of create a network group page." lightbox="./media/create-virtual-network-manager-portal/create-network-group.png":::
+1. Confirm that the new network group is now listed on the **Network groups** pane.
-1. The new network group is now listed on the **Network Groups** page.
- :::image type="content" source="./media/create-virtual-network-manager-portal/network-groups-list.png" alt-text="Screenshot of network group page with list of network groups.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/network-groups-list.png" alt-text="Screenshot of a newly created network group on the pane that list network groups.":::
-## Define membership for connectivity configuration
+## Define membership for a connectivity configuration
+
+After you create your network group, you add virtual networks as members. Choose one of the following options for your mesh membership configuration.
-Once your network group is created, you add virtual networks as members. Choose one of the options: *[Manually add membership](#manually-add-membership)* or *[Create policy to dynamically add members](#create-azure-policy-for-dynamic-membership)* with Azure Policy. Choose one of the options for your mesh membership configuration:
# [Manual membership](#tab/manualmembership)
-### Manually add membership
+### Add a membership manually
-In this task, you manually add two virtual networks for your Mesh configuration to your network group using these steps:
+In this task, you manually add two virtual networks for your mesh configuration to your network group:
-1. From the list of network groups, select **ng-learn-prod-eastus-001** and select **Add virtual networks** under *Manually add members* on the *ng-learn-prod-eastus-001* page.
+1. From the list of network groups, select **ng-learn-prod-eastus-001**. On the **ng-learn-prod-eastus-001** pane, under **Manually add members**, select **Add virtual networks**.
:::image type="content" source="./media/create-virtual-network-manager-portal/add-static-member.png" alt-text="Screenshot of add a virtual network f.":::
-1. On the **Manually add members** page, select **vnet-learn-prod-eastus-001** and **vnet-learn-prod-eastus-002**, and select **Add**.
+1. On the **Manually add members** pane, select **vnet-learn-prod-eastus-001** and **vnet-learn-prod-eastus-002**, and then select **Add**.
+
+ :::image type="content" source="./media/create-virtual-network-manager-portal/add-virtual-networks.png" alt-text="Screenshot of selecting virtual networks on the pane for manually adding members.":::
- :::image type="content" source="./media/create-virtual-network-manager-portal/add-virtual-networks.png" alt-text="Screenshot of add virtual networks to network group page.":::
+1. On the **Network Group** pane, under **Settings**, select **Group Members**. Confirm the membership of the group that you manually selected.
-1. On the **Network Group** page under **Settings**, select **Group Members** to view the membership of the group you manually selected.
- :::image type="content" source="media/create-virtual-network-manager-portal/group-members-list.png" alt-text="Screenshot of group membership under Group Membership." lightbox="media/create-virtual-network-manager-portal/group-members-list.png":::
+ :::image type="content" source="media/create-virtual-network-manager-portal/group-members-list.png" alt-text="Screenshot that shows a list of group members." lightbox="media/create-virtual-network-manager-portal/group-members-list.png":::
# [Azure Policy](#tab/azurepolicy)
-### Create Azure Policy for dynamic membership
-Using [Azure Policy](concept-azure-policy-integration.md), you define a condition to dynamically add two virtual networks to your network group when the name of the virtual network includes **prod** using these steps:
+### Create a policy definition for dynamic membership
-1. From the list of network groups, select **ng-learn-prod-eastus-001** and select **Create Azure policy** under *Create policy to dynamically add members*.
+By using [Azure Policy](concept-azure-policy-integration.md), you define a condition to dynamically add two virtual networks to your network group when the name of the virtual network includes *prod*:
- :::image type="content" source="media/create-virtual-network-manager-portal/define-dynamic-membership.png" alt-text="Screenshot of Create Azure Policy button.":::
+1. From the list of network groups, select **ng-learn-prod-eastus-001**. Under **Create policy to dynamically add members**, select **Create Azure policy**.
-1. On the **Create Azure policy** page, select or enter the following information:
+ :::image type="content" source="media/create-virtual-network-manager-portal/define-dynamic-membership.png" alt-text="Screenshot of the button for creating an Azure policy.":::
- :::image type="content" source="./media/create-virtual-network-manager-portal/network-group-conditional.png" alt-text="Screenshot of create a network group conditional statements tab.":::
+1. On the **Create Azure policy** pane, select or enter the following information, and then select **Preview resources**.
+
+ :::image type="content" source="./media/create-virtual-network-manager-portal/network-group-conditional.png" alt-text="Screenshot of the pane for creating an Azure policy, including criteria for definitions.":::
| Setting | Value | | - | -- |
- | Policy name | Enter **azpol-learn-prod-eastus-001** in the text box. |
- | Scope | Select **Select Scopes** and choose your current subscription. |
- | Criteria | |
- | Parameter | Select **Name** from the drop-down.|
- | Operator | Select **Contains** from the drop-down.|
- | Condition | Enter **-prod** for the condition in the text box. |
+ | **Policy name** | Enter **azpol-learn-prod-eastus-001**. |
+ | **Scope** | Choose **Select scopes** and then select your current subscription. |
+ | **Parameter** | Select **Name** from the dropdown list.|
+ | **Operator** | Select **Contains** from the dropdown list.|
+ | **Condition** | Enter **-prod**. |
-1. Select **Preview resources** to view the **Effective virtual networks** page and select **Close**. This page shows the virtual networks that will be added to the network group based on the conditions defined in Azure Policy.
+1. The **Effective virtual networks** pane shows the virtual networks that will be added to the network group based on the conditions that you defined in Azure Policy. When you're ready, select **Close**.
- :::image type="content" source="media/create-virtual-network-manager-portal/effective-virtual-networks.png" alt-text="Screenshot of effective virtual networks page.":::
+ :::image type="content" source="media/create-virtual-network-manager-portal/effective-virtual-networks.png" alt-text="Screenshot of the pane for effective virtual networks.":::
1. Select **Save** to deploy the group membership. It can take up to one minute for the policy to take effect and be added to your network group.
-1. On the **Network Group** page under **Settings**, select **Group Members** to view the membership of the group based on the conditions defined in Azure Policy. You'll note the **Source** is listed as **azpol-learn-prod-eastus-001 - subscriptions/subscription_id**.
+1. On the **Network Group** pane, under **Settings**, select **Group members** to view the membership of the group based on the conditions that you defined in Azure Policy. Confirm that **Source** is listed as **azpol-learn-prod-eastus-001 - subscriptions/subscription_id**.
- :::image type="content" source="media/create-virtual-network-manager-portal/group-members-list.png" alt-text="Screenshot of group membership under Group Membership." lightbox="media/create-virtual-network-manager-portal/group-members-list.png":::
+ :::image type="content" source="media/create-virtual-network-manager-portal/group-members-list.png" alt-text="Screenshot of listed group members with a configured source." lightbox="media/create-virtual-network-manager-portal/group-members-list.png":::
## Create a configuration
-Now that the Network Group is created, and has the correct VNets, create a mesh network topology configuration. Replace **<subscription_id>** with your subscription and follow these steps:
+Now that you've created the network group and given it the correct virtual networks, create a mesh network topology configuration. Replace `<subscription_id>` with your subscription.
-1. Select **Configurations** under **Settings**, then select **+ Create**.
+1. Under **Settings**, select **Configurations**. Then select **Create**.
-1. Select **Connectivity configuration** from the drop-down menu to begin creating a connectivity configuration.
+1. Select **Connectivity configuration** from the dropdown menu to begin creating a connectivity configuration.
- :::image type="content" source="./media/create-virtual-network-manager-portal/connectivity-configuration-dropdown.png" alt-text="Screenshot of configuration drop-down menu.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/connectivity-configuration-dropdown.png" alt-text="Screenshot of the configuration dropdown menu.":::
-1. On the **Basics** page, enter the following information, and select **Next: Topology >**.
+1. On the **Basics** tab, enter the following information, and then select **Next: Topology**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/connectivity-configuration.png" alt-text="Screenshot of add a connectivity configuration page.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/connectivity-configuration.png" alt-text="Screenshot of the pane for adding a connectivity configuration.":::
| Setting | Value | | - | -- |
- | Name | Enter **cc-learn-prod-eastus-001**. |
- | Description | *(Optional)* Provide a description about this connectivity configuration. |
+ | **Name** | Enter **cc-learn-prod-eastus-001**. |
+ | **Description** | *(Optional)* Provide a description about this connectivity configuration. |
-1. On the **Topology** tab, select the **Mesh** topology if not selected, and leave the **Enable mesh connectivity across regions** unchecked. Cross-region connectivity isn't required for this set up since all the virtual networks are in the same region.
+1. On the **Topology** tab, select the **Mesh** topology if it's not selected, and leave the **Enable mesh connectivity across regions** checkbox cleared. Cross-region connectivity isn't required for this setup, because all the virtual networks are in the same region. When you're ready, select **Add** > **Add network group**.
:::image type="content" source="./media/create-virtual-network-manager-portal/topology-configuration.png" alt-text="Screenshot of topology selection for network group connectivity configuration.":::
-1. Select **+ Add > Add network group** and select **ng-learn-prod-eastus-001** under **Network Groups**. Choose **Select** to add the network group to the configuration.
+1. Under **Network groups**, select **ng-learn-prod-eastus-001**. Then choose **Select** to add the network group to the configuration.
- :::image type="content" source="./media/create-virtual-network-manager-portal/add-network-group-configuration.png" alt-text="Screenshot of add a network group to a connectivity configuration.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/add-network-group-configuration.png" alt-text="Screenshot of adding a network group to a connectivity configuration.":::
-1. Select the **Visualization** tab to view the topology of the configuration. This tab shows you a visual representation of the network group you added to the configuration.
+1. Select the **Visualization** tab to view the topology of the configuration. This tab shows a visual representation of the network group that you added to the configuration.
- :::image type="content" source="./media/create-virtual-network-manager-portal/preview-topology.png" alt-text="Screenshot of preview topology for network group connectivity configuration.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/preview-topology.png" alt-text="Screenshot of previewing a topology for network group connectivity configuration.":::
-1. Select **Next: Review + Create >** and **Create** to create the configuration.
+1. Select **Next: Review + Create** > **Create** to create the configuration.
- :::image type="content" source="./media/create-virtual-network-manager-portal/create-connectivity-configuration.png" alt-text="Screenshot of create a connectivity configuration.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/create-connectivity-configuration.png" alt-text="Screenshot of the tab for reviewing and creating a connectivity configuration.":::
-1. Once the deployment completes, select **Refresh**, and you see the new connectivity configuration added to the **Configurations** page.
+1. After the deployment finishes, select **Refresh**. The new connectivity configuration appears on the **Configurations** pane.
- :::image type="content" source="./media/create-virtual-network-manager-portal/connectivity-configuration-list.png" alt-text="Screenshot of connectivity configuration list.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/connectivity-configuration-list.png" alt-text="Screenshot of a connectivity configuration list.":::
## Deploy the connectivity configuration
-To have your configurations applied to your environment, you need to commit the configuration by deployment. You need to deploy the configuration to the **East US** region where the virtual networks are deployed.
+To apply your configurations to your environment, you need to commit the configuration by deployment. Deploy the configuration to the East US region where the virtual networks are deployed:
-1. Select **Deployments** under **Settings**, then select **Deploy configurations**.
+1. Under **Settings**, select **Deployments**. Then select **Deploy configurations**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/deployments.png" alt-text="Screenshot of deployments page in Network Manager.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/deployments.png" alt-text="Screenshot of the pane for deployments in Virtual Network Manager.":::
-1. Select the following settings:
+1. Select the following settings, and then select **Next**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/deploy-configuration.png" alt-text="Screenshot of deploy a configuration page.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/deploy-configuration.png" alt-text="Screenshot of the tab for configuring a goal state for network resources.":::
| Setting | Value | | - | -- |
- | Configurations | Select **Include connectivity configurations in your goal state** . |
- | Connectivity configurations | Select **cc-learn-prod-eastus-001**. |
- | Target regions | Select **East US** as the deployment region. |
+ | **Configurations** | Select **Include connectivity configurations in your goal state**. |
+ | **Connectivity configurations** | Select **cc-learn-prod-eastus-001**. |
+ | **Target regions** | Select **East US** as the deployment region. |
-1. Select **Next** and then select **Deploy** to complete the deployment.
+1. Select **Deploy** to complete the deployment.
- :::image type="content" source="./media/create-virtual-network-manager-portal/deployment-confirmation.png" alt-text="Screenshot of deployment confirmation message.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/deployment-confirmation.png" alt-text="Screenshot of the tab for reviewing a deployment.":::
-1. The deployment will display in the list for the selected region. The deployment of the configuration can take a few minutes to complete.
+1. Confirm that the deployment appears in the list for the selected region. The deployment of the configuration can take a few minutes to finish.
- :::image type="content" source="./media/create-virtual-network-manager-portal/deployment-in-progress.png" alt-text="Screenshot of configuration deployment in progress status.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/deployment-in-progress.png" alt-text="Screenshot of a configuration deployment that shows a status of succeeded.":::
## Verify configuration deployment
-Use the **Network Manager** section for each virtual network to verify whether configuration was deployed in these steps:
+Use the **Network Manager** section for each virtual network to verify that you deployed your configuration:
-1. Go to **vnet-learn-prod-eastus-001** virtual network and select **Network Manager** under **Settings**. Verify that **cc-learn-prod-eastus-001** is listed under **Connectivity Configurations** tab.
+1. Go to the **vnet-learn-prod-eastus-001** virtual network.
+1. Under **Settings**, select **Network Manager**.
+1. On the **Connectivity Configurations** tab, verify that **cc-learn-prod-eastus-001** appears in the list.
- :::image type="content" source="./media/create-virtual-network-manager-portal/vnet-configuration-association.png" alt-text="Screenshot of connectivity configuration associated with vnet-learn-prod-eastus-001 virtual network." lightbox="./media/create-virtual-network-manager-portal/vnet-configuration-association.png":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/vnet-configuration-association.png" alt-text="Screenshot of a connectivity configuration listed for a virtual network." lightbox="./media/create-virtual-network-manager-portal/vnet-configuration-association.png":::
-1. Repeat the previous step on **vnet-learn-prod-eastus-002**.
+1. Repeat the previous steps on **vnet-learn-prod-eastus-002**.
## Clean up resources
-If you no longer need Azure Virtual Network Manager, the following steps will remove all configurations, network groups, and Virtual Network Manager.
-
-> [!NOTE]
-> Before you can remove Azure Virtual Network Manager, you must remove all deployments, configurations, and network groups.
+If you no longer need Azure Virtual Network Manager, you can remove it after you remove all configurations, deployments, and network groups:
-1. To remove all configurations from a region, start in the virtual network manager and select **Deploy configurations**. Select the following settings:
+1. To remove all configurations from a region, start in Virtual Network Manager and select **Deploy configurations**. Select the following settings, and then select **Next**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/none-configuration.png" alt-text="Screenshot of deploying a none connectivity configuration.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/none-configuration.png" alt-text="Screenshot of the tab for configuring a goal state for network resources, with the option for removing existing connectivity configurations selected.":::
| Setting | Value | | - | -- |
- | Configurations | Select **Include connectivity configurations in your goal state**. |
- | Connectivity configurations | Select the ****None - Remove existing connectivity configurations**** configuration. |
- | Target regions | Select **East US** as the deployed region. |
+ | **Configurations** | Select **Include connectivity configurations in your goal state**. |
+ | **Connectivity configurations** | Select **None - Remove existing connectivity configurations**. |
+ | **Target regions** | Select **East US** as the deployed region. |
-1. Select **Next** and select **Deploy** to complete the deployment removal.
+1. Select **Deploy** to complete the deployment removal.
-1. To delete a configuration, select **Configurations** under **Settings** from the left pane of Azure Virtual Network Manager. Select the checkbox next to the configuration you want to remove and then select **Delete** at the top of the resource page.
+1. To delete a configuration, go to the left pane of Virtual Network Manager. Under **Settings**, select **Configurations**. Select the checkbox next to the configuration that you want to remove, and then select **Delete** at the top of the resource pane.
-1. On the **Delete a configuration** page, select the following options:
+1. On the **Delete a configuration** pane, select the following options, and then select **Delete**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/configuration-delete-options.png" alt-text="Screenshot of configuration to be deleted option selection.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/configuration-delete-options.png" alt-text="Screenshot of the pane for deleting a configuration.":::
| Setting | Value | | - | -- |
- | Delete option | Select **Force delete the resource and all dependent resources**. |
- | Confirm deletion | Enter the name of the configuration. In this example, it's **cc-learn-prod-eastus-001**. |
+ | **Delete option** | Select **Force delete the resource and all dependent resources**. |
+ | **Confirm deletion** | Enter the name of the configuration. In this example, it's **cc-learn-prod-eastus-001**. |
-1. To delete a network group, select **Network Groups** under **Settings** from the left pane of Azure Virtual Network Manager. Select the checkbox next to the network group you want to remove and then select **Delete** at the top of the resource page.
+1. To delete a network group, go to the left pane of Virtual Network Manager. Under **Settings**, select **Network groups**. Select the checkbox next to the network group that you want to remove, and then select **Delete** at the top of the resource pane.
-1. On the **Delete a network group** page, select the following options:
+1. On the **Delete a network group** pane, select the following options, and then select **Delete**.
:::image type="content" source="./media/create-virtual-network-manager-portal/network-group-delete-options.png" alt-text="Screenshot of Network group to be deleted option selection." lightbox="./media/create-virtual-network-manager-portal/network-group-delete-options.png"::: | Setting | Value | | - | -- |
- | Delete option | Select **Force delete the resource and all dependent resources**. |
- | Confirm deletion | Enter the name of the network group. In this example, it's **ng-learn-prod-eastus-001**. |
+ | **Delete option** | Select **Force delete the resource and all dependent resources**. |
+ | **Confirm deletion** | Enter the name of the network group. In this example, it's **ng-learn-prod-eastus-001**. |
-1. Select **Delete** and Select **Yes** to confirm the network group deletion.
+1. Select **Yes** to confirm the network group deletion.
-1. Once all network groups have been removed, select **Overview** from the left pane of Azure Virtual Network Manager and select **Delete**.
+1. After you remove all network groups, go to the left pane of Virtual Network Manager. Select **Overview**, and then select **Delete**.
-1. On the **Delete a network manager** page, select the following options and select **Delete**. Select **Yes** to confirm the deletion.
+1. On the **Delete a network manager** pane, select the following options, and then select **Delete**.
- :::image type="content" source="./media/create-virtual-network-manager-portal/network-manager-delete.png" alt-text="Screenshot of network manager to be deleted option selection.":::
+ :::image type="content" source="./media/create-virtual-network-manager-portal/network-manager-delete.png" alt-text="Screenshot of the pane for deleting a network manager.":::
| Setting | Value | | - | -- |
- | Delete option | Select **Force delete the resource and all dependent resources**. |
- | Confirm deletion | Enter the name of the network manager. In this example, it's **vnm-learn-eastus-001**. |
+ | **Delete option** | Select **Force delete the resource and all dependent resources**. |
+ | **Confirm deletion** | Enter the name of the Virtual Network Manager instance. In this example, it's **vnm-learn-eastus-001**. |
-1. To delete the resource group and virtual networks, locate **rg-learn-eastus-001** and select the **Delete resource group**. Confirm that you want to delete by entering **rg-learn-eastus-001** in the textbox, then select **Delete**
+1. Select **Yes** to confirm the deletion.
+
+1. To delete the resource group and virtual networks, locate **rg-learn-eastus-001** and select **Delete resource group**. Confirm that you want to delete by entering **rg-learn-eastus-001** in the text box, and then select **Delete**.
## Next steps
-After you've created the Azure Virtual Network Manager, continue on to learn how to block network traffic by using a security admin configuration:
+Now that you've created an Azure Virtual Network Manager instance, learn how to block network traffic by using a security admin configuration:
> [!div class="nextstepaction"]-
-[Block network traffic with security admin rules](how-to-block-network-traffic-portal.md)
-[Create a secured hub and spoke network](tutorial-create-secured-hub-and-spoke.md)
+> [Block network traffic with Azure Virtual Network Manager](how-to-block-network-traffic-portal.md)
virtual-network-manager Create Virtual Network Manager Powershell https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/create-virtual-network-manager-powershell.md
Title: 'Quickstart: Create a mesh network with Azure Virtual Network Manager using Azure PowerShell'
-description: Use this quickstart to learn how to create a mesh network with Virtual Network Manager using Azure PowerShell.
+ Title: 'Quickstart: Create a mesh network topology with Azure Virtual Network Manager using Azure PowerShell'
+description: Use this quickstart to learn how to create a mesh network topology with Virtual Network Manager by using Azure PowerShell.
Last updated 04/12/2023
-# Quickstart: Create a mesh network with Azure Virtual Network Manager using Azure PowerShell
+# Quickstart: Create a mesh network topology with Azure Virtual Network Manager by using Azure PowerShell
-Get started with Azure Virtual Network Manager by using the Azure PowerShell to manage connectivity for your virtual networks.
+Get started with Azure Virtual Network Manager by using Azure PowerShell to manage connectivity for your virtual networks.
In this quickstart, you deploy three virtual networks and use Azure Virtual Network Manager to create a mesh network topology.
+Perform this quickstart by using PowerShell locally, not through Azure Cloud Shell. The version of *Az.Network* in Azure Cloud Shell does not currently support the Azure Virtual Network Manager cmdlets.
+ > [!IMPORTANT]
-> Azure Virtual Network Manager is generally available for Virtual Network Manager and hub and spoke connectivity configurations.
+> Azure Virtual Network Manager is generally available for Virtual Network Manager and hub-and-spoke connectivity configurations. Mesh connectivity configurations and security admin rules remain in public preview.
>
-> Mesh connectivity configurations and security admin rules remain in public preview.
-> This preview version is provided without a service level agreement, and it's not recommended for production workloads. Certain features might not be supported or might have constrained capabilities.
-> For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
+> This preview version is provided without a service-level agreement, and we don't recommend it for production workloads. Certain features might not be supported or might have constrained capabilities. For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
## Prerequisites * An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
-> [!IMPORTANT]
-> Perform this quickstart using PowerShell locally, not through Azure Cloud Shell. The version of `Az.Network` in Azure Cloud Shell does not currently support the Azure Virtual Network Manager cmdlets.
-
-## Sign in to your Azure account and select your subscription
-
-To begin your configuration, sign in to your Azure account. Use the following examples to help you connect:
+## Sign in to your Azure account and select your subscription
-Sign in to Azure
+To begin your configuration, sign in to your Azure account:
```azurepowershell Connect-AzAccount ```
-Connect to your subscription
+Then, connect to your subscription:
```azurepowershell Set-AzContext -Subscription <subscription name or id> ```
-## Install Azure PowerShell module
-Install the latest *Az.Network* Azure PowerShell module using this command:
+## Install the Azure PowerShell module
+
+Install the latest *Az.Network* Azure PowerShell module by using this command:
```azurepowershell Install-Module -Name Az.Network -RequiredVersion 5.3.0 ```+ ## Create a resource group
-Before you can create an Azure Virtual Network Manager, you have to create a resource group to host the Network Manager. Create a resource group with [New-AzResourceGroup](/powershell/module/az.Resources/New-azResourceGroup). This example creates a resource group named **vnm-learn-eastus-001ResourceGroup** in the **WestUS** location.
+Before you can create an Azure Virtual Network Manager instance, you have to create a resource group to host it. Create a resource group by using [New-AzResourceGroup](/powershell/module/az.Resources/New-azResourceGroup). This example creates a resource group named *vnm-learn-eastus-001ResourceGroup* in the East US location:
```azurepowershell
New-AzResourceGroup @rg
## Define the scope and access type
-Define the scope and access type for the Azure Virtual Network Manager instance with [New-AzNetworkManagerScope](/powershell/module/az.network/new-aznetworkmanagerscope) This example defines a scope with a single subscription and sets the access type to **Connectivity**. Replace with the **<subscription_id>** of the subscription you want to manage with Azure Virtual Network Manager.
+Define the scope and access type for the Azure Virtual Network Manager instance by using [New-AzNetworkManagerScope](/powershell/module/az.network/new-aznetworkmanagerscope). This example defines a scope with a single subscription and sets the access type to *Connectivity*. Replace `<subscription_id>` with the ID of the subscription that you want to manage through Azure Virtual Network Manager.
```azurepowershell
$access.Add("Connectivity");
$scope = New-AzNetworkManagerScope -Subscription $subGroup ```
-## Create Virtual Network Manager
-Create the Virtual Network Manager with [New-AzNetworkManager](/powershell/module/az.network/new-aznetworkmanager). This example creates an Azure Virtual Network Manager named **vnm-learn-eastus-001** in the East Us location.
+## Create a Virtual Network Manager instance
+
+Create a Virtual Network Manager instance by using [New-AzNetworkManager](/powershell/module/az.network/new-aznetworkmanager). This example creates an instance named *vnm-learn-eastus-001* in the East US location:
```azurepowershell $avnm = @{
$networkmanager = New-AzNetworkManager @avnm
## Create three virtual networks
-Create three virtual networks with [New-AzVirtualNetwork](/powershell/module/az.network/new-azvirtualnetwork). This example creates virtual networks named **vnet-learn-prod-eastus-001**, **vnet-learn-prod-eastus-002** and **vnet-learn-test-eastus-003** in the **East Us** location. If you already have virtual networks you want create a mesh network with, you can skip to the next section.
+Create three virtual networks by using [New-AzVirtualNetwork](/powershell/module/az.network/new-azvirtualnetwork). This example creates virtual networks named *vnet-learn-prod-eastus-001*, *vnet-learn-prod-eastus-002*, and *vnet-learn-test-eastus-003* in the East US location. If you already have virtual networks that you want create a mesh network with, you can skip to the next section.
```azurepowershell $vnet001 = @{
$vnet_learn_test_eastus_003 = New-AzVirtualNetwork @vnet003
### Add a subnet to each virtual network
-To complete the configuration of the virtual networks, create a subnet configuration named **default** with [Add-AzVirtualNetworkSubnetConfig](/powershell/module/az.network/add-azvirtualnetworksubnetconfig) with a subnet address prefix of **/24**. Then, use [Set-AzVirtualNetwork](/powershell/module/az.network/set-azvirtualnetwork) to apply the subnet configuration to the virtual network.
+To complete the configuration of the virtual networks, create a subnet configuration named *default* with a subnet address prefix of */24* by using [Add-AzVirtualNetworkSubnetConfig](/powershell/module/az.network/add-azvirtualnetworksubnetconfig). Then, use [Set-AzVirtualNetwork](/powershell/module/az.network/set-azvirtualnetwork) to apply the subnet configuration to the virtual network.
```azurepowershell $subnet_vnet001 = @{
$vnet_learn_test_eastus_003 | Set-AzVirtualNetwork
``` ## Create a network group
-Virtual Network Manager applies configurations to groups of VNets by placing them in network groups. Create a network group with [New-AzNetworkManagerGroup](/powershell/module/az.network/new-aznetworkmanagergroup). This example creates a network group named **ng-learn-prod-eastus-001** in the **East Us** location.
+
+Virtual Network Manager applies configurations to groups of virtual networks by placing them in network groups. Create a network group by using [New-AzNetworkManagerGroup](/powershell/module/az.network/new-aznetworkmanagergroup). This example creates a network group named *ng-learn-prod-eastus-001* in the East US location:
```azurepowershell $ng = @{
$ng = @{
## Define membership for a mesh configuration
-Once your network group is created, you define a network group's membership by adding virtual networks. Choose one of the options to define network group membership:
+After you create your network group, you define its membership by adding virtual networks. You can add these networks manually or by using Azure Policy.
-- Add membership manually-- Create a policy for dynamic membership # [Manual membership](#tab/manualmembership) ### Add membership manually
-In this task, you add the static members **vnet-learn-prod-eastus-001** and **vnet-learn-prod-eastus-002** to the network group **ng-learn-prod-eastus-001** using [New-AzNetworkManagerStaticMember](/powershell/module/az.network/new-aznetworkmanagerstaticmember).
+In this task, you add the static members *vnet-learn-prod-eastus-001* and *vnet-learn-prod-eastus-002* to the network group *ng-learn-prod-eastus-001* by using [New-AzNetworkManagerStaticMember](/powershell/module/az.network/new-aznetworkmanagerstaticmember).
-> [!NOTE]
-> Static members must have a network group scoped unique name. It's recommended to use a consistent hash of the virtual network ID. This is an approach using the ARM Templates uniqueString() implementation.
+Static members must have a unique name that's scoped to the network group. We recommend that you use a consistent hash of the virtual network ID. This approach uses the Azure Resource Manager template's `uniqueString()` implementation.
```azurepowershell function Get-UniqueString ([string]$id, $length=13)
In this task, you add the static members **vnet-learn-prod-eastus-001** and **vn
-join ($hashArray[1..$length] | ForEach-Object { [char]($_ % 26 + [byte][char]'a') }) } ```
-
+ ```azurepowershell $sm_vnet001 = @{ Name = Get-UniqueString $vnet_learn_prod_eastus_001.Id
$sm_vnet001 = @{
} $sm_vnet001 = New-AzNetworkManagerStaticMember @sm_vnet001 ```
-
+ ```azurepowershell $sm_vnet002 = @{ Name = Get-UniqueString $vnet_learn_prod_eastus_002.Id
$sm_vnet002 = @{
# [Azure Policy](#tab/azurepolicy)
-### Create a policy for dynamic membership
+### Create a policy definition for dynamic membership
-Using [Azure Policy](concept-azure-policy-integration.md), you define a condition to dynamically add two virtual networks to your network group when the name of the virtual network name includes **-prod** in the virtual network name.
+By using [Azure Policy](concept-azure-policy-integration.md), you define a condition to dynamically add two virtual networks to your network group when the name of the virtual network includes *-prod*.
> [!NOTE]
-> It is recommended to scope all of your conditionals to only scan for type `Microsoft.Network/virtualNetworks` for efficiency.
+> We recommend that you scope all of your conditionals to scan for only type `Microsoft.Network/virtualNetworks`, for efficiency.
-1. Define the conditional statement and store it in a variable.
+1. Define the conditional statement and store it in a variable:
```azurepowershell $conditionalMembership = '{
Using [Azure Policy](concept-azure-policy-integration.md), you define a conditio
}' ```
-
-1. Create the Azure Policy definition using the conditional statement defined in the last step using [New-AzPolicyDefinition](/powershell/module/az.resources/new-azpolicydefinition). In this example, the policy definition name is prefixed with **poldef-learn-prod-** and suffixed with a unique string generated from a consistent hash the network group ID. Policy resources must have a scope unique name.
+
+1. Create the Azure Policy definition by using the conditional statement defined in the previous step and using [New-AzPolicyDefinition](/powershell/module/az.resources/new-azpolicydefinition).
+
+ In this example, the policy definition name is prefixed with *poldef-learn-prod-* and suffixed with a unique string that's generated from a consistent hash in the network group ID. Policy resources must have a scope unique name.
```azurepowershell function Get-UniqueString ([string]$id, $length=13)
Using [Azure Policy](concept-azure-policy-integration.md), you define a conditio
$UniqueString = Get-UniqueString $ng.Id ```
-
+ ```azurepowershell $polDef = @{ Name = "poldef-learn-prod-"+$UniqueString
Using [Azure Policy](concept-azure-policy-integration.md), you define a conditio
$policyDefinition = New-AzPolicyDefinition @polDef ```
-
-1. Assign the policy definition at a scope within your network managers scope for it to begin taking effect.
+
+1. Assign the policy definition at a scope within your network manager's scope so that it can begin taking effect:
```azurepowershell $polAssign = @{
Using [Azure Policy](concept-azure-policy-integration.md), you define a conditio
$policyAssignment = New-AzPolicyAssignment @polAssign ```
-
+++ ## Create a connectivity configuration
-In this task, you create a connectivity configuration with the network group **ng-learn-prod-eastus-001** using [New-AzNetworkManagerConnectivityConfiguration](/powershell/module/az.network/new-aznetworkmanagerconnectivityconfiguration) and [New-AzNetworkManagerConnectivityGroupItem](/powershell/module/az.network/new-aznetworkmanagerconnectivitygroupitem).
+In this task, you create a connectivity configuration with the network group *ng-learn-prod-eastus-001* by using [New-AzNetworkManagerConnectivityConfiguration](/powershell/module/az.network/new-aznetworkmanagerconnectivityconfiguration) and [New-AzNetworkManagerConnectivityGroupItem](/powershell/module/az.network/new-aznetworkmanagerconnectivitygroupitem):
-1. Create a connectivity group item.
+1. Create a connectivity group item:
```azurepowershell $gi = @{
In this task, you create a connectivity configuration with the network group **n
} $groupItem = New-AzNetworkManagerConnectivityGroupItem @gi ```
-
-1. Create a configuration group and add connectivity group item to it.
+
+1. Create a configuration group and add a connectivity group item to it:
```azurepowershell [System.Collections.Generic.List[Microsoft.Azure.Commands.Network.Models.NetworkManager.PSNetworkManagerConnectivityGroupItem]]$configGroup = @() $configGroup.Add($groupItem) ```
-1. Create the connectivity configuration with the configuration group.
+1. Create the connectivity configuration with the configuration group:
```azurepowershell $config = @{
In this task, you create a connectivity configuration with the network group **n
### Commit deployment
-Commit the configuration to the target regions with Deploy-AzNetworkManagerCommit. This triggers your configuration to begin taking effect.
+Commit the configuration to the target regions by using `Deploy-AzNetworkManagerCommit`. This step triggers your configuration to begin taking effect.
```azurepowershell [System.Collections.Generic.List[string]]$configIds = @()
Deploy-AzNetworkManagerCommit @deployment
## Clean up resources
-If you no longer need the Azure Virtual Network Manager, you need to make sure all of following is true before you can delete the resource:
+If you no longer need the Azure Virtual Network Manager instance, make sure all of following points are true before you delete the resource:
* There are no deployments of configurations to any region. * All configurations have been deleted. * All network groups have been deleted.
-1. Remove the connectivity deployment by deploying an empty configuration with Deploy-AzNetworkManagerCommit.
+To delete the resource:
+
+1. Remove the connectivity deployment by deploying an empty configuration via `Deploy-AzNetworkManagerCommit`:
```azurepowershell [System.Collections.Generic.List[string]]$configIds = @()
If you no longer need the Azure Virtual Network Manager, you need to make sure a
Deploy-AzNetworkManagerCommit @removedeployment ```
-1. Remove the connectivity configuration with Remove-AzNetworkManagerConnectivityConfiguration
+1. Remove the connectivity configuration by using `Remove-AzNetworkManagerConnectivityConfiguration`:
```azurepowershell Remove-AzNetworkManagerConnectivityConfiguration -Name $connectivityconfig.Name -ResourceGroupName $rg.Name -NetworkManagerName $networkManager.Name ```
-2. Remove the policy resources with Remove-AzPolicy*
+
+1. Remove the policy resources by using `Remove-AzPolicy*`:
```azurepowershell
If you no longer need the Azure Virtual Network Manager, you need to make sure a
```
-3. Remove the network group with Remove-AzNetworkManagerGroup.
+1. Remove the network group by using `Remove-AzNetworkManagerGroup`:
```azurepowershell Remove-AzNetworkManagerGroup -Name $ng.Name -ResourceGroupName $rg.Name -NetworkManagerName $networkManager.Name ```
-4. Delete the network manager instance with Remove-AzNetworkManager.
+1. Delete the Virtual Network Manager instance by using `Remove-AzNetworkManager`:
```azurepowershell Remove-AzNetworkManager -name $networkManager.Name -ResourceGroupName $rg.Name ```
-5. If you no longer need the resource created, delete the resource group with [Remove-AzResourceGroup](/powershell/module/az.resources/remove-azresourcegroup).
+1. If you no longer need the resource that you created, delete the resource group by using [Remove-AzResourceGroup](/powershell/module/az.resources/remove-azresourcegroup):
```azurepowershell Remove-AzResourceGroup -Name $rg.Name -Force
If you no longer need the Azure Virtual Network Manager, you need to make sure a
## Next steps
+Now that you've created an Azure Virtual Network Manager instance, learn how to block network traffic by using a security admin configuration:
+ > [!div class="nextstepaction"]
-> Learn how to [Block network traffic with security admin rules](how-to-block-network-traffic-powershell.md)
+> [Block network traffic with Azure Virtual Network Manager](how-to-block-network-traffic-powershell.md)
virtual-network-manager How To Create Hub And Spoke Powershell https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/how-to-create-hub-and-spoke-powershell.md
In this article, you'll learn how to create a hub and spoke network topology wit
## Prerequisites * Read about [Hub-and-spoke](concept-connectivity-configuration.md#hub-and-spoke-topology) network topology.
-* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-powershell.md#create-virtual-network-manager).
+* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-powershell.md#create-a-virtual-network-manager-instance).
* Identify virtual networks you want to use in the hub-and-spokes configuration or create new [virtual networks](../virtual-network/quick-create-powershell.md). * Version `5.3.0` of `Az.Network` is required to access the required cmdlets for Azure Virtual Network Manager. * If you're running PowerShell locally, you need to run `Connect-AzAccount` to create a connection with Azure.
virtual-network-manager How To Create Hub And Spoke https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/how-to-create-hub-and-spoke.md
In this article, you learn how to create a hub and spoke network topology with A
## Prerequisites * Read about [Hub-and-spoke](concept-connectivity-configuration.md#hub-and-spoke-topology) network topology.
-* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-portal.md#create-virtual-network-manager).
+* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-portal.md#create-a-virtual-network-manager-instance).
* Identify virtual networks you want to use in the hub-and-spokes configuration or create new [virtual networks](../virtual-network/quick-create-portal.md). ## <a name="group"></a> Create a network group
virtual-network-manager How To Create Mesh Network Powershell https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/how-to-create-mesh-network-powershell.md
In this article, you'll learn how to create a mesh network topology with Azure V
## Prerequisites * Read about [mesh](concept-connectivity-configuration.md#mesh-network-topology) network topology.
-* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-powershell.md#create-virtual-network-manager).
+* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-powershell.md#create-a-virtual-network-manager-instance).
* Identify virtual networks you want to use in the mesh configuration or create new [virtual networks](../virtual-network/quick-create-powershell.md). * Version `5.3.0` of `Az.Network` is required to access the required cmdlets for Azure Virtual Network Manager. * If you're running PowerShell locally, you need to run `Connect-AzAccount` to create a connection with Azure.
virtual-network-manager How To Create Mesh Network https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/how-to-create-mesh-network.md
In this article, you learn how to create a mesh network topology using Azure Vir
## Prerequisites * Read about [mesh](concept-connectivity-configuration.md#mesh-network-topology) network topology.
-* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-portal.md#create-virtual-network-manager).
+* Created a [Azure Virtual Network Manager instance](create-virtual-network-manager-portal.md#create-a-virtual-network-manager-instance).
* Identify virtual networks you want to use in the mesh configuration or create new [virtual networks](../virtual-network/quick-create-portal.md). ## <a name="group"></a> Create a network group
virtual-network-manager Resource Manager Template Samples https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/virtual-network-manager/resource-manager-template-samples.md
# Azure Resource Manager templates for Azure Virtual Network Manager
-The following table includes links to Azure Resource Manager template samples for Azure Virtual Network Manager. You can deploy templates using the Azure portal, Azure CLI, or Azure PowerShell.
-
- You can deploy templates using the Azure [portal](../azure-resource-manager/templates/deploy-portal.md?toc=%2fazure%2fvirtual-network%2ftoc.json), Azure [CLI](../azure-resource-manager/templates/deploy-cli.md?toc=%2fazure%2fvirtual-network%2ftoc.json), or Azure [PowerShell](../azure-resource-manager/templates/deploy-powershell.md?toc=%2fazure%2fvirtual-network%2ftoc.json).
+The following table includes links to Azure Resource Manager template samples for Azure Virtual Network Manager. You can deploy templates using the Azure [portal](../azure-resource-manager/templates/deploy-portal.md?toc=%2fazure%2fvirtual-network%2ftoc.json), Azure [CLI](../azure-resource-manager/templates/deploy-cli.md?toc=%2fazure%2fvirtual-network%2ftoc.json), or Azure [PowerShell](../azure-resource-manager/templates/deploy-powershell.md?toc=%2fazure%2fvirtual-network%2ftoc.json).
To learn how to author your own templates, see [Create your first template](../azure-resource-manager/templates/quickstart-create-templates-use-the-portal.md?toc=%2fazure%2fvirtual-network%2ftoc.json) and [Understand the structure and syntax of Azure Resource Manager templates](../azure-resource-manager/templates/syntax.md?toc=%2fazure%2fvirtual-network%2ftoc.json). For the JSON syntax and properties to use in templates, see [Microsoft.Network resource types](/azure/templates/microsoft.network/allversions).
+> [!IMPORTANT]
+> In cases where a template is deploying connectivity or security configurations, the template requires a custom deployment script to deploy the configuration. The script is located at the end of the ARM template, and it uses the `Microsoft.Resources/deploymentScripts` resource type. For more information on deployment scripts, review [Use deployment scripts in ARM templates](../azure-resource-manager/templates/deployment-script-template.md).
+
+## Samples
| Example | Description | |-- | -- | | [Hub-spoke network topology in Azure](/azure/architecture/reference-architectures/hybrid-networking/hub-spoke?tabs=portal#use-virtual-network-manager-connected-groups) | Creates a hub-spoke network pattern with customer-managed hub infrastructure components. |
web-application-firewall Application Gateway Waf Configuration https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/web-application-firewall/ag/application-gateway-waf-configuration.md
You can specify an exact request header, body, cookie, or query string attribute
- **Contains**: This operator matches all request fields that contain the specified selector value. - **Equals any**: This operator matches all request fields. * will be the selector value.
-When processing exclusions, the WAF will perform a case sensitive match for all fields other than request header keys. Depending on your application, the names, and values, of your headers, cookies and query args can be case sensitive or insensitive. Regular expressions aren't allowed as selectors.
+When processing exclusions, any WAF engine running CRS 3.2 and above will perform a case sensitive match for all fields other than request headers. Depending on your application, the names, and values, of your headers, cookies and query args can be case sensitive or insensitive. If your WAF engine is running CRS 3.1 and below, all fields are case insensitive. Regardless of which CRS version you are running regular expressions aren't allowed as selectors and XML request bodies are not supported.
> [!NOTE] > For more information and troubleshooting help, see [WAF troubleshooting](web-application-firewall-troubleshoot.md).
web-application-firewall Cdn Overview https://github.com/MicrosoftDocs/azure-docs/commits/main/articles/web-application-firewall/cdn/cdn-overview.md
You can choose one of the following actions when a request matches a rule's cond
A WAF policy can consist of two types of security rules: -- *custom rules*: rules you create yourself -- *managed rule sets*: Azure managed pre-configured set of rules
+- *custom rules*: rules that you can create yourself.
+- *managed rule sets*: Azure managed pre-configured set of rules that you can enable.
### Custom rules