Back to Blog
Cloud16 min readJun 2026

Advanced Cloud Networking: PrivateLink, Hybrid & DNS

Beyond the basic VPC: private connectivity to services, peering vs Transit Gateway, hybrid links to on-prem, and DNS that actually resolves across the boundary.

CloudNetworkingPrivateLinkDNS
SB

Sri Balaji

Founder · TheSimplifiedTech

On this page

The wall you hit after the VPC works

You built a VPC. Subnets are carved up, route tables are clean, the NAT gateway works, and your app reaches the internet. Then a real requirement lands: "Reach the managed database, but never over the public internet." "Connect this VPC to four others without a tangle of peerings." "Let the on-prem payroll system call our internal API." "Make db.internal.acme.com resolve the same from a Lambda, an EC2 box, and a server in the data center." Suddenly the basic VPC mental model runs out of road.

This is the layer where cloud networking stops being about one VPC and starts being about connectivity between things, services, VPCs, and your own data center, plus the DNS that ties them together. Get it right and traffic stays private, predictable, and cheap. Get it wrong and you either expose internal systems to the internet or spend a day staring at a name that won't resolve.

Who this is for

Engineers who already understand a single VPC (subnets, route tables, security groups) and now need private service access, multi-VPC topologies, hybrid links to on-prem, and DNS that works across all of it. New to VPCs? Start with [Cloud Networking Fundamentals: How a VPC Actually Works](/blog/cloud-networking-fundamentals-vpc-explained) first.

One idea: connectivity is plumbing, not magic

Advanced cloud networking is just deciding which pipes connect which buildings, and making sure every building uses the same phone book.
The whole article in one line

Every option below is a different shape of pipe, and DNS is the shared phone book. Before the cloud-specific names overwhelm you, anchor on the physical picture:

A private hallway between two adjacent officesVPC peering, direct, 1:1, non-transitive
A central transit hub every office connects to onceTransit Gateway, hub-and-spoke for many VPCs
A service window into a shop, no street accessPrivateLink / Private Service Connect, reach one service privately
An armored tunnel to your old headquartersVPN / Direct Connect / ExpressRoute, hybrid to on-prem
The shared phone book every building trustsPrivate DNS zones, internal names that resolve everywhere
Cloud networking primitives mapped to a city of buildings.

The picture: services, VPCs, and on-prem

Here is the topology most senior cloud engineers end up building. An application VPC reaches a managed service privately through PrivateLink, connects to other VPCs through a Transit Gateway, and reaches the on-prem data center over Direct Connect or a VPN, while a private DNS resolver makes internal names resolve from every side.

private circuitBGP routesattachmentattachmentprivate DNS namePrivateLinkqueriesforward zone
On-Prem DC

10.10.0.0/16

Direct Connect / VPN

Hybrid link

Transit Gateway

Hub for VPCs + on-prem

App VPC

10.0.0.0/16

PrivateLink Endpoint

ENI in private subnet

Managed Service

DB / SaaS provider

Shared-Svcs VPC

10.1.0.0/16

Private Resolver

Route 53 / Cloud DNS

App VPC reaches a service via PrivateLink, peers VPCs through a Transit Gateway, links on-prem via Direct Connect/VPN, and resolves internal names via a private resolver.

  1. 1

    App makes a request to db.internal.acme.com

    The app does not know or care whether the target is a managed service, another VPC, or on-prem. It just resolves a name.

  2. 2

    The private resolver answers

    A private hosted zone returns a private IP, the PrivateLink endpoint's ENI, a peer VPC address, or (via a forwarding rule) an on-prem record.

  3. 3

    Traffic takes a private pipe

    PrivateLink for a single service, the Transit Gateway for VPC-to-VPC, or Direct Connect/VPN for on-prem. Nothing crosses the public internet.

  4. 4

    Return path mirrors it

    Route tables on both ends must point back the right way. Asymmetric routing, out one pipe, back another, is the silent killer here.

VPC peering vs Transit Gateway

VPC peering is a direct, point-to-point link between two VPCs. It is cheap and low-latency, but it is non-transitive: if A peers with B and B peers with C, A still cannot reach C. With N VPCs that all need to talk, you face N·(N-1)/2 peerings, a full mesh that becomes unmanageable past a handful.

Transit Gateway (AWS) / Cloud Router + VPC peering hubs (GCP) is a hub-and-spoke router. Each VPC attaches once to the hub, and the hub routes between all of them, and to on-prem over the same attachment model. It costs more (per-attachment and per-GB) and adds a hop, but it turns an O(N²) mesh into O(N) attachments and gives you one place to apply route tables and segmentation. Rule of thumb: 2–3 VPCs that rarely change, use peering; a growing fleet or anything hybrid, use a Transit Gateway.

