VRF and Separate Routing Tables
Why separate routing tables?
Virtual routing and forwarding (VRF) gives a router multiple Layer 3 routing contexts. Each context can select a different path for the same destination. Think of a shared office building with two independent address books: the street name alone is not enough; you must know which book to consult. VRF-lite provides this separation locally without requiring an MPLS VPN backbone. The address itself is unchanged.
Trace overlapping destinations
Two fictional tenants use the same subnet. Their interfaces belong to different VLANs and VRFs. In this paper example, ingress assignment selects the routing table; there are no policy overrides or cross-table lookups. A packet to 198.51.100.8 arriving through A selects A-uplink, while the same destination through B selects B-uplink. The prefixes in these diagrams are documentation-only addresses, not public lab targets.
VLAN 10 -> A-gateway -> VRF A (table 100)VLAN 20 -> B-gateway -> VRF B (table 200)A: 192.0.2.0/24 -> A-LANB: 192.0.2.0/24 -> B-LANA: 198.51.100.0/24 -> A-uplinkB: 198.51.100.0/24 -> B-uplinkVLAN and VRF solve different problems
A VLAN separates Layer 2 broadcast domains. A VRF separates Layer 3 forwarding decisions. Several VLAN gateways can belong to one VRF and be routed between them when routes and policy permit. Conversely, two VRFs do not automatically separate devices sharing a Layer 2 segment. Design both boundaries. The routing information base (RIB) stores routing decisions; the forwarding information base (FIB) supplies forwarding entries. A route present in a control-plane table is not proof of installed forwarding state.
VRF-lite and platform boundaries
In Linux, a VRF device is associated with a routing table and L3 interfaces join that context. Routing-policy rules and socket binding can also influence table selection. VRFs are not independent operating systems or full network namespaces. In a BGP/MPLS VPN architecture, route distribution and labels extend tenant separation across a provider backbone; this is a distinct mechanism, not a prerequisite for VRF-lite. Review platform defaults and fallback rules before relying on isolation.
Practice and common mistakes
Predict the egress for 192.0.2.50 from VLAN 20: B-LAN. Looking only at the destination is insufficient. If a more specific /32 is installed in B, it wins over B’s /24 in the simplified model; A remains unchanged. Do not infer encryption, application authorization or guaranteed isolation from a VRF name. Next, design a narrow shared-service path.
Check Your Understanding
Solidify your learning with the interactive assessment directly below this lesson.
Concept Quiz & Questions
VRF and Separate Routing Tables Quiz
Apply VRF concepts to fictional offline scenarios.
A and B contain the same /24. What selects the table in the paper example?
A packet to 198.51.100.8 arrives in VRF B. Which egress is selected?
What does a VLAN primarily separate?
A /32 is installed in B alongside a matching /24. What happens in the simplified model?
What is required in addition to VRF separation to enforce application authorization?