CCNP-8 OSPF试验4(BSCI)

CCNP-8 OSPF试验4

试验拓扑:

实验要求: R1 R2 R3 通过 FR 相连,形成 hub and spoke 网络拓扑, R1 hub 路由器, R2 R3 sopke 路由器,要求 R1 R2 R3 全部采用点对点子接口,全部起 OSPF
试验目的:掌握 OSPF NBMA 环境下采用点对点子接口的配置。

试验配置:
R1
R1(config)#int s1/0
R1(config-if)#enca frame-relay
R1(config-if)#no shu
R1(config-if)#exit
R1(config)#int s1/0.1 point-to-point  
R1(config-subif)#ip add 199.99.1.1 255.255.255.0
R1(config-subif)#frame-relay interface-dlci 301
R1(config-fr-dlci)#exit
R1(config-subif)#no shu
R1(config-subif)#exit
R1(config)#int s1/0.2 point-to-point
R1(config-subif)#ip add 199.99.2.1 255.255.255.0
R1(config-subif)#frame-relay interface-dlci 302
R1(config-fr-dlci)#exit
R1(config-subif)#no shu
R1(config-subif)#exit
 
R2
R2(config)#int s1/0
R2(config-if)#enca frame-relay
R2(config-if)#no shu
R2(config-if)#exit
R2(config)#int s1/0.1 point-to-point
R2(config-subif)#ip add 199.99.1.2 255.255.255.0
R2(config-subif)#frame-relay interface-dlci 103
R2(config-fr-dlci)#exit
R2(config-subif)#no shu
R2(config-subif)#exit
 
R3
R3(config)#int s1/0
R3(config-if)#enca frame-relay
R3(config-if)#no shu
R3(config-if)#exit
R3(config)#int s1/0.1 point-to-point 
R3(config-subif)#ip add 199.99.2.2 255.255.255.0
R3(config-subif)#frame-relay interface-dlci 203
R3(config-fr-dlci)#exit
R3(config-subif)#no shu
R3(config-subif)#exit
基本的链路层配置完成,先测试一下连通性:
R1#ping 199.99.1.2
 
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 199.99.1.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 144/204/240 ms
R1#ping 199.99.2.2
 
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 199.99.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 240/253/264 ms
 
OK ,都通了,下面开始配置 OSPF
R1(config)#int loop0
R1(config-if)#ip add 100.100.100.100 255.255.255.0
R1(config-if)#ip ospf network point-to-point
R1(config-if)#exit
R1(config)#router ospf 100
R1(config-router)#router-id 100.100.100.100
R1(config-router)#network 199.99.1.0 0.0.0 .255 area 0
R1(config-router)#network 199.99.2.0 0.0.0 .255 area 0
R1(config-router)#exit
 
R2(config)#int loop0
R2(config-if)#ip add 2.2.2 .2 255.255.255.0
R2(config-if)#ip ospf network point-to-point
R2(config-if)#exit
R2(config)#router ospf 100
R2(config-router)#router-id 2.2.2 .2
R2(config-router)#network 199.99.1.0 0.0.0 .255 area 0
 
R3(config)#int loop0
R3(config-if)#ip add 3.3.3 .3 255.255.255.0
R3(config-if)#ip ospf network point-to-point
R3(config-if)#exit
R3(config)#router ospf 100
R3(config-router)#router-id 3.3.3 .3
R3(config-router)#network 199.99.2.0 0.0.0 .255 area 0
R3(config-router)#exit
好了,我们先等一会,看看在点对点环境下邻居关系是否会自动建立,不用说当让会自动建立邻居关系了,下面查看一下各自的路由表:
R1#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF , IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route
 
Gateway of last resort is not set
 
     100.0.0.0/24 is subnetted, 1 subnets
C       100.100.100.0 is directly connected, Loopback0
C    199.99.2.0/24 is directly connected, Serial1/0.2
C    199.99.1.0/24 is directly connected, Serial1/0.1
 
R2#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF , IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route
 
Gateway of last resort is not set
 
     2.0.0 .0/24 is subnetted, 1 subnets
C       2.2.2 .0 is directly connected, Loopback0
O    199.99.2.0/24 [110/128] via 199.99.1.1, 00:00:05, Serial1/0.1
C    199.99.1.0/24 is directly connected, Serial1/0.1
 
