Skip to content

Commit f43526c

Browse files
authored
Merge pull request #210411 from cherylmc/bgp2
New ps article
2 parents ce6ca94 + 7014064 commit f43526c

File tree

3 files changed

+99
-6
lines changed

3 files changed

+99
-6
lines changed

articles/virtual-wan/TOC.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,11 @@
228228
- name: Azure PowerShell
229229
href: virtual-wan-route-table-nva.md
230230
- name: Configure BGP peering to an NVA
231-
href: create-bgp-peering-hub-portal.md
231+
items:
232+
- name: Azure portal
233+
href: create-bgp-peering-hub-portal.md
234+
- name: Azure PowerShell
235+
href: create-bgp-peering-hub-powershell.md
232236
- name: Security
233237
items:
234238
- name: Install Azure Firewall in a hub

articles/virtual-wan/create-bgp-peering-hub-portal.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ description: Learn how to create a BGP peering with Virtual WAN hub router.
55
author: cherylmc
66
ms.service: virtual-wan
77
ms.topic: conceptual
8-
ms.date: 08/24/2022
8+
ms.date: 09/06/2022
99
ms.author: cherylmc
1010

1111
---
1212
# Configure BGP peering to an NVA - Azure portal
1313

14-
This article helps you configure an Azure Virtual WAN hub router to peer with a Network Virtual Appliance (NVA) in your virtual network using BGP Peering via the Azure portal. The virtual hub router learns routes from the NVA in a spoke VNet that is connected to a virtual WAN hub. The virtual hub router also advertises the virtual network routes to the NVA. For more information, see [Scenario: BGP peering with a virtual hub](scenario-bgp-peering-hub.md).
14+
This article helps you configure an Azure Virtual WAN hub router to peer with a Network Virtual Appliance (NVA) in your virtual network using BGP Peering using the Azure portal. The virtual hub router learns routes from the NVA in a spoke VNet that is connected to a virtual WAN hub. The virtual hub router also advertises the virtual network routes to the NVA. For more information, see [Scenario: BGP peering with a virtual hub](scenario-bgp-peering-hub.md). You can also create this configuration using [Azure PowerShell](create-bgp-peering-hub-powershell.md).
1515

1616
:::image type="content" source="./media/create-bgp-peering-hub-portal/diagram.png" alt-text="Diagram of configuration.":::
1717

@@ -21,19 +21,19 @@ Verify that you've met the following criteria before beginning your configuratio
2121

2222
[!INCLUDE [Before you begin](../../includes/virtual-wan-before-include.md)]
2323

24-
## <a name="openvwan"></a>Create a virtual WAN
24+
## Create a virtual WAN
2525

2626
[!INCLUDE [Create a virtual WAN](../../includes/virtual-wan-create-vwan-include.md)]
2727

28-
## <a name="hub"></a>Create a hub
28+
## Create a hub
2929

3030
A hub is a virtual network that can contain gateways for site-to-site, ExpressRoute, or point-to-site functionality. Once the hub is created, you'll be charged for the hub, even if you don't attach any sites.
3131

3232
[!INCLUDE [Create a hub](../../includes/virtual-wan-hub-basics.md)]
3333

3434
Once you have the settings configured, click **Review + Create** to validate, then click **Create**. The hub will begin provisioning. After the hub is created, go to the hub's **Overview** page. When provisioning is completed, the **Routing status** is **Provisioned**.
3535

36-
## <a name="vnet"></a>Connect the VNet to the hub
36+
## Connect the VNet to the hub
3737

