Lesson 5 of 9 · 27m
Mesh VPNs: Hub-and-Spoke, Full Mesh, and Controller-Managed Networks
How to choose between a hub-and-spoke topology, a partial or full mesh, and controller-driven overlays such as Tailscale-style designs without outsourcing your understanding.
“Mesh VPN” is a topology word, not a magic property. WireGuard itself is peer-to-peer: every host knows only the peers you configure. Whether the result is a full mesh, a hub-and-spoke network, or a hybrid depends on how you distribute keys, endpoints, routes, and policy.
Full mesh does not scale socially
A true full mesh means every host can reach every other host directly:
edge-01 <------> edge-02
\ /
\ /
db-01 <----> db-02With N nodes, you manage roughly N(N-1)/2 peer relationships. Ten nodes means 45 relationships. Fifty nodes means 1,225. The math is not the worst part; operational ambiguity is. Every node becomes a distribution point for inventory, revocation, endpoint changes, and debugging.
Full mesh is appropriate for small fleets, high-trust infrastructure clusters, and systems that genuinely need direct low-latency paths. It is not the default answer to “we have more than one server.”
Hub-and-spoke concentrates policy
A hub design routes traffic through one or more gateways:
laptop-a ─┐
laptop-b ─┼── hub-gw ── internal services
server-a ─┘Spokes only know the hub. The hub knows every spoke. This scales configuration better, centralizes firewall policy, and makes revocation simpler: remove the peer at the hub and the endpoint is isolated. The cost is hairpinning traffic through the hub, the hub's bandwidth, and the blast radius of hub failure.
For administrative access, service reachability, and user VPNs, hub-and-spoke is often the operationally sane default.
Partial mesh is the real-world middle
Partial mesh connects nodes that truly benefit from direct paths and routes everything else through hubs. For example, database replicas connect directly, while human laptops use access gateways. This is where design discipline matters: write down which flows deserve direct connectivity and why.
db-01 <-> db-02 <-> db-03 # replication mesh
laptop -> access-gw -> db-01 # administrative path“Everything should be direct” is not a design requirement; it is an aesthetic preference.
Controllers solve distribution, not design
Tools such as Tailscale, Headscale, NetBird, and innernet automate peer discovery, NAT traversal, key rotation, ACLs, and endpoint updates. They can be excellent. But the control plane does not eliminate the need to understand data-plane behavior.
Ask where identity and ACLs are enforced, whether the controller can mint or revoke access, what happens when it is unavailable, whether paths are direct or relayed, and which logs you can export.
A controller-managed network still needs segmentation. “All devices in the tailnet can talk to each other” is usually a convenience decision made before the first compromise.
Endpoint discovery is the hard problem
WireGuard does not dynamically discover endpoints in the core protocol. Static servers can publish stable endpoints. Laptops and NATed hosts often cannot. Controller systems solve this with coordination servers, STUN-like discovery, hole punching, and relays. In self-managed WireGuard, you decide whether mobile peers initiate outbound to stable gateways or whether you operate dynamic endpoint update machinery.
Field notes
- Choose topology by trust domain and traffic pattern, not by the word “mesh.”
- Every direct peer relationship increases exposure; prefer fewer, explainable paths.
- Hubs need capacity planning, DDoS consideration, and highly available design.
- Relays are not evidence of failure. Sometimes NAT physics means a relay is the correct path.
- Keep the control plane's failure mode explicit: cached access, immediate denial, or degraded connectivity are very different security postures.
Was this lesson helpful?