示例图:

其实说白了就是做线路冗余,达到热备切换。

组网需求:

楼层1和楼层2分别通过两条线路做冗余接入交换机(本示例只考虑vrrp,暂不考虑其他方面)。当其中一段链路故障时,能通过另外一条链路传输。

配置信息:

<lsw9>dis cu

#

sysname lsw9

#

vlan batch 10 20

#

stp mode stp

#

interface Ethernet0/0/2

 port link-type access

 port default vlan 10

#

interface Ethernet0/0/3

 port link-type access

 port default vlan 20

#

interface GigabitEthernet0/0/1

 port link-type trunk

 port trunk allow-pass vlan 10 20

#

interface GigabitEthernet0/0/2

 port link-type trunk

 port trunk allow-pass vlan 10 20

 stp instance 0 cost 200000000

#

return

<lsw9>

--------------------------

<lsw11>dis cu

#

sysname lsw11

#

vlan batch 30

#

stp mode stp

#

interface Ethernet0/0/2

 port link-type access

 port default vlan 30

#

interface Ethernet0/0/3

 port link-type access

 port default vlan 30

#

interface GigabitEthernet0/0/1

 port link-type trunk

 port trunk allow-pass vlan 30

 stp instance 0 cost 200000000

#

interface GigabitEthernet0/0/2

 port link-type trunk

 port trunk allow-pass vlan 30

#

return

<lsw11>

-------------------------

<lsw7>dis cu

#

sysname lsw7

#

vlan batch 10 20 30 100

#

stp mode stp

#

interface Vlanif1

#

interface Vlanif10

 description to 1 L

 ip address 10.155.10.254 255.255.255.0

 vrrp vrid 1 virtual-ip 10.155.10.252

 vrrp vrid 1 priority 120

 vrrp vrid 1 preempt-mode timer delay 20

#

interface Vlanif20

 ip address 10.155.20.254 255.255.255.0

 vrrp vrid 1 virtual-ip 10.155.20.252

 vrrp vrid 1 priority 120

 vrrp vrid 1 preempt-mode timer delay 20

#

interface Vlanif30

 description to 5 L

 ip address 10.156.40.254 255.255.255.0

 ip address 10.156.30.254 255.255.255.0 sub

 vrrp vrid 1 virtual-ip 10.156.30.252

 vrrp vrid 2 virtual-ip 10.156.40.252

 vrrp vrid 2 priority 120

 vrrp vrid 2 preempt-mode timer delay 20

#

interface Vlanif100

 ip address 10.10.10.1 255.255.255.0

#

interface MEth0/0/1

#

interface GigabitEthernet0/0/1

 port link-type access

 port default vlan 100

#

interface GigabitEthernet0/0/11

 port link-type trunk

 port trunk pvid vlan 100

 port trunk allow-pass vlan 2 to 4094

#

interface GigabitEthernet0/0/21

 port link-type trunk

 port trunk allow-pass vlan 30

#

ospf 1

 area 0.0.0.0

  network 10.10.10.0 0.0.0.255

  network 10.155.0.0 0.0.255.255

  network 10.156.0.0 0.0.255.255

#

return

--------------------------------------

<lsw8>dis cu

#

sysname lsw8

#

vlan batch 10 20 30 200

#

stp mode stp

#

interface Vlanif1

#

interface Vlanif10

 description to 1 L

 ip address 10.155.10.253 255.255.255.0

 vrrp vrid 1 virtual-ip 10.155.10.252

#

interface Vlanif20

 description to 1 L

 ip address 10.155.20.253 255.255.255.0

 vrrp vrid 1 virtual-ip 10.155.20.252

#

interface Vlanif30

 description to 5 L

 ip address 10.156.30.253 255.255.255.0

 ip address 10.156.40.253 255.255.255.0 sub

 vrrp vrid 1 virtual-ip 10.156.30.252

 vrrp vrid 1 priority 120

 vrrp vrid 1 preempt-mode timer delay 20

 vrrp vrid 2 virtual-ip 10.156.40.252

#

interface Vlanif200

 ip address 10.10.20.1 255.255.255.0

#

interface MEth0/0/1

#

interface GigabitEthernet0/0/1

#

interface GigabitEthernet0/0/2

 port link-type trunk

 port trunk allow-pass vlan 10 20

#

interface GigabitEthernet0/0/12

 port hybrid pvid vlan 200

 port hybrid tagged vlan 1 to 4094

#

interface GigabitEthernet0/0/22

 port link-type trunk

 port trunk allow-pass vlan 30

#

ospf 1

 area 0.0.0.0

  network 10.155.0.0 0.0.255.255

  network 10.156.0.0 0.0.255.255

  network 10.10.20.0 0.0.0.255

#

return

<lsw8>

-----------------

<R4>dis cu

#

sysname R4

#

stp instance 0 root primary

stp enable

#

interface GigabitEthernet0/0/1

 ip address 10.10.10.254 255.255.255.0

 stp enable

#

