Pcornel
Browse topics
Options
Recent
Favorites
Networking · Technical reference

VNI

Direct answer

The VXLAN Network Identifier (VNI) is a 24-bit segment ID in the VXLAN header, allowing about 16 million segments instead of 4094 VLANs.

When to use this

Use it when mapping VLANs or VRFs to VNIs, or when a VNI is down or mismatched between VTEPs.

First 30 seconds

1. The VNI is a 24-bit identifier (16 M segments).

2. L2 VNI per VLAN; L3 VNI per VRF.

3. Mapping must match across VTEPs.

4. BUM replication method per VNI.

5. Document VNI plan.

Operational verification

VLAN/VRF → VNI → encapsulation

Context & applicabilityCommon mistakes · platform/version boundaries
Platform / version applicability
Protocol standard + deployed implementation
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

PlatformProtocol standard · Cisco IOS / IOS XE
Key commandshow nve vni
Scope / prerequisiteUse it when mapping VLANs or VRFs to VNIs, or when a VNI is down or mismatched between VTEPs.
Show · 1
What next?3 suggested next steps
Catalog command links1
Evidence1
On this pageJump to a specific section
Verification

Show Commands

Read-only Cisco show commands for confirming state, narrowing a fault and interpreting the current boundary.

Operational workflow

Verification & Troubleshooting

Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.

3 steps Observe → verify → isolate → change minimally → repeat the original test.
ObservedRecord what the original test actually shows

Capture the concrete output, symptom, packet, log or counter before changing anything.

Step 1 Layered verification and original-test closure Verify boundary

VNI — Verify one known MAC/IP in the intended VNI, observe the VNI in an encapsulated packet, and confirm the remote VTEP maps it into the correct local VLAN/VRF.

Step 2 Observation → implication → next check Narrow the fault

VNI — If one tenant segment fails while others work, compare VNI state and local mapping on both VTEPs before debugging the underlay. If mappings match, inspect endpoint learning and policy within that VNI.

Step 3 Common mistakes Narrow the fault
  • VNI to VLAN mapping not identical on all VTEPs.
  • Reusing VNIs for different segments.
Evidence references

Evidence · 1 on this Topic

Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.

observation · 1
Command lookup Jump straight to Cisco syntax
Key points
  • The VNI (VXLAN Network Identifier) is a 24-bit segment ID, allowing about 16 million segments.
  • A Layer 2 VNI maps to a VLAN; a Layer 3 VNI maps to a VRF.
  • Both ends must map the same VNI to the same segment.
Key checks
  • show nve vni — VNI, mcast/ingress replication, state
  • show running-config | section vlan configuration|member vni — VLAN-to-VNI mapping
ReferenceHow it works1 section · depth on demand

Operational mechanics and ownership

VNI — A VXLAN VNI is a 24-bit logical segment identifier carried in the VXLAN header. Matching VLAN numbers are not required across sites; the VLAN-to-VNI mapping at each VTEP is what matters. The VTEP owns local VLAN/VRF-to-VNI binding and uses the VNI during encapsulation/decapsulation. A tunnel can be up while one VNI is missing or mapped to the wrong local segment.

ReferenceImportant terms & boundaries2 sections · depth on demand

In depth

The VNI: VXLAN's segment identifier

RFC 7348 identifies each VXLAN overlay segment with a 24-bit VXLAN Network Identifier (VNI). That allows up to 16 million segments in one administrative domain, against 4094 usable VLANs. Inner MAC addresses can overlap between VNIs without conflict, because the VNI keeps the segments apart.

VNI in the header (RFC 7348)

FieldBitsValue
Flags8I bit set to 1 for a valid VNI; other bits reserved (0)
Reserved240
VNI24Segment ID
Reserved80

Two kinds of VNI in BGP EVPN (Cisco Catalyst 9300 BGP EVPN VXLAN guide)

VNI typeMapped toUsed for
Layer 2 VNIA local VLAN (bridge domain)Bridging within one subnet across VTEPs
Layer 3 VNIA VRFRouting between subnets of that VRF across VTEPs
LEAF1(config)# vlan configuration 20
LEAF1(config-vlan-config)# member evpn-instance 20 vni 10020
LEAF1(config)# vlan configuration 999
LEAF1(config-vlan-config)# member vni 50001
LEAF1(config)# vrf definition CORP
LEAF1(config-vrf)# vnid 50001
LEAF1(config)# interface nve1
LEAF1(config-if)# source-interface Loopback1
LEAF1(config-if)# host-reachability protocol bgp
LEAF1(config-if)# member vni 10020 ingress-replication
LEAF1(config-if)# member vni 50001 vrf CORP
LEAF1# show nve peers
Interface  VNI      Type Peer-IP          RMAC/Num_RTs   eVNI     state flags UP time
nve1       50001    L3CP 10.255.255.2     a4bb.6d22.0001 50001      UP  A/M/4 2d03h
nve1       10020    L2CP 10.255.255.2     6              10020      UP   N/A  2d03h
LEAF1# show nve vni
Interface  VNI        Multicast-group VNI state  Mode  BD    cfg vrf
nve1       10020      N/A             Up         L2CP  20    CLI N/A
nve1       50001      N/A             Up         L3CP  N/A   CLI CORP

Numbering plan

PracticeExample
Encode the VLAN in the L2 VNIVLAN 20 → VNI 10020
Separate range for L3 VNIsVRF CORP → 50001, VRF GUEST → 50002
Same VNI for the same segment on every VTEPVLAN numbers can differ per switch, but the VNI must match

VNI and VLAN are only locally linked

The VLAN ID is local to each switch: VLAN 20 on one leaf and VLAN 120 on another can map to the same VNI 10020, and the hosts are in the same segment. The VNI is the fabric-wide identifier; the VLAN is only the access-side handle.

Documented example, not captured output.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.

Quick reference

The VNI is VXLAN's segment number, similar to a VLAN ID but 24 bits long, so millions of separate segments are possible instead of 4,094. A Layer 2 VNI represents one bridged network; a Layer 3 VNI represents a VRF and carries routed traffic between leaves. Consistent VLAN-to-VNI mapping across the fabric is what makes a segment the same segment everywhere.

The VNI (VXLAN Network Identifier) is a 24-bit segment ID — about 16 million segments, compared with 4094 VLANs. An L2 VNI maps to a VLAN/bridge domain; an L3 VNI identifies a VRF for routed traffic in symmetric IRB.

vlan 100
 vn-segment 10100              ! NX-OS: VLAN 100 → L2 VNI 10100
interface nve1
 member vni 10100
  ingress-replication protocol bgp
 member vni 50001 associate-vrf
show nve vni
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor docProtocol standard + deployed implementation RFC 7348

Authoritative/upstream documentation reviewed for bounded claims in Virtualization & Overlays → VXLAN → VNI. Documentation verification only; this is not observed lab or production Evidence.

Basis: https://www.rfc-editor.org/rfc/rfc7348.html · confidence 94%
Confirmation

Confirm action

Continue?