Skip to content

Commit b88b59c

Browse files
Merge pull request #260169 from mbender-ms/lb-vnet-create-T189791
load balancer - Update for VNet Create - tutorial-load-balancer-standard-public-zonal-portal.md
2 parents 3bda5e8 + e9bdfc8 commit b88b59c

9 files changed

+217
-312
lines changed

articles/load-balancer/tutorial-load-balancer-standard-public-zonal-portal.md

Lines changed: 7 additions & 304 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: mbender-ms
77
# Customer intent: As an IT administrator, I want to create a load balancer that load balances incoming internet traffic to virtual machines within a specific zone in a region.
88
ms.service: load-balancer
99
ms.topic: tutorial
10-
ms.date: 12/05/2022
10+
ms.date: 12/04/2023
1111
ms.author: mbender
1212
ms.custom: template-tutorial, seodec18
1313
---
@@ -36,316 +36,19 @@ For more information about availability zones and a standard load balancer, see
3636

3737
Sign in to the [Azure portal](https://portal.azure.com).
3838

39-
## Create the virtual network
39+
[!INCLUDE [load-balancer-create-bastion](../../includes/load-balancer-create-bastion.md)]
4040

41-
In this section, you'll create a virtual network and subnet.
41+
[!INCLUDE [load-balancer-nat-gateway-subnet-add](../../includes/load-balancer-nat-gateway-subnet-add.md)]
4242

43-
1. In the search box at the top of the portal, enter **Virtual network**. Select **Virtual Networks** in the search results.
43+
[!INCLUDE [load-balancer-public-create](../../includes/load-balancer-public-create.md)]
4444

45-
2. In **Virtual networks**, select **+ Create**.
46-
47-
3. In **Create virtual network**, enter or select this information in the **Basics** tab:
48-
49-
| **Setting** | **Value** |
50-
|------------------|-----------------------------------------------------------------|
51-
| **Project Details** | |
52-
| Subscription | Select your Azure subscription |
53-
| Resource Group | Select **Create new**. </br> In **Name** enter **CreateZonalLBTutorial-rg**. </br> Select **OK**. |
54-
| **Instance details** | |
55-
| Name | Enter **myVNet** |
56-
| Region | Select **(Europe) West Europe** |
57-
58-
4. Select the **IP Addresses** tab or select the **Next: IP Addresses** button at the bottom of the page.
59-
60-
5. In the **IP Addresses** tab, enter this information:
61-
62-
| Setting | Value |
63-
|--------------------|----------------------------|
64-
| IPv4 address space | Enter **10.1.0.0/16** |
65-
66-
6. Select **+ Add subnet**.
67-
68-
7. On the **Add subnet** page, enter this information:
69-
70-
| Setting | Value |
71-
|--------------------|----------------------------|
72-
| Subnet name | Enter **myBackendSubnet** |
73-
| Subnet address range | Enter **10.1.0.0/24** |
74-
75-
8. Select **Add**.
76-
77-
9. Select the **Security** tab.
78-
79-
10. Under **BastionHost**, select **Enable**. Enter this information:
80-
81-
| Setting | Value |
82-
|--------------------|----------------------------|
83-
| Bastion name | Enter **myBastionHost** |
84-
| AzureBastionSubnet address space | Enter **10.1.1.0/26** |
85-
| Public IP Address | Select **Create new**. </br> For **Name**, enter **myBastionIP**. </br> Select **OK**. |
86-
87-
11. Select the **Review + create** tab or select the **Review + create** button.
88-
89-
12. Select **Create**.
90-
91-
> [!IMPORTANT]
92-
93-
> [!INCLUDE [Pricing](../../includes/bastion-pricing.md)]
94-
95-
>
96-
97-
## Create NAT gateway
98-
99-
In this section, you'll create a NAT gateway for outbound internet access for resources in the virtual network.
100-
101-
1. In the search box at the top of the portal, enter **NAT gateway**. Select **NAT gateways** in the search results.
102-
103-
2. In **NAT gateways**, select **+ Create**.
104-
105-
3. In **Create network address translation (NAT) gateway**, enter or select the following information:
106-
107-
| Setting | Value |
108-
| ------- | ----- |
109-
| **Project details** | |
110-
| Subscription | Select your subscription. |
111-
| Resource group | Select **CreateZonalLBTutorial-rg**. |
112-
| **Instance details** | |
113-
| NAT gateway name | Enter **myNATgateway**. |
114-
| Availability zone | Select **1**. |
115-
| Idle timeout (minutes) | Enter **15**. |
116-
117-
4. Select the **Outbound IP** tab or select the **Next: Outbound IP** button at the bottom of the page.
118-
119-
5. In **Outbound IP**, for **Public IP addresses**, select **Create a new public IP address**.
120-
121-
6. On the **Add a public IP address** page, for **Name**, enter **myNATGatewayIP**.
122-
123-
7. Select **OK**.
124-
125-
8. Select the **Subnet** tab or select the **Next: Subnet** button at the bottom of the page.
126-
127-
9. On the **Subnet** page, for **Virtual network**, select **myVNet** from the dropdown.
128-
129-
10. For **Subnet name**, select **myBackendSubnet**.
130-
131-
11. Select the **Review + create** button at the bottom of the page, or select the **Review + create** tab.
132-
133-
12. Select **Create**.
134-
135-
## Create load balancer
136-
137-
In this section, you'll create a zonal load balancer that load balances virtual machines.
138-
139-
During the creation of the load balancer, you'll configure:
140-
141-
* Frontend IP address
142-
* Backend pool
143-
* Inbound load-balancing rules
144-
145-
1. In the search box at the top of the portal, enter **Load balancer**. Select **Load balancers** in the search results.
146-
147-
2. In the **Load balancer** page, select **Create**.
148-
149-
3. In the **Basics** tab of the **Create load balancer** page, enter or select the following information:
150-
151-
| Setting | Value |
152-
| --- | --- |
153-
| **Project details** | |
154-
| Subscription | Select your subscription. |
155-
| Resource group | Select **CreateZonalLBTutorial-rg**. |
156-
| **Instance details** | |
157-
| Name | Enter **myLoadBalancer** |
158-
| Region | Select **(Europe) West Europe**. |
159-
| SKU | Leave the default **Standard**. |
160-
| Type | Select **Public**. |
161-
| Tier | Leave the default **Regional**. |
162-
163-
4. Select **Next: Frontend IP configuration** at the bottom of the page.
164-
165-
5. In **Frontend IP configuration**, select **+ Add a frontend IP configuration**.
166-
167-
6. For **Name**, type **LoadBalancerFrontend**.
168-
169-
7. For **IP version**, select either **IPv4** or **IPv6**.
170-
171-
> [!NOTE]
172-
> IPv6 isn't currently supported with Routing Preference or Cross-region load-balancing (Global Tier).
173-
174-
8. For **IP type**, select **IP address**.
175-
176-
> [!NOTE]
177-
> For more information on IP prefixes, see [Azure Public IP address prefix](../virtual-network/ip-services/public-ip-address-prefix.md).
178-
179-
9. For **Public IP address**, select **Create new**.
180-
181-
10. On the **Add a public IP address** page, for **Name**, enter **myPublicIP**.
182-
183-
11. For **Availability zone**, select **1** from the dropdown, then click **OK** to close the **Add a public IP address** page.
184-
185-
> [!NOTE]
186-
> 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).
187-
188-
12. If you see **Routing preference** settings, leave the default of **Microsoft Network** for **Routing preference**.
189-
190-
13. Select **OK**.
191-
192-
14. Select **Add**.
193-
194-
15. At the bottom of the page, select **Next: Backend pools**.
195-
196-
16. On the **Backend pools** page, select **+ Add a backend pool**.
197-
198-
17. On the **Add backend pool** page, for **Name**, type **myBackendPool**.
199-
200-
18. For **Virtual network**, select **myVNet** from the dropdown.
201-
202-
19. For **Backend Pool Configuration**, select either **NIC** or **IP Address**.
203-
204-
20. Select **Save**.
205-
206-
21. At the bottom of the page, select the **Next: Inbound rules** button.
207-
208-
22. On the **Inbound rules** page, for **Load balancing rule**, select **+ Add a load balancing rule**.
209-
210-
23. On the **Add load balancing rule** page, enter or select the following information:
211-
212-
| Setting | Value |
213-
| ------- | ----- |
214-
| Name | Enter **myHTTPRule** |
215-
| IP Version | Select **IPv4** or **IPv6** depending on your requirements. |
216-
| Frontend IP address | Select **LoadBalancerFrontend**. |
217-
| Backend pool | Select **myBackendPool**. |
218-
| Protocol | Select **TCP**. |
219-
| Port | Enter **80**. |
220-
| Backend port | Enter **80**. |
221-
| 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**. |
222-
| Session persistence | Select **None**. |
223-
| Idle timeout (minutes) | Enter or select **15**. |
224-
| TCP reset | Select **Enabled**. |
225-
| Floating IP | Select **Disabled**. |
226-
| Outbound source network address translation (SNAT) | Leave the default of **(Recommended) Use outbound rules to provide backend pool members access to the internet.** |
227-
228-
24. Select **Add**.
229-
230-
25. At the bottom of the page, select the **Review + create** button.
231-
232-
26. Select **Create**.
233-
234-
> [!NOTE]
235-
> In this example we created a NAT gateway to provide outbound Internet access. The outbound rules tab in the configuration is bypassed as it's optional isn't needed with the NAT gateway. For more information on Azure NAT gateway, see [What is Azure Virtual Network NAT?](../virtual-network/nat-gateway/nat-overview.md)
236-
> For more information about outbound connections in Azure, see [Source Network Address Translation (SNAT) for outbound connections](../load-balancer/load-balancer-outbound-connections.md)
237-
238-
## Create virtual machines
239-
240-
In this section, you'll create three VMs (**myVM1**, **myVM2**, and **myVM3**) in one zone (**Zone 1**).
241-
242-
These VMs are added to the backend pool of the load balancer that was created earlier.
243-
244-
1. On the upper-left side of the portal, select **Create a resource** > **Compute** > **Virtual machine**.
245-
246-
2. In **Create a virtual machine**, type or select the values in the **Basics** tab:
247-
248-
| Setting | Value |
249-
|-----------------------|----------------------------------|
250-
| **Project Details** | |
251-
| Subscription | Select your Azure subscription |
252-
| Resource Group | Select **CreateZonalLBTutorial-rg** |
253-
| **Instance details** | |
254-
| Virtual machine name | Enter **myVM1** |
255-
| Region | Select **(Europe) West Europe** |
256-
| Availability Options | Select **Availability zone** |
257-
| Availability zone | Select **1** |
258-
| Image | Select **Windows Server 2019 Datacenter - Gen1** |
259-
| Azure Spot instance | Leave the default of unchecked. |
260-
| Size | Choose VM size or take default setting |
261-
| **Administrator account** | |
262-
| Username | Enter a username |
263-
| Password | Enter a password |
264-
| Confirm password | Reenter password |
265-
| **Inbound port rules** | |
266-
| Public inbound ports | Select **None** |
267-
268-
3. Select the **Networking** tab, or select **Next: Disks**, then **Next: Networking**.
269-
270-
4. In the Networking tab, select or enter:
271-
272-
| Setting | Value |
273-
|-|-|
274-
| **Network interface** | |
275-
| Virtual network | **myVNet** |
276-
| Subnet | **myBackendSubnet** |
277-
| Public IP | Select **None**. |
278-
| NIC network security group | Select **Advanced**|
279-
| 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 **Service**, select **HTTP**. </br> Under **Priority**, enter **100**. </br> In **Name**, enter **myNSGRule** </br> Select **Add** </br> Select **OK** |
280-
| **Load balancing** |
281-
| Place this virtual machine behind an existing load-balancing solution? | Select the check box. |
282-
| **Load balancing settings** |
283-
| Load-balancing options | Select **Azure load balancing** |
284-
| Select a load balancer | Select **myLoadBalancer** |
285-
| Select a backend pool | Select **myBackendPool** |
286-
287-
7. Select **Review + create**.
288-
289-
8. Review the settings, and then select **Create**.
290-
291-
9. Follow the steps 1 to 8 to create two more VMs with the following values and all the other settings the same as **myVM1**:
292-
293-
| Setting | VM 2| VM 3|
294-
| ------- | ----- |---|
295-
| Name | **myVM2** |**myVM3**|
296-
| Availability zone | **1** |**1**|
297-
| Network security group | Select the existing **myNSG**| Select the existing **myNSG**|
45+
[!INCLUDE [load-balancer-create-virtual-machine-zonal](../../includes/load-balancer-create-virtual-machine-zonal.md)]
29846

