配置vPC的步骤:
1、配置vPC domain
2、配置vPC之间的keepalive link
3、配置vPC之间的peer link
4、配置vPCs
5、确认双方配置一致

拓扑及描述:
DC1-N7K-5作为Core,DC2-N7K-1和DC2-N7K-2是汇聚层设备,L3连接Core,而通过vPC下联DC2-N5K-1,DC2-N5K-1作为接入层设备使用E1/26连接终端设备VR。

配置命令:

DC1-N7K-5
DC1-N7K-5(config)#feature ospf
DC1-N7K-5(config)#router ospf 1
DC1-N7K-5(config-router)#router-id 5.5.5.5
DC1-N7K-5(config)#interface e3/25
DC1-N7K-5(config-if)#ip add 202.100.13.1/24
DC1-N7K-5(config-if)#ip router ospf 1 are 0
DC1-N7K-5(config-if)#no shut
DC1-N7K-5(config)#interface e3/26
DC1-N7K-5(config-if)#ip add 202.100.14.1/24
DC1-N7K-5(config-if)#ip router ospf 1 are 0
DC1-N7K-5(config)#no shu
DC1-N7K-5(config)#int lo0
DC1-N7K-5(config-if)ip add 61.128.1.1/24
DC1-N7K-5(config-if)#ip router ospf 1 area 0
DC1-N7K-5(config)#int lo1
DC1-N7K-5(config-if)#ip add 128.6.7.6/24
DC1-N7K-5(config-if)#ip router ospf 1 are 0
DC2-N7K-1
DC1-N7K-1(config)#feature interface-vlan
DC1-N7K-1(config)#vlan 10
DC1-N7K-1(config-vlan)#name VLAN10
DC1-N7K-1(config)#inter vlan 10
DC1-N7K-1(config-if)#ip add 202.100.1.252/24
DC1-N7K-1(config-if)#ip router ospf 1 a 0
DC1-N7K-1(config-if)#no shut
DC1-N7K-1(config)#feature ospf
DC1-N7K-1(config)#router ospf 1
DC1-N7K-1(config-router)#router-id 1.1.1.1
DC1-N7K-1(config)#inter e3/7
DC1-N7K-1(config-if)#ip add 202.100.13.3/24
DC1-N7K-1(config-if)#ip router ospf 1 a 0
DC1-N7K-1(config-if)#no shu
开启vPC和LACP feature
DC1-N7K-1(config)#feature vpc
DC1-N7K-1(config)#feature lacp
配置vPC domain和peer keepalive link
DC1-N7K-1(config)#vpc domain 7
DC1-N7K-1(config-vpc-domain)#role priority 73 >>>默认为32768,越小越优先,如一致,比较小的系统MAC
DC1-N7K-1(config-vpc-domain)#system-priority 2500
DC1-N7K-1(config-vpc-domain)#peer-keepalive destination 202.100.14.4 source 202.100.13.3
配置peer link
DC1-N7K-1(config)#inter e3/1-2
DC1-N7K-1(config-if-range)#channel-group 20 mode active
DC1-N7K-1(config-if-range)#no shu
DC1-N7K-1(config-if-range)#exit
DC1-N7K-1(config)#inter port-channel 20
DC1-N7K-1(config-if)#sw mode trunk
DC1-N7K-1(config-if)#vpc peer-link
配置vPC
DC1-N7K-1(config)#inter e3/4
DC1-N7K-1(config-if-range)#channel-group 30 mode active
DC1-N7K-1(config-if-range)#no shu
DC1-N7K-1(config)#int port-channel 30
DC1-N7K-1(config-if)#sw mode trunk
DC1-N7K-1(config-if)#vpc 30
配置HSRP
DC1-N7K-1(config)#feature hsrp
DC1-N7K-1(config)#interface vlan 10
DC1-N7K-1(config-if)#hsrp 1
DC1-N7K-1(config-if-hsrp)#ip 202.100.1.254
DC1-N7K-1(config-if-hsrp)#preempt
DC1-N7K-1(config-if-hsrp)#priority 105
DC2-N7K-2
DC1-N7K-2(config)#feature interface-vlan
DC1-N7K-2(config)#vlan 10
DC1-N7K-2(config-vlan)#name VLAN10
DC1-N7K-2(config)#inter vlan 10
DC1-N7K-2(config-if)#ip add 202.100.1.253/24
DC1-N7K-2(config-if)#ip router ospf 1 a 0
DC1-N7K-2(config-if)#no shut
DC1-N7K-2(config)#feature ospf
DC1-N7K-2(config)#router ospf 1
DC1-N7K-2(config-router)#router-id 2.2.2.2
DC1-N7K-2(config)#inter e3/15
DC1-N7K-2(config-if)#ip add 202.100.14.4/24
DC1-N7K-2(config-if)#ip router ospf 1 a 0
DC1-N7K-2(config-if)#no shu
开启vPC和LACP feature
DC1-N7K-2(config)#feature vpc
DC1-N7K-2(config)#feature lacp
配置vPC domain和peer keepalive link
DC1-N7K-2(config)#vpc domain 7
DC1-N7K-2(config-vpc-domain)#role priority 74 >>>默认为32768,越小越优先,如一致,比较小的系统MAC
DC1-N7K-2(config-vpc-domain)#system-priority 2500
DC1-N7K-2(config-vpc-domain)#peer-keepalive destination 202.100.13.3 source 202.100.14.4
配置peer link
DC1-N7K-2(config)#inter e3/9-10
DC1-N7K-2(config-if-range)#channel-group 20 mode active
DC1-N7K-2(config-if-range)#no shu
DC1-N7K-2(config-if-range)#exit
DC1-N7K-2(config)#inter port-channel 20
DC1-N7K-2(config-if)#sw mode trunk
DC1-N7K-2(config-if)#vpc peer-link
配置vPC
DC1-N7K-2(config)#inter e3/12
DC1-N7K-2(config-if-range)#channel-group 30 mode active
DC1-N7K-2(config-if-range)#no shu
DC1-N7K-2(config)#int port-channel 30
DC1-N7K-2(config-if)#sw mode trunk
DC1-N7K-2(config-if)#vpc 30
配置HSRP
DC1-N7K-2(config)#feature hsrp
DC1-N7K-2(config)#interface vlan 10
DC1-N7K-2(config-if)#hsrp 1
DC1-N7K-2(config-if-hsrp)#ip 202.100.1.254
DC1-N7K-2(config-if-hsrp)#preempt
DC2-N5K-1
配置vPC
DC1-N5K-1(config)#feature lacp
DC1-N5K-1(config)#inter e1/4,e1/12
DC1-N5K-1(config-if-range)#channel-group 30 mode active
DC1-N5K-1(config-if-range)#exit
DC1-N5K-1(config)#inter port-channel 30
DC1-N5K-1(config-if)#sw mode trunk
配置vlan接入
DC1-N5K-1(config)#vlan 10
DC1-N5K-1(config-vlan)#name VLAN10
DC1-N5K-1(config)#inter e1/26
DC1-N5K-1(config-if)#speed 1000
DC1-N5K-1(config-if)#sw mode access
DC1-N5K-1(config-if)#sw access vlan 10
DC1-N5K-1(config-if)#spanning-tree port type edge
VR

