
This is Part 3 of the series The VCF 9.1 VPC Networking Mental Model. Part 2 built the routing model: IP blocks, External Connections, Transit Gateways, Connectivity Profiles, and subnet access modes. It closed with a short warning that VLAN extension serves a different purpose. This part opens the hood on the gateway that makes it possible: the Distributed Transit Gateway (DTGW).
Two questions drive everything discussed below. How does a Virtual Private Cloud (VPC) reach the physical network with no NSX Edge and no routing protocol? And how can a VPC subnet share one broadcast domain with a VLAN that already has servers and a gateway on it? This part answers the first. Part 4, coming soon, will answer the second.
Core idea
A DTGW is one logical gateway that NSX builds on every ESX host. It is attached to an external VLAN whose CIDR already contains the VPC’s External IP block. So the physical router sees VPC addresses as directly connected. VLAN extension reuses the same Distributed VLAN Connection object but dedicates it to a single subnet, so that subnet and an existing VLAN become one Layer 2 domain with one CIDR and one physical gateway.
In everyday terms, picture a supermarket. A centralized gateway is one big checkout by the main door. Every shopper queues there. A distributed transit gateway puts a till at the end of every aisle, so shoppers pay and leave from wherever they are. Only special requests, like returns, still go to the service desk. That desk is the VNA. VLAN extension is different. It knocks a doorway through to the old shop next door, so both share one floor while the stock moves across.
1. What a DTGW really is
A Transit Gateway becomes distributed the moment you attach it to a distributed external connection. The result is a gateway instantiated on each ESX host, with no NSX Edge nodes in the path. Traffic that needs no stateful services runs at close to physical NIC line rate.

Three properties fall out of that design. Each one has a design consequence.
- Every host is an exit. North-south traffic leaves on the host where the VM runs. There is no Edge to hair-pin through and no Edge to size. The price is that the external VLAN must be present on every host in the span, on the same VDS uplinks as the host TEPs.
- East-west is still overlay. VM-to-VM traffic between hosts rides GENEVE between TEPs, as before. The external VLAN is only for traffic entering or leaving the VPC domain.
- Stateful services need a home. Stateful services such as NAT cannot be distributed to the hosts. They run on a Virtual Network Appliance (VNA) cluster. The VPC Gateway’s north-south services are instantiated there, and the VNA must sit inside the external VLAN span.
All external connections on one Transit Gateway must be the same type, all centralized or all distributed. A project can have several DTGWs. They may share a VLAN or use different ones, but public subnets and External IPs must not overlap between DTGWs.

2. The on-link trick: why no BGP and no static routes
A centralized connection needs a Tier-0 gateway on NSX Edge nodes with external routing, such as BGP, to the fabric. A DTGW has none of that. So how does the physical router know where 10.50.0.70 lives?
The answer is one design rule: the External IP block must sit inside the external VLAN’s CIDR. The Transit Gateway wizard says so on the form: “The External IP Block must be within the Gateway CIDR”. In the lab the external VLAN is 150 with 10.50.0.0/24, and the External IP block is 10.50.0.64/26, a slice of that /24.
One thing to know: NSX does not stop you if you break this rule. In the lab, a block of 30.30.30.0/24, which sits in no external VLAN, was added to the connectivity profile and a Public subnet was carved from it. Both saved with status Success. The physical switch has no route to those addresses, so return traffic for that subnet never arrives. Keeping the block inside the VLAN CIDR is your job, not the UI’s.


Think of the external VLAN as one /24 with two owners. The core switch owns the gateway, 10.50.0.1, and sees the whole /24 as a connected route. NSX owns the slice you gave it, 10.50.0.64/26, and answers for every address it hands out from that slice. When the switch needs to reach 10.50.0.70, it does what it does for any host on a connected subnet: it ARPs on VLAN 150, and the DTGW replies. No static route and no BGP are needed, because the address was never outside the switch’s own subnet.
What the external VLAN’s addresses are used for
A common question: is the external VLAN only for Public subnets? No. Public subnets are one of four things NSX carves out of the External IP block. The VLAN itself is a transit network. VMs only get an address from it when they sit on a Public subnet, and even then the subnet is an overlay segment, not the VLAN.
Everything NSX puts on the external VLAN comes from the External IP block. The two Public subnets are from the lab. The single addresses are the examples used in Figure 8 below.
Do not confuse this with VLAN extension in Part 4. A transit VLAN like 150 is carved into small pieces and shared by many VPCs. An extended VLAN is a workload VLAN, and its whole CIDR becomes one subnet.
Adding another external VLAN
If VLAN 150 still has free addresses, you do not need a new VLAN. Add another CIDR from inside 10.50.0.0/24 to the External IP block. You only need a second VLAN when the first one is full or you want a separate exit. The rule stays the same: each VLAN gets its own Distributed VLAN connection, and each External IP block sits inside the VLAN it belongs to. This was tested in the lab with VLAN 160 (10.51.0.0/24):
- In the Default project, create a Distributed VLAN connection for VLAN 160 with gateway 10.51.0.1/24. Leave Dedicated to Subnet off.
- Create an External IP block inside that VLAN, 10.51.0.64/26.
- Share the new connection and the new block with the project.
- Edit the DTGW and add the new connection next to the existing one. The DTGW now has two Distributed VLAN connections.
- Add the new block to the VPC Connectivity Profile.
- When you create a Public subnet, the IP Block field now lists both blocks. Pick the one for the VLAN you want.