interface GigabitEthernet0/0/2

 ip address 10.10.20.254 255.255.255.0

 stp enable

#

interface GigabitEthernet0/0/3

 ip address 61.128.128.6 255.255.255.0

#

return

<R4>

参考:

http://www.023wg.com/kkxpz/85.html(以上内容转自此篇文章)

华为交换机VRRP配置实例收集(转)的更多相关文章

  1. 华为交换机MSTP+VRRP配置实例说明文档

    华为交换机MSTP+VRRP配置实例说明文档 拓扑图 IP地址规划表 设备名称 设备接口 对端设备 对端接口 VLAN VLAN /接口地址 备注 SW0 GE0/0/23 SW2 GE0/0/23 ...

  2. 华为交换机sflow配置

    华为交换机sflow功能配置 1.配置交换机的sflow流发送 [系统视图]sflow agen ip  x.x.x.x                 设置sflow输出源 [系统视图]sflow ...

  3. 华为交换机-SNMP配置

    1.1     SNMP基础配置 <switch>system-view 进入交换机的配置模式 [switch]snmp-agent 使能snmp服务 [switch]snmp-agent ...

  4. 华为交换机VRRP 综合配置示例

    组网需求: 楼层1和楼层2分别通过两条线路做冗余接入交换机(本示例只考虑vrrp,暂不考虑其他方面).当其中一段链路故障时,能通过另外一条链路传输. 配置信息: <lsw9>dis cu ...

  5. 华为交换机netstream配置

    1.配置交换机的流发送 [系统视图]ip netstream timeout active 100         流活跃时间 [系统视图]ip netstream timeout inactive ...

  6. 华为交换机telnet配置

    1.在路由器上和交换机相连的借口上配置一个IP地址:比如192.168.1.1 24 2.在交换机上配置如下:<switch>system-view[switch]vlan 10[swit ...

  7. 华为交换机如何配置SSH远程登录,一分钟秒学会

    从事网络运维工作的小伙伴们都知道,在交换机正式上线时,必须完成配置SSH远程登录,这样做目的是为了日后,维护方便,不需要每次登录设备都要跑到机房,这样既不现实,又费事. 远程登录方式 目前网络设备中主 ...

  8. 华为交换机SSH配置

    设备:S5700 一.在本地设备服务端生成秘钥对 [Huawei]rsa local-key-pair create 二.配置VTY [Huawei]user-interface vty 0 4进入虚 ...

  9. MSTP+ VRRP 交换机的 配置过程

    配置思路采用以下思路配置: 1.在处于环形网络中的交换设备上配置MSTP基本功能,包括:a.配置MST域并创建多实例,配置VLAN2映射到MSTI1,VLAN3映射到MSTI2,实现流量的负载分担. ...

随机推荐

  1. git 学习小记之记住https方式推送密码

    昨天刚刚学了点git基础操作,但是不幸的是Git@OSC给出公告说尽量使用 https 进行操作.可是在用 https 进行 push 时,都需要输入帐号和密码. 各种百度谷歌之后在Git@OSC官网 ...

  2. LEARN HOW TO HACK

    出处:https://www.hackerone.com/hacker101 什么是HACKER101? https://hacker101.com/Hacker101是一个视频,资源和实践活动的集合 ...

  3. python3解析库pyquery

    pyquery是一个类似jquery的python库,它实现能够在xml文档中进行jQuery查询,pyquery使用lxml解析器进行快速在xml和html文档上操作,它提供了和jQuery类似的语 ...

  4. ZeroMQ安装说明

    ZeroMQ安装说明 1.   安装 1.1.Linux zmq安装 安装过程参考地址:http://zeromq.org/intro:get-the-software的说明 安装步骤如下(在安装时参 ...

  5. fastdfs:安装nginx

    #安装依赖 yum -y install gcc yum -y install gcc-c++ yum -y install zlib-devel yum -y install pcre-devel ...

  6. ipsec-tools安装教程

    ipsec-tools最新版本为0.8.2,此处以0.7.3版本为例说明安装和使用过程.可参考ipsec-howto. 安装步骤 ipsec-tools依赖于linux2.6版本内核,在安装ipsec ...

  7. jexus配置支持Owin

    vi打开配置文件,加一行 OwinMain=xxx.dll ###################### # Web Site: Default ########################### ...

  8. Java学习--编译器javac

    Java的源程序为.java文件, 编译后生成.class文件(字节码文件); javac(java compiler的简写)是java语言的编译器. Hello.java public class ...

  9. 2011TG初赛

    一.单项选择题(共20题,每题1.5分,共计30分,每题有且仅有一个正确选项.) 1. 在二进制下,1011001+( )=1100110. A.1011 B.1101 C.1010 D.1111 B ...

  10. TinyHttpd代码解析

    十一假期,闲来无事.看了几个C语言开源代码.http://www.cnblogs.com/TinyHttpd 这里本来想解析一下TinyHttpd的代码,但是在网上一搜,发现前辈们已经做的很好了.这里 ...