You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/virtual-network/how-to-configure-subnet-peering.md
+20-21Lines changed: 20 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,16 +14,15 @@ ms.date: 12/03/2024
14
14
15
15
# How to configure subnet peering - Preview
16
16
17
-
18
17
<!-- descriptive text here. Search engine optimization crawls the first few sentences. You'll want to make this first area something that will help a customer find this article in Google search.-->
19
18
20
-
Subnet peering refers to a method of connecting two Virtual Networks by linking only the subnet address spaces rather than the entire virtual network address spaces. It lets users specify which subnets are supposed to participate in the peering across the local and remote virtual network.
19
+
Subnet peering refers to a method of connecting two Virtual Networks by linking only the subnet address spaces rather than the entire virtual network address spaces. It lets users specify which subnets are supposed to participate in the peering across the local and remote virtual networks.
21
20
22
-
It's an added flexibility built on top of virtual network peering, where users get an option to choose specific subnets that need to be peered across virtual networks. User can select or is prompted to enter the list of subnets across the virtual networks that they want to peer. In contrast, if regular virtual network peering, entire address space/subnets across the virtual networks get peered.
21
+
It's an added flexibility built on top of virtual network peering, where users get an option to choose specific subnets that need to be peered across virtual networks. User can specify/enter the list of subnets across the virtual networks that they want to peer. In contrast, in regular virtual network peering, entire address space/subnets across the virtual networks get peered.
23
22
24
23
> [!IMPORTANT]
25
24
> Subnet peering is currently in public preview.
26
-
> This preview version is provided without a service level agreement, and it isn't recommended for production workloads. Certain features might not be supported or might have constrained capabilities.
25
+
> This preview version is provided without a service level agreement, and it isn't recommended for production workloads. Certain features might not be supported or might have constrained capabilities.
27
26
> For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
28
27
29
28
The following limitations apply during the public preview:
@@ -34,15 +33,15 @@ The following limitations apply during the public preview:
34
33
35
34
## Prerequisites
36
35
37
-
- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
36
+
- An Azure account with an active subscription. [Create an account for free](https://azure.microsoft.com/free/?WT.mc_id=A261C142F).
38
37
39
38
## Configure subnet peering
40
39
41
40
<updatethisforyourfeature.>
42
41
43
42
- The 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.
44
43
45
-
- To access the subnet peering preview feature, you need to register it in your Azure subscription.
44
+
- To access the subnet peering preview feature, you need your Azure subscription to be registered for the feature.
46
45
47
46
-**Note:** The feature is in preview currently, and it's advised that you test the feature on nonproduction workloads. To use it, you would need to allowlist your subscription. Fill this [form](https://forms.office.com/r/99J2fSfd9L) to get your subscription registered. For more information about registering preview features in your subscription, see [Set up preview features in Azure subscription](/azure/azure-resource-manager/management/preview-features).
48
47
@@ -52,22 +51,22 @@ In the existing virtual network peering create process, few new optional paramet
52
51
53
52
A.
54
53
**--peer-complete-vnet**
55
-
This parameter would let user exercise and option to select subnet peering. By default the value for this parameter is set to true, which means entire virtual networks are peered (all address spaces/subnets). To use subnet peering, this parameter needs to be set to false.
54
+
This parameter would let user exercise an option to select subnet peering. By default the value for this parameter is set to true, which means entire virtual networks are peered (all address spaces/subnets). To use subnet peering, this parameter needs to be set to false.
56
55
57
56
Accepted values: 0, 1, f, false, n, no, t, true, y, yes
58
57
Default value: True
59
58
60
59
B.
61
60
**--local-subnet-names**
62
-
This parameter lets user enter local subnet names they want to peer with the remote subnets, in case subnet peering is enabled by setting “peer-complete-vnet’ parameter as 0
61
+
This parameter lets users enter local subnet names they want to peer with the remote subnets when subnet peering is enabled by setting “peer-complete-vnet’ parameter as 0
63
62
64
63
C.
65
64
**--remote-subnet-names**
66
-
This parameter would let user enter remote subnet names they want to peer with the local subnets in case subnet peering is enabled by setting “peer-complete-vnet’ parameter as 0
65
+
This parameter would let users enter remote subnet names they want to peer with the local subnets when subnet peering is enabled by setting “peer-complete-vnet’ parameter as 0
67
66
68
67
D.
69
-
**--enable-only-ipv6**
70
-
This parameter would let user exercise an option to select subnet peering with only IPv6 peering functionality. By default, the value for this parameter is set to false, which means peering would be done over IPv4 addresses by default. If set to true, peering would be done over IPv6 in dual stack subnets
68
+
**--enable-only-ipv6**
69
+
This parameter would let users exercise an option to configure subnet peering over IPv6 address space only (for dual stack subnets). By default, the value for this parameter is set to false, which means peering would be done over IPv4 addresses by default. If set to true, peering would be done over IPv6 in dual stack subnets.
71
70
72
71
Accepted values: 0, 1, f, false, n, no, t, true, y, yes
73
72
@@ -136,9 +135,9 @@ az network vnet peering create --name
136
135
--address-prefix 10.1.2.0/24
137
136
```
138
137
139
-
1. After creating the required subnets, let's say we want to connect only subnet-1 from vnet-1 and subnet-3 from vnet-2, instead of peering the entire vnet. For this, we use the optional parameters described above to achieve this.
138
+
1. After creating the required subnets, let's say we want to connect only subnet-1 from vnet-1 and subnet-3 from vnet-2, instead of peering the entire virtual network. For this, we use the optional parameters described above to achieve this.
140
139
141
-
For this, we run the vitual network peering create command with the optional parameters.
140
+
For this, we run the virtual network peering create command with the optional parameters.
142
141
143
142
```azurecli
144
143
az network vnet peering create -n vnet-1_to_vnet-2
@@ -160,28 +159,28 @@ Refer the figure to understand the checks performed while configuring subnet pee
160
159
:::image type="content" source=".\media\how-to-configure-subnet-peering\subnet-peering.png" alt-text="Diagram that shows subnet peering.":::
161
160
162
161
1. The participating subnets **must be unique** and **must belong to unique address spaces**.
163
-
- For example, in the virtual network A and virtual network C peering (illustrated in the figure by black arrow headed line) virtual network A can't subnet peer over Subnet 1, Subnet 2 and Subnet 3 with any of the subnets in virtual network C as virtual network C, as these subnets of virtual network A belong to 10.1.0.0/16 Address space which is also present in virtual network C.
162
+
- For example, in the virtual network A and virtual network C peering (illustrated in the figure by black arrow headed line) virtual network A can't subnet peer over Subnet 1, Subnet 2 and Subnet 3 with any of the subnets in virtual network C, as these subnets of virtual network A belong to 10.1.0.0/16 Address space which is also present in virtual network C.
164
163
- However, virtual network A’s Subnet 4 (10.0.1.0/24) can subnet peer with Subnet 5 in virtual network C (10.6.1.0/24) as these subnets are unique across the virtual networks and they belong to unique address spaces across virtual networks. Subnet 4 belongs to 10.0.0.0/16 address space in virtual network A and Subnet 5 belongs to 10.6.0.0/16 address space in virtual network C.
165
164
166
-
1. There can be **only one peering link between any two virtual networks**. If you want to add or remove subnets from the peering link, then the same peering link is required to be updated. This also means **multiple exclusive peering between set of subnets are not possible**.<br>
165
+
1. There can be **only one peering link between any two virtual networks**. If you want to add or remove subnets from the peering link, then the same peering link is required to be updated. This also means **multiple exclusive peering between set of subnets are not possible**.<br>
167
166
Also, **a given peering link type cannot be changed**. That means, if there's a virtual network peering between virtual network A and virtual network B, and user wants to change that to subnet peering, the existing virtual network peering link needs to be deleted, and new peering needs to be created with the required parameters for subnet peering and vice versa.
168
167
169
-
1.**Number of subnets that can be part of a peering link should be less than or equal to 200.**
170
-
- For example, in the VENT A and virtual network B peering link (illustrated by blue arrow headed line), total number of subnets participating in the peering here's 4 (two from virtual network A and two from virtual network B side). This number should be <=200.
168
+
1.**Number of subnets that can be part of a peering link should be less than or equal to 400 (200 limit from each local and remote side).**
169
+
- For example, in the virtual network A and virtual network B peering link (illustrated by blue arrow headed line), total number of subnets participating in the peering here's 4 (two from virtual network A and two from virtual network B side). This number should be <=400.
171
170
172
171
1. In the present release (Public preview and GA March 2025, feature remains behind subscription flag), **forward route from non-peered subnet to peered subnet exists** - that is, in the current scenario virtual network A and virtual network B peering, even though Subnet 2 from virtual network A side isn't peered, but it will still have route for Subnet 1 and Subnet 2 in virtual network B.
173
-
- To clarify more, in the subnet peering for virtual network A and virtual network B, customer would expect only Subnet 1 and Subnet 3 from virtual network A to have route for Subnet 1 and Subnet 2 in remote VENT B, however, Subnet 2 and Subnet 4 (from local side virtual network A which isn't peered) also have route for Subnet 1 and Subnet 2 in remote side (virtual network B), meaning the nonpeered subnets can send packet to destination node in the peered subnet, although the packet gets dropped and don't reach virtual machine.
172
+
- To clarify more, in the subnet peering for virtual network A and virtual network B, customer would expect only Subnet 1 and Subnet 3 from virtual network A to have route for Subnet 1 and Subnet 2 in remote virtual network B, however, Subnet 2 and Subnet 4 (from local side virtual network A which isn't peered) also have route for Subnet 1 and Subnet 2 in remote side (virtual network B), meaning the nonpeered subnets can send packet to destination node in the peered subnet, although the packet gets dropped and don't reach virtual machine.
174
173
175
-
- We're recommending users to apply NSGs on the participating subnets to allow traffic from only peered subnets/address spaces. This limitation is removed in the post GA release.
174
+
- We're recommending users to apply NSGs on the participating subnets to allow traffic from only peered subnets/address spaces. This limitation will be removed in the post GA release.
176
175
177
176
1. Subnet Peering and AVNM
178
177
- Connected Group<br>
179
178
If two virtual networks are connected in 'Connected Group', and if Subnet peering is configured over these two virtual networks, subnet peering takes preference and the connectivity between nonpeered subnets gets dropped.
180
179
- AVNM Connectivity Configuration<br>
181
-
AVNM today can't differentiate between virtual network peering and Subnet peering. So let's say if Subnet peering exists between virtual network A and virtual network B, and later an AVNM user tries to establish a virtual network peering between virtual network A and virtual network B through some connectivity configuration (say Hub and Spoke deployment), AVNM would assume that peering between virtual network A and virtual network B already exists and would ignore the new peering request. We recommend users to exercise caution in such conflicting scenarios while using AVNM and Subnet peering
180
+
AVNM today can't differentiate between virtual network peering and subnet peering. So let's say if Subnet peering exists between virtual network A and virtual network B, and later an AVNM user tries to establish a virtual network peering between virtual network A and virtual network B through some AVNM connectivity configuration (say Hub and Spoke deployment), AVNM would assume that peering between virtual network A and virtual network B already exists and would ignore the new peering request. We recommend users to exercise caution in such conflicting scenarios while using AVNM and Subnet peering
182
181
183
182
## Next steps
184
183
185
184
Subnet peering helps you have better conservation of IPv4 space, by letting you reuse address spaces across subnets that need not be peered. It also prevents unnecessary exposure of entire virtual network address space through gateways to on-premises environments. With IPv6 only peering, you can further configure peering over IPv6 only for dual-stack subnets or IPv6 only subnets. Explore these capabilities and let us know if you have feedback and suggestions here. Your feedback on the overall feature would help us make Azure networking more powerful and enabling!
186
185
187
-
To learn more about subnet peering, see [Virtual network peering](/azure/virtual-network/virtual-network-peering-overview.md).
186
+
To learn more about peering, see [Virtual network peering](/azure/virtual-network/virtual-network-peering-overview.md).
Copy file name to clipboardExpand all lines: articles/virtual-network/virtual-network-peering-overview.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -33,9 +33,9 @@ The benefits of using virtual network peering, whether local or global, include:
33
33
34
34
Network traffic between peered virtual networks is private. Traffic between the virtual networks is kept on the Microsoft backbone network. No public internet, gateways, or encryption are required in the communication between the virtual networks.
35
35
36
-
Recently, we have also introduced an added flexibility on top of VNet peering - '**Subnet peering**'.
36
+
We recently introduce an added flexibility on top of virtual network peering - '**Subnet peering**'.
37
37
38
-
It's an added flexibility built on top of VNet peering, where users get an option to choose specific subnets that need to be peered across VNets. User can select or is prompted to enter the list of subnets across the VNets that they want to peer. In contrast, in the case of regular VNet peering, entire address space/subnets across the VNets get peered. For more information, see [How to configure Subnet Peering](how-to-configure-subnet-peering.md).
38
+
It's an added flexibility built on top of virtual network peering, where users get an option to choose specific subnets that need to be peered across virtual networks. User can specify/enter the list of subnets across the virtual networks that they want to peer. In contrast, in regular virtual network peering, entire address space/subnets across the virtual networks get peered. For more information, see [How to configure Subnet Peering](how-to-configure-subnet-peering.md).
39
39
40
40
> [!IMPORTANT]
41
41
> Subnet peering is currently in preview.
@@ -126,7 +126,7 @@ A nominal fee is charged for ingress and egress traffic that uses a virtual netw
126
126
Gateway transit is a peering property that enables a virtual network to use a virtual private network or an ExpressRoute gateway in a peered virtual network. Gateway transit works for both cross-premises and network-to-network connectivity. Traffic to the gateway (ingress or egress) in the peered virtual network incurs virtual network peering charges on the spoke virtual network (or virtual network without a VPN gateway). For more information, see [Azure VPN Gateway pricing](https://azure.microsoft.com/pricing/details/vpn-gateway/) for VPN gateway charges and ExpressRoute gateway charges.
127
127
128
128
>[!NOTE]
129
-
> A previous version of this document stated that virtual network peering charges wouldn't apply on the spoke virtual network (or non-gateway virtual network) with gateway transit. It now reflects accurate pricing per the pricing page.
129
+
> A previous version of this document stated that virtual network peering charges wouldn't apply on the spoke virtual network (or nongateway virtual network) with gateway transit. It now reflects accurate pricing per the pricing page.
0 commit comments