3838
After your hub router status is provisioned, create a connection between your hub and VNet.
3939

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
---
2+
title: 'Configure BGP peering to an NVA: PowerShell'
3+
titleSuffix: Azure Virtual WAN
4+
description: Learn how to create a BGP peering with Virtual WAN hub router using Azure PowerShell.
5+
author: cherylmc
6+
ms.service: virtual-wan
7+
ms.topic: conceptual
8+
ms.date: 09/08/2022
9+
ms.author: cherylmc
10+
11+
---
12+
# Configure BGP peering to an NVA - PowerShell
13+
14+
This article helps you configure an Azure Virtual WAN hub router to peer with a Network Virtual Appliance (NVA) in your virtual network using BGP Peering using Azure PowerShell. The virtual hub router learns routes from the NVA in a spoke VNet that is connected to a virtual WAN hub. The virtual hub router also advertises the virtual network routes to the NVA. For more information, see [Scenario: BGP peering with a virtual hub](scenario-bgp-peering-hub.md). You can also create this configuration using the [Azure portal](create-bgp-peering-hub-portal.md).
15+
16+
:::image type="content" source="./media/create-bgp-peering-hub-portal/diagram.png" alt-text="Diagram of configuration.":::
17+
18+
## Prerequisites
19+
20+
Verify that you've met the following criteria before beginning your configuration:
21+
22+
[!INCLUDE [Before you begin](../../includes/virtual-wan-before-include.md)]
23+
24+
### Azure PowerShell
25+
26+
[!INCLUDE [PowerShell](../../includes/vpn-gateway-cloud-shell-powershell-about.md)]
27+
28+
#### <a name="signin"></a>Sign in
29+
30+
[!INCLUDE [Sign in](../../includes/vpn-gateway-cloud-shell-ps-login.md)]
31+
32+
## Create a virtual WAN
33+
34+
```azurepowershell-interactive
35+
$virtualWan = New-AzVirtualWan -ResourceGroupName "testRG" -Name "myVirtualWAN" -Location "West US"
36+
```
37+
38+
## Create a virtual hub
39+
40+
A hub is a virtual network that can contain gateways for site-to-site, ExpressRoute, or point-to-site functionality. Once the hub is created, you'll be charged for the hub, even if you don't attach any sites.
41+
42+
```azurepowershell-interactive
43+
$virtualHub = New-AzVirtualHub -VirtualWan $virtualWan -ResourceGroupName "testRG" -Name "westushub" -AddressPrefix "10.0.0.1/24"
44+
```
45+
46+
## Connect the VNet to the hub
47+
48+
Create a connection between your hub and VNet.
49+
50+
```azurepowershell-interactive
51+
$remote = Get-AzVirtualNetwork -Name "[vnet name]" -ResourceGroupName "[resource group name]"
52+
$hubVnetConnection = New-AzVirtualHubVnetConnection -ResourceGroupName "[parent resource group name]" -VirtualHubName "[virtual hub name]" -Name "[name of connection]" -RemoteVirtualNetwork $remote
53+
```
54+
55+
## Configure a BGP peer
56+
57+
Configure BGP peer for the $hubVnetConnection you created.
58+
59+
```azurepowershell-interactive
60+
New-AzVirtualHubBgpConnection -ResourceGroupName "testRG" -VirtualHubName "westushub" -PeerIp 192.168.1.5 -PeerAsn 20000 -Name "testBgpConnection" -VirtualHubVnetConnection $hubVnetConnection
61+
```
62+
63+
Or, you can configure BGP for an existing virtual hub VNet connection.
64+
65+
```azurepowershell-interactive
66+
$hubVnetConnection = Get-AzVirtualHubVnetConnection -ResourceGroupName "[resource group name]" -VirtualHubName "[virtual hub name]" -Name "[name of connection]"
67+
68+
New-AzVirtualHubBgpConnection -ResourceGroupName "[resource group name]" -VirtualHubName "westushub" -PeerIp 192.168.1.5 -PeerAsn 20000 -Name "testBgpConnection" -VirtualHubVnetConnection $hubVnetConnection
69+
```
70+
71+
## Modify a BGP peer
72+
73+
Update an existing hub BGP peer connection.
74+
75+
```azurepowershell-interactive
76+
Update-AzVirtualHubBgpConnection -ResourceGroupName "[resource group name]" -VirtualHubName "westushub" -PeerIp 192.168.1.6 -PeerAsn 20000 -Name "testBgpConnection" -VirtualHubVnetConnection $hubVnetConnection
77+
```
78+
79+
## Delete a BGP peer
80+
81+
Remove an existing hub BGP connection.
82+
83+
```azurepowershell-interactive
84+
Remove-AzVirtualHubBgpConnection -ResourceGroupName "[resource group name]" -VirtualHubName "westushub" -Name "testBgpConnection"
85+
```
86+
87+
## Next steps
88+
89+
For more information about BGP scenarios, see [Scenario: BGP peering with a virtual hub](scenario-bgp-peering-hub.md).

0 commit comments

Comments
 (0)