R3#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF , IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route
 
Gateway of last resort is not set
 
     3.0.0 .0/24 is subnetted, 1 subnets
C       3.3.3 .0 is directly connected, Loopback0
C    199.99.2.0/24 is directly connected, Serial1/0.1
O    199.99.1.0/24 [110/128] via 199.99.2.1, 00:00:00, Serial1/0.1
 
在两台 spoke 路由器上都看到了 ”O” 路由,证明 OSPF 路由协议运行正常,下面 show ip ospf interface 查看一下接口的 OSPF 运行情况:
R1#show ip ospf interface
Serial1/0.2 is up, line protocol is up
  Internet Address 199.99.2.1/24, Area 0
  Process ID 100, Router ID 100.100.100.100, Network Type POINT_TO_POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    oob-resync timeout 40
    Hello due in 00:00:03
  Supports Link-local Signaling (LLS)
  Index 2/2, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 1, Adjacent neighbor count is 1
    Adjacent with neighbor 3.3.3 .3
  Suppress hello for 0 neighbor(s)
Serial1/0.1 is up, line protocol is up
  Internet Address 199.99.1.1/24, Area 0
  Process ID 100, Router ID 100.100.100.100, Network Type POINT_TO_POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    oob-resync timeout 40
    Hello due in 00:00:03
  Supports Link-local Signaling (LLS)
  Index 1/1, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 4 msec
  Neighbor Count is 1, Adjacent neighbor count is 1
    Adjacent with neighbor 2.2.2 .2
  Suppress hello for 0 neighbor(s)
 
R2#show ip ospf interface
Serial1/0.1 is up, line protocol is up
  Internet Address 199.99.1.2/24, Area 0
  Process ID 100, Router ID 2.2.2 .2, Network Type POINT_TO_POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    oob-resync timeout 40
    Hello due in 00:00:08
  Supports Link-local Signaling (LLS)
  Index 1/1, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 1, Adjacent neighbor count is 1
    Adjacent with neighbor 100.100.100.100
  Suppress hello for 0 neighbor(s)
 
R3#show ip ospf interface
Serial1/0.1 is up, line protocol is up
  Internet Address 199.99.2.2/24, Area 0
  Process ID 100, Router ID 3.3.3 .3, Network Type POINT_TO_POINT, Cost: 64
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    oob-resync timeout 40
    Hello due in 00:00:07
  Supports Link-local Signaling (LLS)
  Index 1/1, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 1, Adjacent neighbor count is 1
    Adjacent with neighbor 100.100.100.100
  Suppress hello for 0 neighbor(s)
上面的输出包含了很多重要的信息:点对电子接口的网络类型为 POINT_TO_POINT ,默认的 HELLO 时间间隔为 10 秒,等待时间和死亡时间为 HELLO 时间间隔的 4 40 秒,各自邻居的 router-id 等等 ,要看懂上面的每一条信息,下面查看邻居表:
R1#show ip ospf neighbor
 
Neighbor ID     Pri   State           Dead Time   Address         Interface
3.3.3 .3           0   FULL/  -        00:00:30    199.99.2.2      Serial1/0.2
2.2.2 .2           0   FULL/  -        00:00:39    199.99.1.2      Serial1/0.1
 
R2#show ip ospf neighbor
 
Neighbor ID     Pri   State           Dead Time   Address         Interface
100.100.100.100   0   FULL/  -        00:00:30    199.99.1.1      Serial1/0.1
 
R3#show ip ospf neighbor
 
Neighbor ID     Pri   State           Dead Time   Address         Interface
100.100.100.100   0   FULL/  -        00:00:38    199.99.2.1      Serial1/0.1
 
通过邻居表和我们之前的配置可以知道 NBMA 点对点子接口的环境下,邻居关系是自动建立的,无需手动添加,并且是没有 DR/BDR 选举存在。

实验总结:掌握在 NBMA 点对点子接口环境下配置 OSPF 的方法,并且知道在 NBMA 点对点环境下邻居关系是自动建立的,并且没有 DR/BDR 选举,默认得 HELLO 时间间隔为 10 秒,等待时间和死亡时间为 HELLO 时间间隔的 4 40 秒。

你可能感兴趣的:(职场,休闲,OSPF试验4,CCNP-8)