5 Easy Steps to Configure vPC

A simple lab-friendly guide for Cisco Nexus vPC pairs

Both physical switches appear as one logical port-channel to the downstream device.

  • Keepalive: Layer 3 heartbeat between peers.
  • Peer-link: trunk port-channel between peers.
  • Member ports: downstream dual-homed port-channels.

Step 1 – Enable vPC and create the domain

Start with the global features and a common vPC domain ID on both Nexus switches. This enables LACP and vPC, creates the vPC control domain and sets deterministic role priority.

! Run on both switches
feature lacp
feature vpc

vpc domain 10
role priority 100 ! Nexus-1
! role priority 200 ! Nexus-2

Useful vPC domain options

vpc domain 10
peer-switch
peer-gateway
auto-recovery
ip arp synchronize

  • Use the same vPC domain ID on both peers.
  • Use a lower role priority on the switch you prefer as vPC primary.
  • Do not confuse vPC primary with STP root. Plan both deliberately.

Step 2 – Build the Layer 3 keepalive path

The keepalive is only a heartbeat. It should use Layer 3 reachability and should not depend on the peer-link. Use a dedicated routed link, management link, or separate VRF. Do not run the peer-keepalive over the vPC peer-link.

Nexus-1 keepalive

vrf context VPC-KA

interface Ethernet1/47
no switchport
vrf member VPC-KA
ip address 10.255.255.1/30
no shutdown

vpc domain 10
peer-keepalive destination 10.255.255.2 source 10.255.255.1 vrf VPC-KA

Nexus-2 keepalive

vrf context VPC-KA

interface Ethernet1/47
no switchport
vrf member VPC-KA
ip address 10.255.255.2/30
no shutdown

vpc domain 10
peer-keepalive destination 10.255.255.1 source 10.255.255.2 vrf VPC-KA

Test with: ping 10.255.255.2 vrf VPC-KA from Nexus-1, and reverse it from Nexus-2. The keepalive detects peer health. It does not carry data VLAN traffic.

Step 3 – Build the vPC peer-link

The peer-link is a trunk port-channel between the two Nexus switches. It is mandatory for vPC. It carries vPC control traffic and VLAN traffic when needed, such as orphan-port traffic or failure scenarios.

! Run equivalent config on both Nexus switches
interface Ethernet1/49-50
switchport
channel-group 100 mode active
no shutdown

interface port-channel100
description VPC-PEER-LINK
switchport
switchport mode trunk
switchport trunk allowed vlan 10,20,30
spanning-tree port type network
vpc peer-link
no shutdown

  • Use at least two physical links for resilience.
  • Use LACP active mode.
  • Allow the VLANs required by downstream vPCs and any orphan ports.
  • Use spanning-tree port type network on the peer-link.

Easy memory: Keepalive = heartbeat. Peer-link = vPC control and VLAN safety path.

Step 4 – Configure downstream vPC member ports

The downstream device sees one logical port-channel, even though the links land on two physical Nexus switches. The same vPC ID must be configured on the matching port-channel on both peers.

! Run matching config on both Nexus switches
interface Ethernet1/1
switchport
channel-group 10 mode active
no shutdown

interface port-channel10
description DOWNSTREAM-VPC
switchport
switchport mode trunk
switchport trunk allowed vlan 10,20
spanning-tree port type edge trunk
vpc 10
no shutdown

  • Use the same port-channel number if possible. It keeps the config easy to read.
  • Use the same vPC ID on both peers for the same downstream bundle.
  • For a server, firewall, or downstream switch, configure its side as an LACP port-channel.
  • For access ports, use spanning-tree port type edge. For trunks to endpoints/firewalls, use edge trunk only when appropriate.

Step 5 – Verify vPC state and consistency

vPC is simple to configure, but consistency checks decide whether it works cleanly.

show vpc brief
show vpc consistency-parameters global
show vpc consistency-parameters interface port-channel10
show port-channel summary
show lacp neighbor
show spanning-tree vlan 10

Healthy result checklist

  • vPC peer-link status is up (Po100).
  • vPC keepalive status is peer is alive.
  • Member vPCs show up/up (Po10).
  • No Type-1 consistency mismatch.
  • Allowed VLANs match on both peers.
  • LACP neighbours are present on both sides.

Type-1 consistency issues can suspend vPC member ports. Always verify both global and per-interface consistency. Check STP root placement and vPC peer-switch behaviour in L2 designs.

Failure test idea

Shut one downstream member link and confirm traffic still uses the other peer. Then restore it and check port-channel balance and vPC state again.

vPC cheat sheet

  1. Enable vPC and create domain
  2. Build L3 peer-keepalive path
  3. Build peer-link trunk port-channel
  4. Add downstream vPC member port-channels
  5. Verify vPC, LACP, STP, and consistency

Key terminology

  • vPC domain: the control relationship between the pair.
  • Peer-keepalive: Layer 3 heartbeat.
  • Peer-link: trunk port-channel between the peers.
  • vPC member port: downstream port-channel with the vPC ID.

Common mistakes

  • Using the peer-link as the keepalive path.
  • Different allowed VLANs on each side of the same vPC member port-channel.
  • Forgetting the vpc <id> command under the downstream port-channel.
  • Ignoring consistency checks after the config looks correct.
  • Not planning STP root, peer-switch, peer-gateway, and L3 gateway behaviour.

Leave a Reply

Trending