集成路由和桥接IRB详解Word格式文档下载.docx
《集成路由和桥接IRB详解Word格式文档下载.docx》由会员分享,可在线阅读,更多相关《集成路由和桥接IRB详解Word格式文档下载.docx(16页珍藏版)》请在冰点文库上搜索。
switch#configureterminal
switch(config)#vlan2
switch(config)#interfacefastethernet0/1
switch(config-if)#switchportaccesssvlan2
switch(config-if)#encapsulationisl
R1
router#configureterminal
router(config)#interfacefastethernet0/0
router(config-if)#noshut
router(config-if)#interfacefastethernet0/0.1
router(config-subif)#encapsulationdot1q1
router(config-subif)#bridge-group1
router(config-subif)#interfacefastethernet0/0.2
router(config-subif)#encapsultiondot1q2
router(config-subif)#bridge-group2
router(config-subif)#exit
router(config-if)#interfacefastetherent0/1
router(config-if)#interfacefastethernet0/1.1
router(config-subif)#encapsulationisl1
router(config-subif)#brdigegroup1
router(config-subif)#interfacefastethernet0/1.2
router(config-subif)#encapsulationisl2
router(config-subif)#brdigegroup2
router(config-if)#exit
router(config)#bridgeirb
router(config)#bridge1protocolieee
router(config)#bridge2protocolieee
router(config)#bridge1routeip
router(config)#brdige2routeip
router(config)#intbvi1
router(config-if)#ipadd192.168.1.254255.255.255.0
router(config-if)#intbvi2
router(config-if)#ipadd192.168.2.254255.255.255.0
SectionIII.实验-子接口桥接
实验中的IP划分:
SW1VLAN2
192.168.2.250
VLAN3
192.168.3.250
SW2VLAN2
192.168.2.249
192.168.3.249
R1
bvi
1
192.168.2.251
bvi
2
192.168.3.251
R2
192.168.2.248
192.168.3.248
HSRP2
192.168.2.254
HSRP3
192.168.3.254
一。
实验目的
了解桥接的作用:
桥接”,是指依据OSI网络模型的链路层的地址,对网络数据包进行转发的过程。
当路由器配置了桥接选项后,会处理所有接口上的所有的数据帧,并实时调查每个主机的位置。
若在某个接口上收入一个帧,就会在一个桥接内置入一个条目,列出发送数据的主机和接收到数据帧的接口MAC地址,这样路由表就被不断地在通信中完善起来。
参考:
二。
实验内容
1。
在实验中,我们使用的是二层交换机,通过路由器来实现VLAN之间的路由
在E0/0E0/1下面划分子接口
inte0/0.1
inte0/0.2
endot1q2
endot1q3
分别封装VLAN2VLAN3
2。
因为在同一物理接口不能配置同一网段的IP地址,我们要通过桥接组来实现子接口之间的桥接
inte0/1.1
bridge-group1
bridge-group2
建立两个桥接组
3。
这只是简单的两层桥接,要实现三层桥接,我们要给桥接组配置IP地址
intbvi1
intbvi2
ipadd192.168.2.1255.255.255.0
ipadd192.168.3.1255.255.255.0
两个组分别使用VLAN2与VLAN3的网段,这样可以实现VLAN之间的路由
4。
为了完成VLAN之间的路由,所有橙色线路的端口为trunk
switchportmodetruck
switchporttruckendo
5。
所有PC接入端号使作protfast端口,接到收敛速成度
spanning-streeprotfast
6。
为了终端PC的安全,我们可以采用热备份协议,实现网关冗余
R1:
intbri2
standy1ip192.168.2.254
standy2ip192.168.3.254
standy1pree
standy2pree
开启抢占
R2:
intbvi1
standy1pri50让R1成为VLAN1主网关
standy2pri200让R2成为VLAN2的主网关
在第6中,我们分别分R1与R2成为VLAN1与VLAN2的主,彼此之间成为备份,使得网络更可靠
7。
ISP与本地路由器之间采用路由协议,可以实现负载均衡
在实验中用到如下命令:
bridge1protocolieee封装协议
birdge1routeip
支持IP路由
birdgeirb
将桥接接口集成路由功能
实验配置
这个实验中,主要是难点是子接口的路由桥接,但这个设计早以最淘汰了,我们可以在三层路由来实现上面的功能。
另一个知识点就是为这个VLAN建立备份网关,我们可以采用HSRPVRRPGLBP协议来实现
三.配置
R1-up#shrun
Buildingconfiguration...
Currentconfiguration:
1119bytes
!
version12.3
servicetimestampsdebugdatetimemsec
servicetimestampslogdatetimemsec
noservicepassword-encryption
hostnameR1-up
boot-start-marker
boot-end-marker
noaaanew-model
ipsubnet-zero
ipcef
bridgeirb
interfaceLoopback1
ipaddress1.1.1.1255.255.255.0
interfaceEthernet0/0
noipaddress
half-duplex
interfaceEthernet0/0.1
encapsulationdot1Q2
bridge-group1
interfaceEthernet0/0.2
encapsulationdot1Q3
bridge-group2
interfaceSerial0/0
ipaddress10.1.1.1255.255.255.0
nofair-queue
interfaceEthernet0/1
interfaceEthernet0/1.1
interfaceEthernet0/1.2
interfaceBVI1
ipaddress192.168.2.251255.255.255.0
standby1ip192.168.2.1
standby1preempt
interfaceBVI2
ipaddress192.168.3.251255.255.255.0
standby2ip192.168.3.1
iphttpserver
ipclassless
bridge1protocolieee
bridge1routeip
bridge2protocolieee
bridge2routeip
linecon0
lineaux0
linevty04
login
end
R2-down#shrun
1173bytes
hostnameR2-down
ipauditpomax-events100
shutdown
ipaddress192.168.2.248255.255.255.0
standby1priority50
//桥接组1并启用了HSRP
ipaddress192.168.3.248255.255.255.0
standby2priority200
standby2preempt
//桥接组2并启用了HSRP
noiphttpsecure-server
Sw1-up#shrun
Currentconfiguration:
version12.0
noservicepad
servicetimestampsdebuguptime
servicetimestampsloguptime
hostnameSw1-up
interfaceFastEthernet0/1
switchporttrunkencapsulationdot1q
switchportmodetrunk
interfaceFastEthernet0/2
interfaceFastEthernet0/3
interfaceFastEthernet0/4
interfaceFastEthernet0/5
interfaceFastEthernet0/6
interfaceFastEthernet0/7
interfaceFastEthernet0/8
interfaceFastEthernet0/9
interfaceFastEthernet0/10
switchportaccessvlan
2
spanning-treeportfast
interfaceFastEthernet0/11
interfaceFastEthernet0/12
interfaceVLAN1
noipdirected-broadcast
noiproute-cache
interfaceVLAN2
ipaddress192.168.2.250255.255.255.0
interfaceVLAN3
ipaddress192.168.3.250255.255.255.0
transportinputnone
stopbits1
linevty515
Sw1-up#
Sw2-down#shrun
hostnameSw2-down
ipaddress192.168.2.249255.255.255.0
ipaddress192.168.3.249255.255.255.0
Sw2-down#
欢迎您的下载,资料仅供参考!