Router(config)#inter f0/0
Router(config-if)#ip add 202.100.1.2 255.255.255.0
Router(config-if)#no shu

Router(config)#ip route 0.0.0.0 0.0.0.0 202.100.1.254

2、查看Peer Link状态:

3、查看Port-channel情况:

4、查看对应vPC,show vpc或者show vpc vpc-id:

5、一致性检查:

全局的vPC参数一致性,尤其是Type1的参数,必须要一致,Type2可以不一致,但是会报错。

6、检查对应vPC的参数一致性(接口):

对于上述拓扑中的Router去访问N7K(core)的Loopback0和1的地址,我们需要将N5K的load-balance的hash计算方式修改为基于目的IP地址的,这样一个“奇数”一个“偶数”的IP地址很容易分别使用不同的链路转发。
DC1-N5K-1(config)#inter e1/26
DC1-N5K-1(config-if)#port-channel load-balance ethernet destination-ip

Nexus-配置vPC 实验一的更多相关文章

  1. 为Nexus配置阿里云代理仓库【转】

    Nexus默认远程仓库为https://repo1.maven.org/maven2/ 慢死,还常连不上. 可以添加阿里云代理仓库 URL:http://maven.aliyun.com/nexus/ ...

  2. 架构(二)Maven安装以及Nexus配置

    一 Maven安装配置 1.1 下载 http://mirrors.tuna.tsinghua.edu.cn/apache/maven/maven-3/3.5.4/binaries/apache-ma ...

  3. 使用Nexus配置Maven私有仓库

    使用Nexus配置Maven私有仓库 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.安装配置Nexus 1>.下载nexus 下载地址:https://www.sonat ...

  4. 【Maven】Nexus配置和使用

    Nexus安装 nexus安装,可以参照:[Maven]Nexus(Maven仓库私服)下载与安装 Nexus简单说明 用途:指定私服的中央地址.将自己的Maven项目指定到私服地址.从私服下载中央库 ...

  5. Nexus-配置vPC 实验二

    实验一中介绍的是单面的vPC,本实验配置的是dual site(双面vPC),这样的情况将上下的Port-channel都配置在了同一vPC下面. 实验拓扑如下: N5K-1配置:N5K-1(conf ...

  6. MHA+Atlas+mysql一主一从开启gtid安装配置与实验

    各节点架构 (说明:生产环境有两个节点可以组成一套完整集群,我是测试环境,因此对于manager以及atlas和binlog server都是单点,如果生产环境,相应的将manager以及atlas和 ...

  7. Nexus配置

    1.可以为maven项目单独配置nexus路径 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi=&q ...

  8. Gradle nexus配置

    1.下载Gradle; 2.添加脚本init.gradle到gradle的init.d目录中: ext { nexus = 'http://192.168.184.6:8081/nexus' user ...

  9. maven+nexus配置本地私有仓库

    以下是settting.xml的配置 <?xml version="1.0" encoding="UTF-8"?> <settings> ...

随机推荐

  1. Windows下PHP安装 Imagick 扩展

    1.下载拓展下载地址一: http://windows.php.net/downloads/pecl/releases/imagick/下载地址二: https://pecl.php.net/pack ...

  2. Sliding Window POJ - 2823 单调队列模板题

    Sliding Window POJ - 2823 单调队列模板题 题意 给出一个数列 并且给出一个数m 问每个连续的m中的最小\最大值是多少,并输出 思路 使用单调队列来写,拿最小值来举例 要求区间 ...

  3. angular 读写电脑本地文件

    angular 读写本地电脑文件 angular将数据写进到电脑文件 在前端写一个按钮,然后点击按钮的时候在本地电脑保存一个text文件. 这时候我们需要用到一个angular的插件,叫做" ...

  4. ansible笔记(5):常用模块之命令类模块

    1.command模块 它的作用是帮助我们在远程主机上执行命令. [注意]使用command模块在远程主机中执行命令时,不会经过远程主机的shell处理,在使用command模块时,如果需要执行的命令 ...

  5. Light Up Your Business Promotions With LED Keychain

    Imagine you want to insert the car key into the keyhole in the dark. What would you do? You will def ...

  6. 每天进步一点点------Allegro 原理图到PCB网表导入

  7. 每天进步一点点------ORCAD Capture CIS

    ORCAD Capture CIS 一.建工程及设置 1.选主菜单 file->new->project ;弹出 project wizard 对话框,取名Myproject : Mypr ...

  8. hadoop学习笔记(九):mr2HA高可用环境搭建及处步使用

    本文原创,如需转载,请注明原文链接和作者 所用到的命令的总结: yarn:启动start-yarn.sh   停止stop-yarn.sh zk :zkServer.start ;:zkServer. ...

  9. .net core 框架调用顺序

    API -> AppSrv -> IRepository -> Repository ->

  10. pycharm中的搜索快捷键