苏志辉技术博客

  IT博客 :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理 ::
  11 随笔 :: 5 文章 :: 1 评论 :: 0 Trackbacks

网络类型
1.Broadcast
2.NonBroadcast
3.Point-to-Multimpoint
4.Point-to-Multimpoint NonBroadcast
5.Point-to-Point
****************************************************
**OSPF网络类型   DR/BDR        手工邻居        HELLO        单播/组播 **
**   P2P                 ---            ---             10S             组   **
**   P2MP               ---            ---             30S            单/组 **
**   NBMA                √             √              30S             单  **
**   Broadcast          √             ---            10S             组  **
**   P2MP-NBMA      ---             √              30S             单  **
****************************************************
--------------------------------
                        R1
                         |(S1/0)
                         |
R2(S1/0)------FR-SW-------(S1/0)R3
--------------------------------
1.
R1:
interface Loopback0
 ip address 1.1.1.1 255.255.255.0
 ip ospf network point-to-point
!        
interface Serial1/0
 ip address 123.1.1.1 255.255.255.0
 encapsulation frame-relay
 ip ospf network point-to-multipoint 默认为广播网络
!
router ospf 100
 router-id 1.1.1.1
 log-adjacency-changes
 network 1.1.1.1 0.0.0.0 area 0
 network 123.1.1.1 0.0.0.0 area 0
!
R2:
interface Loopback0
 ip address 2.2.2.2 255.255.255.0
 ip ospf network point-to-point
!        
interface Serial1/0
 ip address 123.1.1.2 255.255.255.0
 encapsulation frame-relay
 ip ospf network point-to-multipoint
!
router ospf 200
 router-id 2.2.2.2
 log-adjacency-changes
 network 2.2.2.2 0.0.0.0 area 0
 network 123.1.1.2 0.0.0.0 area 0
!
R3:
interface Loopback0
 ip address 3.3.3.3 255.255.255.0
 ip ospf network point-to-point
!        
interface Serial1/0
 ip address 123.1.1.3 255.255.255.0
 encapsulation frame-relay
 ip ospf network point-to-multipoint
!
router ospf 300
 router-id 3.3.3.3
 log-adjacency-changes
 network 3.3.3.3 0.0.0.0 area 0
 network 123.1.1.3 0.0.0.0 area 0
!
----------------------------
R1#show ip ospf interface s1/0
Serial1/0 is up, line protocol is up
  Internet Address 123.1.1.1/24, Area 0
  Process ID 100, Router ID 1.1.1.1, Network Type POINT_TO_MULTIPOINT, Cost: 64
  Transmit Delay is 1 sec, State POINT_TO_MULTIPOINT,
  Timer intervals configured, Hello 30, Dead 120, Wait 120, Retransmit 5
    oob-resync timeout 120
    Hello due in 00:00:08
  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 4 msec
  Neighbor Count is 2, Adjacent neighbor count is 2
    Adjacent with neighbor 3.3.3.3
    Adjacent with neighbor 2.2.2.2
  Suppress hello for 0 neighbor(s)
R1#show frame-relay map 自动解析的DLCI具有Broadcast能力
Serial1/0 (up): ip 123.1.1.3 dlci 103(0x67,0x1870), dynamic,
              broadcast,, status defined, active
Serial1/0 (up): ip 123.1.1.2 dlci 102(0x66,0x1860), dynamic,
              broadcast,, status defined, active
R1#
---------------------
R1#debug ip ospf hello
OSPF hello events debugging is on
R1#
May  6 17:31:44.375: OSPF: Rcv hello from 3.3.3.3 area 0 from Serial1/0 123.1.1.3
May  6 17:31:44.379: OSPF: End of hello processing
R1#
May  6 17:31:48.267: OSPF: Send hello to 224.0.0.5 area 0 on Serial1/0 from 123.1.1.1
R1#
May  6 17:31:54.823: OSPF: Rcv hello from 2.2.2.2 area 0 from Serial1/0 123.1.1.2
May  6 17:31:54.827: OSPF: End of hello processing
R1#
May  6 17:32:14.347: OSPF: Rcv hello from 3.3.3.3 area 0 from Serial1/0 123.1.1.3
May  6 17:32:14.351: OSPF: End of hello processing
R1#
May  6 17:32:18.267: OSPF: Send hello to 224.0.0.5 area 0 on Serial1/0 from 123.1.1.1
R1#
May  6 17:32:24.807: OSPF: Rcv hello from 2.2.2.2 area 0 from Serial1/0 123.1.1.2
May  6 17:32:24.811: OSPF: End of hello processing
R1#
---------------------
R1#show ip ospf neighbor

