Skip to content

Commit 4929d4f

Browse files
committed
Updates
1 parent c9fd9e1 commit 4929d4f

File tree

1 file changed

+39
-39
lines changed

1 file changed

+39
-39
lines changed

articles/load-balancer/cross-subscription-how-to-global-backend.md

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ services: load-balancer
66
author: mbender-ms
77
ms.service: azure-load-balancer
88
ms.topic: how-to
9-
ms.date: 02/20/2024
9+
ms.date: 02/20/2025
1010
ms.author: mbender
1111
ms.custom: devx-track-azurepowershell
1212
---
@@ -39,7 +39,7 @@ If you choose to install and use PowerShell locally, this article requires the A
3939
- Two Azure subscriptions. One subscription for the virtual network (**Azure Subscription A**) and another subscription for the load balancer(**Azure Subscription B**).
4040
- An Azure account with active subscriptions. [Create an account for free](https://azure.microsoft.com/free/)
4141
- A global public IP address deployed in **Azure Subscription A** located in a [Global load balancer home region](cross-subscription-how-to-global-backend.md).
42-
- A regional load balancer deployed in **Azure Subscription A**.
42+
- A regional load balancer deployed in **Azure Subscription A**. For this example, the load balancer is called **load-balancer-regional** in a resource group called **resource-group-a**.
4343

4444
[!INCLUDE [azure-cli-prepare-your-environment.md](~/reusable-content/azure-cli/azure-cli-prepare-your-environment-no-header.md)]
4545

@@ -64,12 +64,12 @@ With Azure PowerShell, you sign into Azure with [`Connect-AzAccount`](/powershel
6464
Connect-AzAccount
6565
6666
# Set the subscription context to Azure Subscription A
67-
Set-AzContext -Subscription 'd9f0f529-83ab-4840-9c8b-76db5d68517f'
67+
Set-AzContext -Subscription '<Subscription ID of Subscription A>'
6868
6969
# Get the Virtual Network information with Get-AzVirtualNetwork
7070
$rlb= @{
71-
Name = 'load-balancer-reg'
72-
ResourceGroupName = 'myResourceGroup'
71+
Name = 'load-balancer-regional'
72+
ResourceGroupName = 'resource-group-a'
7373
}
7474
$rlbinfo = Get-AzLoadBalancer @rlb
7575
$rlbfe = Get-AzLoadBalancerFrontendIpConfig @rlbinfo
@@ -86,7 +86,7 @@ With Azure CLI, you'll sign into Azure with [az login](/cli/azure/reference-inde
8686
8787
# Sign in to Azure CLI and change subscription to Azure Subscription B
8888
Az login
89-
Az account set –subscription d9f0f529-83ab-4840-9c8b-76db5d68517f
89+
Az account set –subscription '<Subscription ID of Subscription B>'
9090
```
9191

9292
---
@@ -106,8 +106,8 @@ Set-AzContext -Subscription '<Azure Subscription B>'
106106
107107
# Create a resource group
108108
$rg = @{
109-
Name = 'myResourceGroupLB'
110-
Location = 'westus'
109+
Name = 'resource-group-b'
110+
Location = '<Region for resource group in subscription B>'
111111
}
112112
New-AzResourceGroup @rg
113113
```
@@ -120,7 +120,7 @@ With Azure CLI, you switch the subscription context with [`az account set`](/cli
120120

121121
```azurecli
122122
# Create a resource group in Azure Subscription B
123-
az group create --name 'myResourceGroupLB' --location westus
123+
az group create --name '<Region for resource group in subscription B>' --location $'<Region for resource group in subscription B>'$
124124
```
125125

126126
> [!NOTE]
@@ -130,8 +130,8 @@ az group create --name 'myResourceGroupLB' --location westus
130130

131131
## Create a global load balancer
132132

133-
In this section, you create the resources needed for the cross-region load balancer.
134-
A global standard sku public IP is used for the frontend of the cross-region load balancer.
133+
In this section, you create the resources needed for the global load balancer.
134+
A global standard sku public IP is used for the frontend of the global load balancer.
135135

136136
# [Azure PowerShell](#tab/azurepowershell)
137137

@@ -146,8 +146,8 @@ With Azure PowerShell, you:
146146
```azurepowershell
147147
# Create global IP address for load balancer
148148
$ip = @{
149-
Name = 'myPublicIP-CR'
150-
ResourceGroupName = ‘ Resource Group B’
149+
Name = 'public-IP-global'
150+
ResourceGroupName = 'resource-group-b'
151151
Location = 'eastus2'
152152
Sku = 'Standard'
153153
Tier = 'Global'
@@ -157,20 +157,20 @@ $publicIP = New-AzPublicIpAddress @ip
157157
158158
# Create frontend configuration
159159
$fe = @{
160-
Name = 'myFrontEnd-CR'
160+
Name = 'front-end-config-global'
161161
PublicIpAddress = $publicIP
162162
}
163163
$feip = New-AzLoadBalancerFrontendIpConfig @fe
164164
165165
# Create backend address pool
166166
$be = @{
167-
Name = 'myBackEndPool-CR'
167+
Name = 'backend-pool-global'
168168
}
169169
$bepool = New-AzLoadBalancerBackendAddressPoolConfig @be
170170
171171
# Create the load balancer rule
172172
$rul = @{
173-
Name = 'myHTTPRule-CR'
173+
Name = 'HTTP-rule-global'
174174
Protocol = 'tcp'
175175
FrontendPort = '80'
176176
BackendPort = '80'
@@ -179,10 +179,10 @@ $rul = @{
179179
}
180180
$rule = New-AzLoadBalancerRuleConfig @rul
181181
182-
# Create cross-region load balancer resource
182+
# Create global load balancer resource
183183
$lbp = @{
184-
ResourceGroupName = ‘ Resource Group B’
185-
Name = 'myLoadBalancer-CR'
184+
ResourceGroupName = 'resource-group-b'
185+
Name = 'load-balancer-global'
186186
Location = ‘eastus2’
187187
Sku = 'Standard'
188188
Tier = 'Global'
@@ -197,45 +197,45 @@ $lb = New-AzLoadBalancer @lbp
197197

198198
With Azure CLI, you:
199199

200-
- Create a cross-region load balancer with [`az network cross-region-lb create`](/cli/azure/network/cross-region-lb#az-network-cross-region-lb-create).
200+
- Create a global load balancer with [`az network cross-region-lb create`](/cli/azure/network/cross-region-lb#az-network-cross-region-lb-create).
201201
- Create a load balancer rule with [`az network cross-region-lb rule create`](/cli/azure/network/cross-region-lb#az-network-cross-region-lb-rule-create).
202202

203203
```azurecli
204204
205-
# Create cross-region load balancer
206-
az network cross-region-lb create --name myLoadBalancer-CR --resource-group myResourceGroupLB-CR --frontend-ip-name myFrontEnd-CR --backend-pool-name myBackEndPool-CR
205+
# Create global load balancer
206+
az network cross-region-lb create --name load-balancer-global --resource-group resource-group-b --frontend-ip-name front-end-config-global --backend-pool-name backend-pool-global
207207
208208
# create a load balancer rule
209-
az network cross-region-lb rule create --backend-port 80 --frontend-port 80 --lb-name myLoadBalancer-CR --name myHTTPRule-CR --protocol tcp --resource-group myResourceGroupLB-CR --backend-pool-name myBackEndPool-CR --frontend-ip-name myFrontEnd-CR
209+
az network cross-region-lb rule create --backend-port 80 --frontend-port 80 --lb-name load-balancer-global --name HTTP-rule-global --protocol tcp --resource-group resource-group-b --backend-pool-name backend-pool-global --frontend-ip-name front-end-config-global
210210
211211
```
212212
---
213213

214-
## Add load balancer frontends to cross-region load balancer
214+
## Add load balancer frontends to global load balancer
215215

216-
In this section, you add a frontend IP configuration to the cross-region load balancer.
216+
In this section, you add a frontend IP configuration to the global load balancer.
217217

218218
# [Azure PowerShell](#tab/azurepowershell)
219219

220220
With Azure PowerShell, you:
221221

222-
- Use [`Set-AzLoadBalancerFrontendIpConfig`](/powershell/module/az.network/set-azloadbalancerfrontendipconfig) to add the regional load balancer frontend to the cross-region backend pool.
222+
- Use [`Set-AzLoadBalancerFrontendIpConfig`](/powershell/module/az.network/set-azloadbalancerfrontendipconfig) to add the regional load balancer frontend to the global backend pool.
223223
- Use [`New-AzLoadBalancerBackendAddressConfig`](/powershell/module/az.network/new-azloadbalancerbackendaddressconfig) to create the backend address pool configuration for the load balancer.
224224

225225
```azurepowershell
226226
227-
## Create the cross-region backend address pool configuration for region 2 ##
228-
$RLB-BAF = @{
229-
Name = 'MyBackendPoolConfig-RLB'
230-
LoadBalancerFrontendIPConfigurationId = $RLBFE.Id
227+
## Create the global backend address pool configuration for region 2 ##
228+
$rlbbaf = @{
229+
Name = 'backend-pool-config-regional'
230+
LoadBalancerFrontendIPConfigurationId = $rlbfe.Id
231231
}
232232
$beaddressconfigRLB = New-AzLoadBalancerBackendAddressConfig @region2ap
233233
234-
## Apply the backend address pool configuration for the cross-region load balancer ##
234+
## Apply the backend address pool configuration for the global load balancer ##
235235
$bepoolcr = @{
236-
ResourceGroupName = ‘ Resource Group B’
237-
LoadBalancerName = 'myLoadBalancer-CR'
238-
Name = 'myBackEndPool-CR'
236+
ResourceGroupName = 'resource-group-b'
237+
LoadBalancerName = 'load-balancer-global'
238+
Name = 'backend-pool-global'
239239
LoadBalancerBackendAddress = $beaddressconfigRLB
240240
}
241241
Set-AzLoadBalancerBackendAddressPool @bepoolcr
@@ -244,16 +244,16 @@ Set-AzLoadBalancerBackendAddressPool @bepoolcr
244244

245245
# [Azure CLI](#tab/azurecli/)
246246

247-
With Azure CLI, you add the frontends you placed in variables in the backend pool of the cross-region load balancer with use [`az network cross-region-lb address-pool`](/cli/azure/network/cross-region-lb#az-network-cross-region-lb-address-pool).
247+
With Azure CLI, you add the frontends you placed in variables in the backend pool of the global load balancer with use [`az network cross-region-lb address-pool`](/cli/azure/network/cross-region-lb#az-network-cross-region-lb-address-pool).
248248

249249
```azurecli
250250
251251
az network cross-region-lb address-pool address add \
252-
--frontend-ip-address ‘/subscriptions/Subscription A/resourceGroups/rg-name/providers/Microsoft.Network/loadBalancers/RLB-name /frontendIPConfigurations/RLB-LB Frontend Name’
253-
--lb-name myLoadBalancer-CR \
252+
--frontend-ip-address ‘/subscriptions/Subscription A/resourceGroups/rg-name/providers/Microsoft.Network/loadBalancers/rlb-name /frontendIPConfigurations/rlb-lb Frontend Name’
253+
--lb-name load-balancer-global \
254254
--name myFrontEnd-R2 \
255-
--pool-name myBackEndPool-CR \
256-
--resource-group myResourceGroupLB-CR
255+
--pool-name backend-pool-global \
256+
--resource-group resource-group-b
257257
```
258258

259259
## Next steps

0 commit comments

Comments
 (0)