The physical side needs the same as VLAN 150: VLAN 160 trunked to every host in the span and an SVI at 10.51.0.1. The lab did not show how NSX chooses between two exits for traffic leaving the VPC, so check the Broadcom docs for that.
The Broadcom tech docs state the requirement. Set up Distributed Network Connectivity says External IP blocks must be the same as, or a subset of, the dedicated VLAN subnets. The VMware Cloud Foundation (VCF) 9.1 design guide adds that public subnet addresses, External IPs, translated NAT addresses and load balancer VIPs are presented to the external VLAN through the host uplinks where the TEPs are.
Three rules from the docs matter most in production:
- Exclude anything already in use. The gateway IP is excluded automatically. Every other address used by a physical device or VM on that VLAN must be excluded from the External IP block with an exclude range. Otherwise NSX can hand it to a VPC and you get a duplicate IP.
- Expect asymmetry from on-link neighbours. Traffic between a device sitting directly on the external VLAN and VPC addresses from the External IP block can be asymmetric. Keep the external VLAN for transit, not for servers.
- Set up the external gateway as documented. Turn off ICMP redirects on the external VLAN gateway. Make sure it forwards a packet that arrived from one ESX host on that VLAN back out to the same host or a different one.
The payoff is operational. Once the VLAN and its gateway exist, new VPCs, public subnets, External IPs and VIPs need zero change in the physical network. To grow, you have two levers. A connectivity profile takes up to five External IP blocks, and the project’s Set External IP Blocks dialog shows “Maximum 5 IP Blocks”. One IP block can also hold several CIDRs. The lab saved a block with eleven, and the NSX API reference lists no maximum for that field. For the supported numbers, check the Broadcom configuration maximums. Whichever lever you use, each CIDR must still sit inside an external VLAN CIDR.
3. Three north-south paths
Not every packet takes the same road out. The access mode of the source subnet decides it.

Only traffic sourced from private or Private-TGW subnets is sent to the VNA cluster for stateful services such as NAT. So a VNA is optional. If you only need public subnets, External IPs and Avi load balancing, you do not need one. Auto-SNAT, custom NAT, the VNA load balancer and (from 9.1.1) DHCP relay to an external server all require it, with N-S Services enabled in the connectivity profile.
What the VM uses as its gateway
A Public subnet’s addresses come from VLAN 150’s range, so it is tempting to give the VMs 10.50.0.1 as their gateway. Do not. Every VPC subnet has its own gateway on the VPC Gateway, and NSX sets it to the first usable address of the subnet. The VM only ever talks to that address. 10.50.0.1 is the DTGW’s next hop, not the VM’s.

Follow a VM at 10.50.0.70 on that Public subnet out to the data centre:
The VM sees a /28 with gateway .65. The switch sees the same address as a host on its /24. Both views are right, because the DTGW sits between them.
Private subnets work the same way at hop 1. A VM on 172.16.0.0/26 uses 172.16.0.1, and a Private-TGW VM uses the first address of its own subnet. The difference comes later, as the table above shows: an External IP is translated on the host, and anything else goes to the VNA for SNAT before it reaches VLAN 150.
Worked example: one external VLAN, many subnets
Here is the whole thing end to end. One DTGW, one external VLAN 150 (10.50.0.0/24, gateway 10.50.0.1 on the core switch) and an External IP block of 10.50.0.64/26. VPC-A has a public subnet with a web VM at 10.50.0.70, a private subnet with an app VM at 172.16.10.10 that owns External IP 10.50.0.100, and a second private subnet with a db VM at 172.16.20.10 and no External IP. VPC-B has a public subnet with a VM at 10.50.0.85. On the physical side there is exactly one thing configured for all of this: the SVI on VLAN 150.

The distributed external connection sets 10.50.0.1 as the default gateway for the external VLAN. The core switch sees VLAN 150 as a connected /24. Now follow the four flows.
- The web VM on the public subnet: 10.50.0.70 comes from the External IP block, which sits inside VLAN 150’s CIDR. For the core switch it is an address in a directly connected subnet. NSX presents public subnet addresses to the external VLAN through the host uplinks where the TEPs are. Nothing is translated and no appliance is in the path.
- The app VM on a private subnet with an External IP: its traffic uses a stateless 1:1 NAT between 172.16.10.10 and 10.50.0.100. External IPs are presented to the external VLAN the same way as public subnet addresses, so inbound connections to 10.50.0.100 work too. No appliance is in the path.
- The db VM on a private subnet with no External IP: to reach the outside it needs Default Outbound NAT (Auto-SNAT), which is a stateful service. Traffic from a private subnet is forwarded to the VNA cluster, which translates it to an address from the External IP block (10.50.0.120 in the figure). This is the only flow in the example that uses an appliance. It needs a VNA cluster and N-S Services.
- The VPC-B VM to the web VM, east-west between VPCs: east-west traffic between workloads is carried by GENEVE between the host TEPs. It does not use VLAN 150 or the core switch.
Two things follow. First, the only addresses that appear on VLAN 150 are the gateway and addresses from the External IP block: public subnet addresses, External IPs, translated NAT addresses and load balancer VIPs. 172.16.x.x never leaves the VPC. Second, adding VPC-C, ten more private subnets or another public subnet changes nothing on the core switch, as long as every public address comes from the block. The only reason to touch the physical network again is a new exit, which section 7 of Part 4, coming soon, covers.
What’s next
Part 4, coming soon, picks up the second question: how a VPC subnet and an existing VLAN become one broadcast domain. It covers the four objects behind VLAN extension, Layer 2 versus Layer 2 plus Layer 3, how many external connections you really need, the migration workflow and the TEP-less VLAN-backed VPC.
Discover more from VMware Cloud Foundation (VCF) Blog
Subscribe to get the latest posts sent to your email.