onethink做移动网站,淘宝上开网店的流程,做那个男女的视频网站,自己做个微信小程序文章目录 华为eNSP配置专题-VRRP的配置0、参考文档1、前置环境1.1、宿主机1.2、eNSP模拟器 2、基本环境搭建2.1、基本终端构成和连接 2.VRRP的配置2.1、PC1的配置2.2、接入交换机acsw的配置2.3、核心交换机coresw1的配置2.4、核心交换机coresw2的配置2.5、配置VRRP2.6、配置出口… 文章目录 华为eNSP配置专题-VRRP的配置0、参考文档1、前置环境1.1、宿主机1.2、eNSP模拟器 2、基本环境搭建2.1、基本终端构成和连接 2.VRRP的配置2.1、PC1的配置2.2、接入交换机acsw的配置2.3、核心交换机coresw1的配置2.4、核心交换机coresw2的配置2.5、配置VRRP2.6、配置出口路由器AR12.7、配置模拟互联网路由器AR12.8、配置PC1可以访问模拟互联网路由器 3、其他场景3.1、VRRP优先级调整3.2、接口跟踪 华为eNSP配置专题-VRRP的配置
0、参考文档
1、前置环境
1.1、宿主机
笔记本电脑配置如下Windows10企业版32GB内存
1.2、eNSP模拟器
eNSP1.3.00
2、基本环境搭建
2.1、基本终端构成和连接
0、总体拓扑如下 1、1台PC。 2、3台交换机型号为S5700。其中1台作为接入交换机。另外2台作为核心交换机配置VRRP。 3、2台路由器型号为AR2220。其中一台为作为内网的出口路由器另外一台路由器模拟互联网 4、开启设备。
2.VRRP的配置
2.1、PC1的配置
1、PC1配置静态IP和网关如下 IP192.168.10.1 掩码255.255.255.0 网关192.168.10.254
2.2、接入交换机acsw的配置
1、右击接入交换机acsw-》点击“CLI”进入系统模式改名为acsw同时也关闭信息中心的通知消息。
Huaweisystem-view
Enter system view, return user view with CtrlZ.
[Huawei]sysname acsw
[acsw]undo info-center enable
Info: Information center is disabled.2、创建vlan 10
[acsw]vlan 10
[acsw-vlan10]quit3、配置三个接口1个access口2个trunk口
[acsw]interface GigabitEthernet 0/0/3
[acsw-GigabitEthernet0/0/3]port link-type access
[acsw-GigabitEthernet0/0/3]port default vlan 10
[acsw-GigabitEthernet0/0/3]quit
[acsw]interface GigabitEthernet 0/0/1
[acsw-GigabitEthernet0/0/1]port link-type trunk
[acsw-GigabitEthernet0/0/1]port trunk allow-pass vlan all
[acsw-GigabitEthernet0/0/1]quit
[acsw]interface GigabitEthernet 0/0/2
[acsw-GigabitEthernet0/0/2]port link-type trunk
[acsw-GigabitEthernet0/0/2]port trunk allow-pass vlan all2.3、核心交换机coresw1的配置
1、右击接入交换机acsw-》点击“CLI”进入系统模式改名同时也关闭信息中心的通知消息。
Huaweisystem-view
Enter system view, return user view with CtrlZ.
[Huawei]sysname coresw1
[coresw1]undo info-center enable
Info: Information center is disabled.2、生成两个vlanvlan10用于下联vlan100用于上联
[coresw1]vlan 10
[coresw1-vlan10]vlan 1003、给三个接口配置两个trunk口一个access口用于上联
[coresw1]interface GigabitEthernet 0/0/1
[coresw1-GigabitEthernet0/0/1]port link-type trunk
[coresw1-GigabitEthernet0/0/1]port trunk allow-pass vlan all
[coresw1-GigabitEthernet0/0/1]quit
[coresw1]interface GigabitEthernet 0/0/3
[coresw1-GigabitEthernet0/0/3]port link-type trunk
[coresw1-GigabitEthernet0/0/3]port trunk allow-pass vlan all
[coresw1-GigabitEthernet0/0/3]quit
[coresw1]interface GigabitEthernet 0/0/2
[coresw1-GigabitEthernet0/0/2]port link-type access
[coresw1-GigabitEthernet0/0/2]port default vlan 100
[coresw1-GigabitEthernet0/0/2]quit4、配置三层接口。
[coresw1]interface vlanif 10
[coresw1-Vlanif10]ip add 192.168.10.252 24
[coresw1-Vlanif10]quit
[coresw1]interface vlanif 100
[coresw1-Vlanif100]ip add 192.168.100.1 30
[coresw1-Vlanif100]quit2.4、核心交换机coresw2的配置
1、右击接入交换机acsw-》点击“CLI”进入系统模式改名同时也关闭信息中心的通知消息。
Huaweisystem-view
Enter system view, return user view with CtrlZ.
[Huawei]undo info-center enable
Info: Information center is disabled.
[Huawei]sysname coresw22、生成两个vlanvlan10用于下联vlan200用于上联
[coresw2]vlan 10
[coresw2-vlan10]vlan 2003、给三个接口配置两个trunk口一个access口用于上联
[coresw2-vlan200]interface GigabitEthernet 0/0/1
[coresw2-GigabitEthernet0/0/1]port link-type trunk
[coresw2-GigabitEthernet0/0/1]port trunk allow-pass vlan all
[coresw2-GigabitEthernet0/0/1]quit
[coresw2]interface GigabitEthernet 0/0/3
[coresw2-GigabitEthernet0/0/3]port link-type trunk
[coresw2-GigabitEthernet0/0/3]port trunk allow-pass vlan all
[coresw2-GigabitEthernet0/0/3]quit
[coresw2]interface GigabitEthernet 0/0/2
[coresw2-GigabitEthernet0/0/2]port link-type access
[coresw2-GigabitEthernet0/0/2]port default vlan 200
[coresw2-GigabitEthernet0/0/2]quit4、配置三层接口。
[coresw2]interface vlanif 10
[coresw2-Vlanif10]ip add 192.168.10.253 24
[coresw2-Vlanif10]quit
[coresw2]interface vlanif 200
[coresw2-Vlanif200]ip add 192.168.200.1 30
[coresw2-Vlanif200]quit5、到PC1上ping两个核心交换机发现可以通了
2.5、配置VRRP
1、在coresw1上作如下配置设置虚拟IP为192.168.10.254优先级为120默认优先级为100因此本交换机为主节点。设置为抢占模式抢占延时为20秒。
[coresw1]interface vlanif10
[coresw1-Vlanif10]vrrp vrid 10 virtual-ip 192.168.10.254
[coresw1-Vlanif10]vrrp vrid 10 priority 120
[coresw1-Vlanif10]vrrp vrid 10 preempt-mode timer delay 20
[coresw1-Vlanif10]display this
#
interface Vlanif10ip address 192.168.10.252 255.255.255.0vrrp vrid 10 virtual-ip 192.168.10.254vrrp vrid 10 priority 120vrrp vrid 10 preempt-mode timer delay 20
#
return2、在coresw2上作类似配置但不设置优先级默认为100。
[coresw2]interface vlanif 10
[coresw2-Vlanif10]vrrp vrid 10 virtual-ip 192.168.10.254
[coresw2-Vlanif10]quit3、在coresw1上通过display vrrp查看配置情况可以看到coresw1的状态为Master
4、在PC1上ping 192.168.10.254发现可以通了也就意味着VRRP配置成功
2.6、配置出口路由器AR1
1、右击AR1-》点击“CLI”进入系统模式改名同时也关闭信息中心的通知消息。
Huaweisystem-view
Enter system view, return user view with CtrlZ.
[Huawei]undo info-center enable
Info: Information center is disabled.
[Huawei]sysname AR12、配置三个接口的地址
[AR1]int g0/0/0
[AR1-GigabitEthernet0/0/0]ip add 100.1.1.2 30
[AR1-GigabitEthernet0/0/0]int g0/0/1
[AR1-GigabitEthernet0/0/1]ip add 192.168.100.2 24
[AR1-GigabitEthernet0/0/1]int g0/0/2
[AR1-GigabitEthernet0/0/2]ip add 192.168.200.2 242.7、配置模拟互联网路由器AR1
1、右击AR2-》点击“CLI”进入系统模式改名同时也关闭信息中心的通知消息。
Huaweisystem-view
Enter system view, return user view with CtrlZ.
[Huawei]undo info-center enable
Info: Information center is disabled.
[Huawei]sysname AR22、配置三个接口的地址
[AR2]int g0/0/0
[AR2-GigabitEthernet0/0/0]ip add 100.1.1.1 302.8、配置PC1可以访问模拟互联网路由器
1、在PC1上ping AR2发现ping不通因为PC1会把包交给默认网关coresw1但默认网关也就是核心路由器上并没有10网段的路由如下所示
2、在核心交换机1上配置默认路由指向出口路由器
[coresw1]ip route-static 0.0.0.0 0 192.168.100.23、在核心交换机2上配置默认路由指向出口路由器
[coresw2]ip route-static 0.0.0.0 0 192.168.200.24、这时发现仍然ping不通但是在AR2上抓包已经可以看到ICMP包主要是AR2上没有回程的路由。
5、在AR2上配置静态路由。
[AR2]ip route-static 192.168.10.0 255.255.255.0 100.1.1.26、这时发现仍然ping不通发现ICMP有回包了主要原因是AR1上也没有回程的路由。做如下配置即可
[AR1]ip route-static 192.168.10.0 24 192.168.100.1
[AR1]ip route-static 192.168.10.0 24 192.168.200.17、这时发现PC1可以ping通模拟互联网路由器了。
3、其他场景
3.1、VRRP优先级调整
1、在PC1上tracert可以发现是从左边的coresw1走的。
2、降低coresw1的VRRP的优先级
[coresw1]interface vlanif 10
[coresw1-Vlanif10]vrrp vrid 10 priority 903、此时再在PC1上tracert可以发现是从右边的coresw2走的。
4、在coresw1查看VRRP状态发现已经变成了BACKUP
3.2、接口跟踪
1、在coresw1恢复已有的优先级为120再跟踪接口g0/0/2即接到出口网关的接口
[coresw1]int Vlanif 10
[coresw1-Vlanif10]vrrp vrid 10 priority 120
[coresw1-Vlanif10]vrrp vrid 10 track interface g0/0/2 reduce 302、在PC1进行tracert查看发觉流量走的coresw1
3、在coresw1关闭它的g/0/0/2接口
[coresw1]int g0/0/2
[coresw1-GigabitEthernet0/0/2]shutdown4、在PC1进行tracert查看发觉流量已经改走coresw2
6、在coresw1查看VRRP状态发现已经变成了BACKUP