ospf 互备分流实验

要求:办公挂了不走生产 走路由器6(公共线路),生产挂了走办公

当生产线路挂了:生产走办公线路             当办公线路挂掉时,走公共线路

R1

!
interface Loopback0
 ip address 1.1.1.1 255.255.255.255
!
interface Loopback1
 ip address 1.1.1.2 255.255.255.255

interface FastEthernet0/0.1
 encapsulation dot1Q 1 native
 ip address 14.1.1.1 255.255.255.0
!
interface FastEthernet0/0.2
 encapsulation dot1Q 2
 ip address 14.2.2.1 255.255.255.0
!
interface FastEthernet1/0.1
 encapsulation dot1Q 1 native
 ip address 12.1.1.1 255.255.255.0
 ip ospf cost 2
!
interface FastEthernet1/0.2
 encapsulation dot1Q 2
 ip address 12.2.2.1 255.255.255.0
 ip ospf cost 2
!
interface Serial3/0
 ip address 12.0.0.1 255.255.255.0
 serial restart-delay 0
!
interface Serial3/1
 ip address 13.0.0.1 255.255.255.0
 ip ospf cost 1
 serial restart-delay 0

router ospf 1
 router-id 1.1.1.1
 log-adjacency-changes
 network 1.1.1.1 0.0.0.0 area 1
 network 1.1.1.2 0.0.0.0 area 2
 network 12.1.1.0 0.0.0.255 area 1
 network 12.2.2.0 0.0.0.255 area 2
 network 13.0.0.0 0.0.0.255 area 1
 network 14.1.1.0 0.0.0.255 area 1
 network 14.2.2.0 0.0.0.255 area 2
!

R2

interface Loopback0
 ip address 2.2.2.1 255.255.255.255
!
interface Loopback1
 ip address 2.2.2.2 255.255.255.255
!
!
interface FastEthernet0/0.1
 encapsulation dot1Q 1 native
 ip address 23.1.1.1 255.255.255.0
!
interface FastEthernet0/0.2
 encapsulation dot1Q 2
 ip address 23.2.2.1 255.255.255.0
!
!
interface FastEthernet1/0.1
 encapsulation dot1Q 1 native
 ip address 12.1.1.2 255.255.255.0
 ip ospf cost 2
!
interface FastEthernet1/0.2
 encapsulation dot1Q 2
 ip address 12.2.2.2 255.255.255.0
 ip ospf cost 2
!
!
interface Serial3/0
 ip address 12.0.0.2 255.255.255.0
 serial restart-delay 0
!
interface Serial3/1
 ip address 24.0.0.1 255.255.255.0
 ip ospf cost 1
 serial restart-delay 0
!
router ospf 1
 router-id 2.2.2.2
 log-adjacency-changes
 network 2.2.2.1 0.0.0.0 area 1
 network 2.2.2.2 0.0.0.0 area 2
 network 12.1.1.0 0.0.0.255 area 1
 network 12.2.2.0 0.0.0.255 area 2
 network 23.1.1.0 0.0.0.255 area 1
 network 23.2.2.0 0.0.0.255 area 2
 network 24.0.0.0 0.0.0.255 area 2
!

R3

interface FastEthernet0/0.1
 encapsulation dot1Q 1 native
 ip address 35.1.1.1 255.255.255.0
!
interface FastEthernet0/0.2
 encapsulation dot1Q 2
 ip address 35.2.2.1 255.255.255.0
 ip ospf cost 2
!
interface FastEthernet1/0
 ip address 36.0.0.1 255.255.255.0
 ip ospf 1 area 2
 duplex auto
 speed auto
!
interface FastEthernet1/1.1
 encapsulation dot1Q 1 native
 ip address 23.1.1.2 255.255.255.0
!
interface FastEthernet1/1.2
 encapsulation dot1Q 2
 ip address 23.2.2.2 255.255.255.0
