CISCO N5K vPC配置案例分享——N5K SW1配置:
Step1. 配置管理接口IP地址和缺省路由
N5k-1(config)# int mgmt 0
N5k-1(config-if)# ip address 172.25.182.51/24
N5k-1(config-if)# vrf context management
N5k-1(config-vrf)# ip route 0.0.0.0/0 172.25.182.1
Step2. 启用vPC和LACP
N5k-1(config)# feature vpc
N5k-1(config)# feature lacp
Step3. 创建VLAN.
N5k-1(config)#vlan 101
Step4. 创建vPC domain.
N5k-1(config)# vpc domain 1
Step5. 配置vPC role priority (可选).
N5k-1(config-vpc-domain)# role priority 1000
Step6. 配置peer keepalive link. N5K SW2的管理接口IP地址是172.25.182.52.
N5k-1(config-vpc-domain)# peer-keepalivedestination 172.25.182.52
Note:
--------:: Management VRF will be used as thedefault VRF ::--------
Step7. 配置vPC peer link. 注意:配置为trunk模式,必须在trunk中允许vPC成员所在的VLAN.
N5k-1(config-vpc-domain)# int ethernet 1/17-18
N5k-1(config-if-range)# channel-group 1 modeactive
N5k-1(config-if-range)# int po1
N5k-1(config-if)# vpc peer-link
N5k-1(config-if)# switchport mode trunk
N5k-1(config-if)# switchport trunk allowed vlan1,101
Step8. 配置N2K FEX和fabric接口.
N5k-1(config)# fex 100
N5k-1(config-fex)# pinning max-links 1
Change in Max-links will cause traffic disruption.
N5k-1(config-fex)# int e1/7-8
N5k-1(config-if-range)# channel-group 100
N5k-1(config-if-range)# int po100
N5k-1(config-if)# switchport mode fex-fabric
N5k-1(config-if)# fex associate 100
Step9. 将FEX接口划入vPC. 在FEX 100 online后, 为接口eth100/1/1创建PortChannel, 并将PortChannel划入vPC. 注意: PortChannel号和vPC号可以不同, 但是在两台N5K交换机上vPC号必须相同.
N5k-1(config-if)# int ethernet 100/1/1
N5k-1(config-if)# channel-group 10
N5k-1(config-if)# int po10
N5k-1(config-if)# vpc 10
N5k-1(config-if)# switchport access vlan 101
N5K SW2的配置:
N5k-2(config)# int mgmt 0
N5k-2(config-if)# ip address 172.25.182.52/24
N5k-2(config-if)# vrf context management
N5k-2(config-vrf)# ip route 0.0.0.0/0 172.25.182.1
N5k-2(config)# feature vpc
N5k-2(config)# feature lacp
N5k-2(config)#vlan 101
N5k-2(config)# vpc domain 1
N5k-2(config-vpc-domain)# peer-keepalivedestination 172.25.182.51
Note:
--------:: Management VRF will be used as thedefault VRF ::--------
N5k-2(config-vpc-domain)# int ethernet 1/17-18
N5k-2(config-if-range)# channel-group 1 modeactive
N5k-2(config-if-range)# int po1
N5k-2(config-if)# vpc peer-link
N5k-2(config-if)# switchport mode trunk
N5k-2(config-if)# switchport trunk allowed vlan1,101
N5k-2(config)# fex 100
N5k-2(config-fex)# pinning max-links 1
Change in Max-links will cause traffic disruption.
N5k-2(config-fex)# int e1/9-10
N5k-2(config-if-range)# channel-group 100
N5k-2(config-if-range)# int po100
N5k-2(config-if)# switchport mode fex-fabric
N5k-2(config-if)# fex associate 100
N5k-2(config-if)# int ethernet 100/1/1
N5k-2(config-if)# channel-group 10
N5k-2(config-if)# int po10
N5k-2(config-if)# vpc 10
N5k-2(config-if)# switchport access vlan 101
检查vPC配置的命令:
show feature
//查看vPC是否启用
show vpc brief
//显示vPC的简要信息
show vpc consistency-parameters
//显示一致性检查的参数状态, 这些参数在所有vPC接口都必须一致
show running-config vpc
//显示运行配置中vPC的配置
show port channel capacity
//显示配置了多少个PortChannel, 以及设备上还有多少个PortChannel available.
show vpc statistics
//显示vPC统计信息
show vpc peer-keepalive
//显示vPC的peer keepalive信息
show vpc role
//显示vPC的对端设备状态, 本机的角色, vPC系统MAC地址和系统优先级,本端vPC设备的MAC地址和优先级.
Copyright © All rights Reserved 北京炫亿时代科技有限公司 版权所有