PatternJoinsTransitive?Best whenWatch out for
VPC PeeringTwo VPCs, full CIDRsNo2–3 stable VPCs, lowest cost/latencyMesh explosion; overlapping CIDRs block it
Transit GatewayMany VPCs + on-prem via a hubYes (per route table)Growing fleet, central segmentation, hybridPer-attachment + data cost; extra hop
PrivateLink / PSCConsumer → one serviceN/AConsume a SaaS/internal API/AWS service privatelyPer-service only; one-directional
VPN / Direct ConnectCloud ↔ on-premVia TGW/routerReaching the data centerVPN = internet-dependent; DX = lead time + cost
Pick the connectivity pattern by what you are actually joining.

Hybrid connectivity (VPN / Direct Connect / ExpressRoute)

Hybrid means joining your cloud network to your physical data center. Two grades exist. A site-to-site VPN runs an encrypted IPsec tunnel over the public internet, fast to stand up, cheap, but latency and throughput ride on the open internet, so it varies. Direct Connect (AWS) / ExpressRoute (Azure) / Cloud Interconnect (GCP) is a *dedicated private circuit* from a carrier into the cloud provider, consistent latency, higher bandwidth, lower per-GB cost at scale, but weeks of lead time and a monthly port fee.

The common production pattern is both: Direct Connect as the primary path for predictable performance, with a VPN as automatic failover if the circuit drops. Routes are usually exchanged via BGP, so each side learns the other's prefixes dynamically, which is exactly why your CIDR planning has to be disjoint from day one (more on that in mistakes).

How DNS actually resolves across the boundary

DNS is where hybrid setups quietly fall apart, because there are *three* name spaces, cloud private zones, on-prem internal zones, and the public internet, and every resolver has to know which one to ask for a given name.

Private hosted zones

A private zone (Route 53 private hosted zone / Cloud DNS private zone) is a DNS zone visible only inside the VPCs you associate with it. db.internal.acme.com resolves to a private IP for anything in the VPC and does not exist on the public internet. This is how you give services stable internal names without ever exposing them.

Split-horizon (split-brain) DNS

Split-horizon means the *same name* returns *different answers* depending on who asks. api.acme.com resolves to a private endpoint when queried from inside the VPC, and to a public load balancer when queried from the internet. You achieve it by running a public zone and a private zone for the same domain; the private zone wins for in-VPC queries. It is powerful, one hostname everywhere, but it is the single most confusing failure mode when someone debugs from the wrong network and gets the "other" answer.

Resolution across hybrid

For cloud and on-prem to resolve each other's names you need a resolver with forwarding rules: an inbound endpoint so on-prem can query cloud names, and an outbound endpoint with a conditional forwarder that says "send *.corp.local queries to the on-prem DNS server at 10.10.0.53." Without these, an instance in AWS asking for an on-prem hostname gets NXDOMAIN even though the network path is wide open.

Common mistakes that cost hours

  1. Overlapping CIDRs. Two VPCs (or a VPC and on-prem) using 10.0.0.0/16 *cannot* be peered or routed together, routing is ambiguous. Plan a disjoint IP address scheme across every VPC and data center *before* you build anything. This is the #1 retrofit nightmare.
  2. Exposing internal services publicly. Reaching for a public load balancer or a 0.0.0.0/0 security-group rule because "it was faster than PrivateLink." Internal APIs and databases should only ever be reachable over private paths, PrivateLink, peering, or the Transit Gateway.
  3. DNS works in cloud, fails to on-prem (or vice versa). Network path is open but names won't resolve, because there is no conditional forwarder / resolver endpoint bridging the two name spaces. Always test resolution *from both sides*.
  4. Split-horizon confusion. Debugging api.acme.com from your laptop (public answer) while the app inside the VPC gets the private answer, and concluding the app is broken. Always check which network the failing query came from.
  5. Asymmetric routing. Traffic leaves over the Transit Gateway and tries to return over a VPN, or the return route table never got the peer's CIDR. Stateful firewalls drop the reply. Confirm route tables point back symmetrically on both ends.
  6. Peering mesh sprawl. Adding the fifth, sixth, seventh peering by hand until nobody can reason about the topology. Move to a Transit Gateway hub the moment you outgrow a handful of VPCs.

Takeaways

The whole article in seven lines

  • Advanced networking = choosing pipes between services, VPCs, and on-prem, plus a shared DNS phone book.
  • **PrivateLink / PSC**: reach one service privately, one-directional, no CIDR entanglement.
  • **Peering**: cheap, direct, 1:1, non-transitive, fine for 2–3 stable VPCs.
  • **Transit Gateway**: hub-and-spoke that scales VPC-to-VPC and hybrid; turns O(N²) into O(N).
  • **VPN** = quick internet-based tunnel; **Direct Connect/ExpressRoute** = dedicated private circuit. Often both, with VPN as failover.
  • **Private zones** hide internal names; **split-horizon** serves the same name differently per network; **forwarding rules** bridge cloud and on-prem.
  • Plan **disjoint CIDRs** first, keep internal services off public paths, and test DNS from *both* sides.

Where to go next

Build the muscle memory hands-on, then zoom out to how this fits a real multi-account organization.

Want to go deeper?

This article covers concepts taught hands-on in the Cloud Engineer and DevOps career paths, with real terminal labs, production scenarios, and structured lessons.