!
!
interface Serial3/0
 ip address 13.0.0.2 255.255.255.0
 ip ospf cost 1
 serial restart-delay 0
!
interface Serial3/1
 ip address 34.0.0.1 255.255.255.0
 ip ospf cost 1
 serial restart-delay 0
!
router ospf 1
 router-id 3.3.3.3
 log-adjacency-changes
 network 13.0.0.0 0.0.0.255 area 1
 network 23.1.1.0 0.0.0.255 area 1
 network 23.2.2.0 0.0.0.255 area 2
 network 34.0.0.0 0.0.0.255 area 0
 network 35.1.1.0 0.0.0.255 area 1
 network 35.2.2.0 0.0.0.255 area 2
!

R4

interface FastEthernet0/0.1
 encapsulation dot1Q 1 native
 ip address 45.1.1.1 255.255.255.0
 ip ospf cost 2
!
interface FastEthernet0/0.2
 encapsulation dot1Q 2
 ip address 45.2.2.1 255.255.255.0
!
interface FastEthernet1/0
 ip address 46.0.0.1 255.255.255.0
 ip ospf 1 area 2
 duplex auto
 speed auto
!
!
interface FastEthernet1/1.1
 encapsulation dot1Q 1 native
 ip address 14.1.1.2 255.255.255.0
!
interface FastEthernet1/1.2
 encapsulation dot1Q 2
 ip address 14.2.2.2 255.255.255.0
!
!
interface Serial3/0
 ip address 24.0.0.2 255.255.255.0
 ip ospf cost 1
 serial restart-delay 0
!
interface Serial3/1
 ip address 34.0.0.2 255.255.255.0
 ip ospf cost 1
 serial restart-delay 0
!
router ospf 1
 router-id 4.4.4.4
 log-adjacency-changes
 network 14.1.1.0 0.0.0.255 area 1
 network 14.2.2.0 0.0.0.255 area 2
 network 24.0.0.0 0.0.0.255 area 2
 network 34.0.0.0 0.0.0.255 area 0
 network 45.1.1.0 0.0.0.255 area 1
 network 45.2.2.0 0.0.0.255 area 2

R5

interface Loopback0
 ip address 5.5.5.1 255.255.255.255
!
interface Loopback1
 ip address 5.5.5.2 255.255.255.255
!
!
interface FastEthernet0/0.1
 encapsulation dot1Q 1 native
 ip address 45.1.1.2 255.255.255.0
 ip ospf cost 2
!
interface FastEthernet0/0.2
 encapsulation dot1Q 2
 ip address 45.2.2.2 255.255.255.0
!
!
interface FastEthernet1/0.1
 encapsulation dot1Q 1 native
 ip address 35.1.1.2 255.255.255.0
!
interface FastEthernet1/0.2
 encapsulation dot1Q 2
 ip address 35.2.2.2 255.255.255.0
 ip ospf cost 65535
!
interface FastEthernet1/1
 ip address 56.0.0.1 255.255.255.0
 ip ospf 1 area 2
 duplex auto
 speed auto
!

router ospf 1
 router-id 5.5.5.5
 log-adjacency-changes
 network 5.5.5.1 0.0.0.0 area 1
 network 5.5.5.2 0.0.0.0 area 2
 network 35.1.1.0 0.0.0.255 area 1
 network 35.2.2.0 0.0.0.255 area 2
 network 45.1.1.0 0.0.0.255 area 1
 network 45.2.2.0 0.0.0.255 area 2

R6

interface FastEthernet0/0
 ip address 36.0.0.2 255.255.255.0
 ip ospf 1 area 2
 duplex half
!
interface FastEthernet1/0
 ip address 46.0.0.2 255.255.255.0
 ip ospf 1 area 2
 duplex auto
 speed auto
!
interface FastEthernet1/1
 ip address 56.0.0.2 255.255.255.0
 ip ospf 1 area 2
 duplex auto
 speed auto
!
router ospf 1
 router-id 6.6.6.6
 log-adjacency-changes

 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值