29947
[!INCLUDE [ephemeral-ip-note.md](../../includes/ephemeral-ip-note.md)]
30048

301-
## Install IIS
302-
303-
1. Select **All services** in the left-hand menu, select **All resources**, and then from the resources list, select **myVM1** that is located in the **CreateZonalLBTutorial-rg** resource group.
304-
305-
2. On the **Overview** page, select **Connect**, then **Bastion**.
306-
307-
3. Select **Use Bastion**.
308-
309-
4. Enter the username and password entered during VM creation.
310-
311-
5. Select **Connect**.
312-
313-
6. On the server desktop, navigate to **Windows Administrative Tools** > **Windows PowerShell**.
314-
315-
7. In the PowerShell Window, run the following commands to:
316-
317-
* Install the IIS server
318-
* Remove the default iisstart.htm file
319-
* Add a new iisstart.htm file that displays the name of the VM:
320-
321-
```powershell
322-
# Install IIS server role
323-
Install-WindowsFeature -name Web-Server -IncludeManagementTools
324-
325-
# Remove default htm file
326-
Remove-Item C:\inetpub\wwwroot\iisstart.htm
327-
328-
# Add a new htm file that displays server name
329-
Add-Content -Path "C:\inetpub\wwwroot\iisstart.htm" -Value $("Hello World from " + $env:computername)
330-
```
331-
332-
8. Close the Bastion session with **myVM1**.
333-
334-
9. Repeat steps 1 to 8 to install IIS and the updated iisstart.htm file on **myVM2** and **myVM3**.
335-
336-
## Test the load balancer
337-
338-
1. In the search box at the top of the page, enter **Load balancer**. Select **Load balancers** in the search results.
339-
340-
2. Click the load balancer you created, **myLoadBalancer**. On the **Frontend IP configuration** page for your load balancer, locate the public **IP address**.
341-
342-
3. Copy the public IP address, and then paste it into the address bar of your browser. The custom VM page of the IIS Web server is displayed in the browser.
343-
344-
:::image type="content" source="./media/tutorial-load-balancer-standard-zonal-portal/load-balancer-test.png" alt-text="Screenshot of load balancer test":::
345-
346-
## Clean up resources
49+
[!INCLUDE [load-balancer-install-iis](../../includes/load-balancer-install-iis.md)]
34750

348-
When no longer needed, delete the resource group, load balancer, and all related resources. To do so, select the resource group **CreateZonalLBTutorial-rg** that contains the resources and then select **Delete**.
51+
[!INCLUDE [load-balancer-cleanup-resources](../../includes/load-balancer-cleanup-resources.md)]
34952

35053
## Next steps
35154

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
---
2+
title: include file
3+
description: include file
4+
services: load-balancer
5+
author: mbender-ms
6+
ms.service: load-balancer
7+
ms.topic: include
8+
ms.date: 12/04/2023
9+
ms.author: mbender
10+
ms.custom: include file
11+
---
12+
13+
## Clean up resources
14+
15+
When no longer needed, delete the resource group, load balancer, and all related resources. To do so, select the resource group **load-balancer-rg** that contains the resources and then select **Delete**.

includes/load-balancer-create-2-virtual-machines.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
---
22
title: include file
33
description: include file
4-
services: virtual-network
4+
services: load-balancer
55
author: mbender-ms
6-
ms.service: virtual-network
6+
ms.service: load-balancer
77
ms.topic: include
8-
ms.date: 10/19/2023
8+
ms.date: 12/04/2023
99
ms.author: mbender
1010
ms.custom: include file
1111
---

0 commit comments

Comments
 (0)