Neighbor ID     Pri   State           Dead Time   Address         Interface
3.3.3.3           0   FULL/  -        00:01:40    123.1.1.3       Serial1/0
2.2.2.2           0   FULL/  -        00:01:44    123.1.1.2       Serial1/0
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, 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

     1.0.0.0/24 is subnetted, 1 subnets
C       1.1.1.0 is directly connected, Loopback0
     2.0.0.0/24 is subnetted, 1 subnets
O       2.2.2.0 [110/65] via 123.1.1.2, 00:00:12, Serial1/0
     3.0.0.0/24 is subnetted, 1 subnets
O       3.3.3.0 [110/65] via 123.1.1.3, 00:00:12, Serial1/0
     123.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
O       123.1.1.3/32 [110/64] via 123.1.1.3, 00:00:12, Serial1/0
O       123.1.1.2/32 [110/64] via 123.1.1.2, 00:00:12, Serial1/0
C       123.1.1.0/24 is directly connected, Serial1/0
R1#
===========================
手工映射DLCI  Hub and Spoke类型 R1为Hub,R2和R3为Spoke
配置如下:
R1:
interface Loopback0
 ip address 1.1.1.1 255.255.255.0
 ip ospf network point-to-point
!        
interface Serial1/0
 ip address 123.1.1.1 255.255.255.0
 encapsulation frame-relay
 ip ospf network point-to-multipoint
 frame-relay map ip 123.1.1.3 103 broadcast
 frame-relay map ip 123.1.1.2 102 broadcast
 no frame-relay inverse-arp
!
router ospf 100
 router-id 1.1.1.1
 log-adjacency-changes
 network 1.1.1.1 0.0.0.0 area 0
 network 123.1.1.1 0.0.0.0 area 0
!
R2:
interface Loopback0
 ip address 2.2.2.2 255.255.255.0
 ip ospf network point-to-point
!
interface Serial1/0
 ip address 123.1.1.2 255.255.255.0
 encapsulation frame-relay
 ip ospf network point-to-multipoint
 serial restart_delay 0
 frame-relay map ip 123.1.1.1 201 broadcast
 no frame-relay inverse-arp
!
router ospf 200
 router-id 2.2.2.2
 log-adjacency-changes
 network 2.2.2.2 0.0.0.0 area 0
 network 123.1.1.2 0.0.0.0 area 0
!
R3:
interface Loopback0
 ip address 3.3.3.3 255.255.255.0
 ip ospf network point-to-point
!
interface Serial1/0
 ip address 123.1.1.3 255.255.255.0
 encapsulation frame-relay
 ip ospf network point-to-multipoint
 serial restart_delay 0
 frame-relay map ip 123.1.1.1 301 broadcast
 no frame-relay inverse-arp
!
router ospf 300
 router-id 3.3.3.3
 log-adjacency-changes
 network 3.3.3.3 0.0.0.0 area 0
 network 123.1.1.3 0.0.0.0 area 0
!
----------------------------
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, 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

     1.0.0.0/24 is subnetted, 1 subnets
C       1.1.1.0 is directly connected, Loopback0
     2.0.0.0/24 is subnetted, 1 subnets
O       2.2.2.0 [110/65] via 123.1.1.2, 00:05:34, Serial1/0
     3.0.0.0/24 is subnetted, 1 subnets
O       3.3.3.0 [110/65] via 123.1.1.3, 00:05:34, Serial1/0
     123.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
O       123.1.1.3/32 [110/64] via 123.1.1.3, 00:05:34, Serial1/0
O       123.1.1.2/32 [110/64] via 123.1.1.2, 00:05:34, Serial1/0
C       123.1.1.0/24 is directly connected, Serial1/0
R1#
---------------
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, 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

     1.0.0.0/24 is subnetted, 1 subnets
O       1.1.1.0 [110/65] via 123.1.1.1, 00:05:40, Serial1/0
     2.0.0.0/24 is subnetted, 1 subnets
C       2.2.2.0 is directly connected, Loopback0
     3.0.0.0/24 is subnetted, 1 subnets
O       3.3.3.0 [110/129] via 123.1.1.1, 00:05:40, Serial1/0
     123.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
O       123.1.1.3/32 [110/128] via 123.1.1.1, 00:05:40, Serial1/0
O       123.1.1.1/32 [110/64] via 123.1.1.1, 00:05:40, Serial1/0
C       123.1.1.0/24 is directly connected, Serial1/0
R2#

posted on 2009-05-16 16:37 苏志辉 阅读(294) 评论(0)  编辑 收藏 引用 所属分类: CCNP
只有注册用户登录后才能发表评论。