Skip to content

VPC Groups

vPC groups can be named according to a naming convention defined once, without having to specify a name for every group. The following placeholders can be used when defining the naming convention:

  • \\g<switch1_id>: gets replaced by the respective node ID of the first leaf
  • \\g<switch2_id>: gets replaced by the respective node ID of the second leaf

Location in GUI: Fabric » Access Policies » Policies » Switch » Virtual Port Channel default

Diagram
NameTypeConstraintMandatoryDefault Value
vpc_groupsClass[vpc_groups]No

NameTypeConstraintMandatoryDefault Value
modeChoiceexplicit, consecutive, reciprocalNoexplicit
groupsList[groups]No

NameTypeConstraintMandatoryDefault Value
idIntegermin: 1, max: 1000Yes
nameStringRegex: ^[a-zA-Z0-9_.:-]{1,64}$No
switch_1Integermin: 1, max: 16000Yes
switch_2Integermin: 1, max: 16000Yes
policyStringRegex: ^[a-zA-Z0-9_.:-]{1,64}$No

Example 1: In the example below we create vPC pairs by manually defining them, including the name of the group. The switch_1 and switch_2 refer to the nodes ids which were assigned during discovery, where the id is a new id which refers to the new vPC group containing both leaf switches.

apic:
node_policies:
vpc_groups:
mode: explicit
groups:
- id: 101
switch_1: 101
switch_2: 102
name: vpc-group-1

Example 2: In the example below we create vPC pairs by manually defining them and we apply a vpc domain policy defining the peer dead interval and delay restore timers. The policy myVpcPolicy is a policy which defines the peer_dead_interval and delay_restore_timer for a leaf switch. (apic:access_policies:switch_policies:vpc_policies)

apic:
node_policies:
vpc_groups:
mode: explicit
groups:
- id: 101
switch_1: 101
switch_2: 102
policy: myVpcPolicy

Example 3: In the example below we automatically create vPC pairs of all switches in a consecutive order (101-102, 103-104,…) .

apic:
node_policies:
vpc_groups:
mode: consecutive

Example 4: In the example below we automatically create vPC pairs of all switches in a reciprocal order (101-103, 102-104,…) .

apic:
node_policies:
vpc_groups:
mode: reciprocal

Example 5: In the example below we create vPC pairs by manually defining them, but we make use of the automatic naming convention for each group. Where in our example this would result into vpc-101-102. The \g will capture a value of the object listed between <> from within this group, which is in our case the switch1_id and switch2_id values.

apic:
access_policies:
vpc_group_name: vpc-\g<switch1_id>-\g<switch2_id>
node_policies:
vpc_groups:
mode: explicit
groups:
- id: 101
switch_1: 101
switch_2: 102