《开放链路最短优先108知识讲解》由会员分享,可在线阅读,更多相关《开放链路最短优先108知识讲解(56页珍藏版)》请在金锄头文库上搜索。
1、 2006, Shenzhen Polytechnic. All rights reserved.1开放链路最短优先开放链路最短优先Open Shortest Path First 深圳职业技术学院计算机系网络专业深圳职业技术学院计算机系网络专业 2006 Shenzhen Polytechnic. All rights reserved.2链路状态协议(链路状态协议(LinkState Protocols) 2006 Shenzhen Polytechnic. All rights reserved.3OSPF概述(概述(OSPF Overview) 2006 Shenzhen Polyte
2、chnic. All rights reserved.4 2006 Shenzhen Polytechnic. All rights reserved.5OSPF术语(术语(OSPF Terminology) 2006 Shenzhen Polytechnic. All rights reserved.6OSPF数据包类型(数据包类型(OSPF Packet Types) 2006 Shenzhen Polytechnic. All rights reserved.7OSPF数据包头格式数据包头格式(OSPF Packet Header Format) 2006 Shenzhen Polyte
3、chnic. All rights reserved.8OSPF操作(操作(OSPF Operation) 1. 建立邻接关系建立邻接关系Establish router adjacencies2. 必要的进行必要的进行DR选举选举Elect the DR / BDR ( if necessary )3. 发现路由发现路由Discover routes4.选择相应的路由选择相应的路由Select appropriate routes5. 维护路由信息维护路由信息Maintain routing information 2006 Shenzhen Polytechnic. All rights
4、reserved.9邻居关系(邻居关系(Neighborship)*标记的在邻居路由器上必须匹配标记的在邻居路由器上必须匹配 2006 Shenzhen Polytechnic. All rights reserved.10建立双向通信建立双向通信(Establishing Bidirectional Communication) 2006 Shenzhen Polytechnic. All rights reserved.11建立双向通信建立双向通信(Establishing Bidirectional Communication) 2006 Shenzhen Polytechnic. Al
5、l rights reserved.12建立双向通信建立双向通信(Establishing Bidirectional Communication) 2006 Shenzhen Polytechnic. All rights reserved.13建立双向通信建立双向通信(Establishing Bidirectional Communication) 2006 Shenzhen Polytechnic. All rights reserved.14查找网络路由查找网络路由(Discovering the Network Routes) 2006 Shenzhen Polytechnic.
6、All rights reserved.15查找网络路由查找网络路由(Discovering the Network Routes) 2006 Shenzhen Polytechnic. All rights reserved.16增加链路状态条目增加链路状态条目(Adding the LinkState Entries) 2006 Shenzhen Polytechnic. All rights reserved.17增加链路状态条目增加链路状态条目(Adding the LinkState Entries) 2006 Shenzhen Polytechnic. All rights res
7、erved.18增加链路状态条目增加链路状态条目(Adding the LinkState Entries) 2006 Shenzhen Polytechnic. All rights reserved.19维护路由信息维护路由信息(Maintaining Routing Information)路由器用路由器用224.0.0.6通知通知DR Router A notifies all OSPF DRs on 224.0.0.6 2006 Shenzhen Polytechnic. All rights reserved.20维护路由信息维护路由信息(Maintaining Routing I
8、nformation)DR利用组播地址利用组播地址224.0.0.5通知其它路由器通知其它路由器DR notifies others on 224.0.0.5 2006 Shenzhen Polytechnic. All rights reserved.21维护路由信息维护路由信息(Maintaining Routing Information) 2006 Shenzhen Polytechnic. All rights reserved.22维护路由信息维护路由信息(Maintaining Routing Information) 2006 Shenzhen Polytechnic. All
9、 rights reserved.23维护路由信息维护路由信息(Maintaining Routing Information) 2006 Shenzhen Polytechnic. All rights reserved.24OSPF网络类型(网络类型(OSPF Network Types)Network TypeCharacteristicsDR/BDR Elected?以太网(以太网(Ethernet)Yes帧中继(帧中继(Frame Relay)YesPPP, HDLCNo管理员用子接口配置管理员用子接口配置(Configured by administrator with subin
10、terfaces)NoFrame RelayX.25广播广播Broadcast Multiaccess非广播非广播Nonbroadcast Multiaccess点到点点到点Point-to-Point点到多点点到多点Point-to-Multipoint 2006 Shenzhen Polytechnic. All rights reserved.25点到点链路(点到点链路(PointtoPoint Links)1.不进行不进行DR选举选举No DR or BDR election required2. OSPF自动检测这种接口类型自动检测这种接口类型 OSPF autodetects th
11、is interface type 2006 Shenzhen Polytechnic. All rights reserved.26广播型多路访问网络广播型多路访问网络(Multiaccess Broadcast Network) 1.进行进行DR选举选举 DR and BDR selection required 2.邻居只与邻居只与DR和和DBR形成邻接关系形成邻接关系All neighbor routers form full adjacencies with the DR and BDR only 2006 Shenzhen Polytechnic. All rights reser
12、ved.27选举选举DR和和BDR(Electing the DR and BDR)1.最高接口优先级的路由器被选成最高接口优先级的路由器被选成DR The router with the highest OSPF priority is selected as the DR.2.最高路由器最高路由器ID的路由器被选举成的路由器被选举成DR Use the OSPF router ID as the tie breaker. 3.DR选举不具有抢占性选举不具有抢占性The DR election is nonpreemptive. 2006 Shenzhen Polytechnic. All
13、rights reserved.28设置接口优先级(设置接口优先级(Setting Interface Priority)ip ospf priority number1. 不同的接口可以指定不同的值不同的接口可以指定不同的值Different interfaces on a router may be assigned different values.2. 接口优先级默认为接口优先级默认为1,取值范围是取值范围是0255The default priority is 1. The range is from 0 to 255.3. 接口优先级为接口优先级为0表示不参加表示不参加DR选举选举
14、0 means the router is a DROTHER; it cant be the DR or BDR.Router(config-if)# 2006 Shenzhen Polytechnic. All rights reserved.29router ospf process-id Router(config)#启动路由进程启动路由进程Turns on one or more OSPF routing processesOSPF基本配置(基本配置(Configuring Basic OSPF)network address inverse-mask area area-idRou
15、ter(config-router)#用用network命令命令ospf运行的接口,并将网络指定到特定的运行的接口,并将网络指定到特定的区域区域Router OSPF subordinate command that defines the interfaces (by network number) that OSPF will run on. Each network number must be defined to a specific area. 2006 Shenzhen Polytechnic. All rights reserved.30OSPF配置实例(配置实例(Config
16、uring OSPF Example) 2006 Shenzhen Polytechnic. All rights reserved.31验证验证ospf配置(配置(Verifying OSPF Operation)show ip protocolsShow ip ospf neighborShow ip ospf databaseShow ip routeShow ip ospfShow ip ospf interfaceDebug ip ospf adjDebug ip ospf event 2006 Shenzhen Polytechnic. All rights reserved.32确定确定OSPF路由器路由器ID(OSPF Router ID)1. 通过通过routerid命令指定的最为优先命令指定的最为优先An OSPF routerid command can override OSPF router ID.2. 最高的环回接口地址次之最高的环回接口地址次之A loopback interface can override OSPF router ID. It is t