1 / 258

OSPF

OSPF. Open Shortest Path First (OSPF) is a routing protocol developed for Internet Protocol (IP) networks by the Interior Gateway Protocol (IGP) working group of the Internet Engineering Task Force (IETF).

wayde
Download Presentation

OSPF

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. OSPF

  2. Open Shortest Path First (OSPF) is a routing protocol developed for Internet Protocol (IP) networks by the Interior Gateway Protocol (IGP) working group of the Internet Engineering Task Force (IETF). The working group was formed in 1988 to design an IGP based on the Shortest Path First (SPF) algorithm for use in the Internet. OSPF was created because in the mid-1980s, the Routing Information Protocol (RIP) was increasingly incapable of serving large, heterogeneous internetworks.

  3. OSPF has two primary characteristics. The first is that the protocol is open, which means that its specification is in the public domain. The OSPF specification is published as Request For Comments (RFC) 1247. The second principal characteristic is that OSPF is based on the SPF algorithm, which sometimes is referred to as the Dijkstra algorithm, named for the person credited with its creation. UPDATE: RFC 2328 !!!

  4. OSPF is a link-state routing protocol that calls for the sending of link-state advertisements (LSAs) to all other routers within the same hierarchical area. Information on attached interfaces, metrics used, and other variables is included in OSPF LSAs. As OSPF routers accumulate link-state information, they use the SPF algorithm to calculate the shortest path to each node.

  5. Preferred to RIP on larger networks Open Standard - IETF RFC 2328 (new RFC) Link State routing protocol Interior Gateway Protocol for Autonomous systems Metric based on bandwidth Supports VLSM OSFP can use ‘areas’ to allow hierarchical design OSPF Overview

  6. Overview of Link-State and Distance Vector Routing

  7. OSPF • Large OSPF networks use a hierarchical design • Defining areas reduces routing overhead, speeds up convergence, confines network instability to an area and improves performance • Backbone: area 0 OSPF has introduced new concepts such as authentication of routing updates, Variable Length Subnet Masks (VLSM), route summarization, etc.

  8. Large OSPF Network

  9. Link State Update Problem Flip flop Hold on

  10. OSPF Overview - Metric Different routing result comparing to RIP

  11. The formula used to calculate the cost is: cost= 100 000 000/bandwith in bpsFor example, it will cost 10 EXP8/10 EXP7 = 10 to cross a 10M Ethernet line and will cost 10 EXP8/1544000 = 64 to cross a T1 line. By default, the cost of an interface is calculated based on the bandwidth (not the clock rate !!); you can force the cost of an interface by using the ip ospf cost <value> interface sub- command.

  12. Configuring Cost Cost 64.7 Cost 64.7 1.544MB R4 1.544MB R3 R5 Cost 1 Cost =1562 Cost =195.1 100MB 56KB LAN 2 Cost 1562 R1 1.544MB R2 LAN 1 Cost 64.7 Cost = 10^8 / bandwidth

  13. Un premier exemple

  14. RTA# interface Ethernet0 ip address 192.213.11.1 255.255.255.0 interface Ethernet1 ip address 192.213.12.2 255.255.255.0 interface Ethernet2 ip address 128.213.1.1 255.255.255.0 router ospf 100 network 192.213.0.0 0.0.255.255 area 0.0.0.0 network 128.213.1.0 0.0.0.255 area 23

  15. Advantages and Disadvantages of Link-State Routing

  16. Comparing Distance Vector and Link-State Routing

  17. Identify Distance Vector & Link State Routing Characteristics Updates contain entire routing table Slow convergence Updates consume significant bandwidth Updates contain changes only Increased memory & processing requirements Updates sent to all routers Topology changes trigger updates Support CIDR/VLSM Updates sent to neighbours Rapid convergence Periodic updates

  18. Identify Distance Vector & Link State Routing Characteristics Updates contain entire routing table Slow convergence Updates consume significant bandwidth Updates contain changes only Increased memory & processing requirements Updates sent to all routers Topology changes trigger updates Support CIDR/VLSM Updates sent to neighbours Rapid convergence Periodic updates

  19. OSPF permet d’installer plusieurs routes pour une même destination, selon critère de débit. si plusieurs routes vers une même destination sont de coût équivalents, OSPF répartit la charge équitablement parmi ces routes. OSPF supporte l’adressage en sous-réseaux (subnets); Découpe d’un système autonome en aréas isolement des informations de routage à l’intérieur de ces aréas ==> limitation des informations de routage dans le système autonome . Les liens extérieurs avec d’autres systèmes autonomes (via EGP par exemple) sont pris en compte. Echanges entre routeurs authentifiés ==> intégrité des messages.

  20. Le problème : dans les systèmes de routage, si le réseau est trop grand overhead du traffic dans le réseau,calculs trop longs, dimensionnement mémoire trop grand La solution : routage hiérachique découpage du réseau en parties indépendantes (Areas) reliées par un BackBone (Area BackBone) OSPF : les concepts, areas

  21. La fonctionnalité • chaque area constitue un réseau indépendant • la table des liaisons ne contient que les liaisons de l’Area, • le protocole d’inondation s’arrête aux frontières de l’Area, • les routeurs ne calculent que des routes internes à l’Area • certains routeurs (area border routers) appartiennent à plusieurs Areas (en général une Area inférieure et une Area BB) et transmettent les informations récapitulatives des Areas qu’ils relient.

  22. OSPF: Concepts: Areas b1 BB0 BB2 Routeurs inter-areas b2 b6 Routeurs internes A1 a2 c1 C2 AB1 BC1 Area A Area C a1 b3 b5 c2 A2 a3 b4 c3 BC3 C4 AB4 BB AS

  23. Chaque routeur du système autonome ou d’une area construit sa propre base d’information décrivant la topologie de l’AS complet ou bien de l’area. Au départ les routeurs utilisent des message "Hello" pour découvrir leurs voisins; une "adjacence" est formée lorsque deux routeurs communiquent pour échanger des informations de routage. L’information élémentaire échangée entre routeurs décrit l’état (link state) des adjacences; cette information est fournie par un routeur donné puis propagée dans l'area ou l’AS. A partir de sa base d’information (collection d’états des routeurs), chaque routeur construit un arbre du plus court chemin (SPF tree) dont il est la racine. Cet arbre indique toutes les routes pour toutes les destinations du système autonome, plus les destinations extérieures.

  24. La base d’information topologique d’un système autonome décrit un graphe orienté. Les noeuds du graphe sont des routeurs tandis que les liens représentent les connexions physiques. Les réseaux sont dits de transit si plusieurs routeurs y sont connectés ou terminaux dans le cas contraire. A chaque réseau est associé une adresse IP et un masque réseau. Une machine seule (host) est considérée comme un réseau terminal avec un masque égal à FFFFFFFF. OSPF, la Base topologique

  25. N12 N13 N14 N 1 8 8 8 3 1 RT1 1 8 8 N3 RT4 RT5 7 6 AS border Router 1 N 2 8 6 3 RT3 RT6 RT2 7 2 N12 2 N4 N 1 1 6 3 N16 9 RT9 RT7 1 1 5 1 2 3 1 N 8 N9 N6 RT11 RT10 1 1 N 1 0 4 N 7 H1 RT12 RT8 2 10 OSPF : exemple

  26. N12 N13 N14 Dest. Next hop Distance N1 RT3 10 N2 RT3 10 N3 RT3 7 N4 RT3 8 N6 RT10 8 N7 RT10 12 N8 RT10 10 N9 RT10 11 N10 RT10 13 N11 RT10 14 H1 RT10 21 RT5 RT5 6 RT7 RT10 8 N12 RT10 10 N13 RT5 14 N14 RT5 14 N15 RT10 17 N 1 8 8 8 3 RT1 N3 RT4 RT5 1 6 RT6 RT3 3 RT2 N 2 2 6 N 1 1 N4 3 RT9 7 1 RT11 N9 3 N 8 RT10 1 N12 2 RT12 H1 N6 10 N 1 0 2 N15 9 RT7 La table de routage de R6 RT8 4 N7

  27. Area 1 N12 N13 N14 N 1 8 8 8 3 1 RT1 1 8 8 N3 RT4 RT5 7 6 AS border Router 1 N 2 8 6 3 RT3 RT6 RT2 2 7 N4 N12 2 6 N16 OSPF : Configuration en areas 9 3 Area 3 RT7 N 1 1 RT9 1 5 1 1 2 3 1 N 8 N9 N6 RT11 RT10 N 1 0 1 1 internes 4 N 7 H1 Area border RT12 RT8 2 10 Area 2 AS border

  28. Area 1 N1 4 N 1 3 1 RT1 1 N3 N2 4 RT4 N3 1 1 1 N 2 N4 3 3 RT3 RT2 2 N1 4 N4 N2 4 N3 1 N4 2 OSPF : Annonces de l’area 1 vers le BackBone

  29. A l’inverse : OSPF : les annonces du Backbone vers l’area 1 Destinations annoncées dans l’area 1 par RT3, RT4 Dest RT3 RT4 N6 16 (1+7+8) 15 N7 20 19 N8 18 18 N9 19 26

  30. Link-State Routing Features • Using Hello and LSA to build DB • Using SPF to calculate shortest route • Store this route info in routing table

  31. How Routing Information Is Maintained

  32. How Routing Information Is Maintained • Link-state advertisements (LSAs) • A topological database • The shortest path first (SPF) algorithm • The resulting SPF tree • A routing table of paths and ports to each network to determine the best paths for packets • If a link failure occurs, the flooding mechanism • with LSA is used!

  33. Routers are aware of directly connected networks known as ‘links’ Routers send ‘hellos’ to discover neighbours Routers send Link State Advertisements to other routers informing them of their links All routers add Link State Advertisements to their topological database Shortest Path algorithm calculates best route to each network When link states change, LSA update sent to all routers which recalculate their routes Link State Operation

  34. OSPF Key Words Adjacencies database • Directly connected routers (with exchange) Topological Database • Routes to every network Routing table • Best path to each network Designated Router • a router elected by all others to represent the network area Area 0 • backbone

  35. Topological Database • Every router advertises directly connected networks via Link State Advertisements • Every router has it’s own view of the network – it builds a ‘topological database’ • Router A is aware of 2 paths to 192.168.157.0 – this provides redundancy should one of the routers fail (cf slide suivante)

  36. Link-State Routing Protocol Algorithms

  37. OSPF Terminology

  38. OSPF Terminology

  39. Init state Establish bi-directional communication Exstart Loading state Full state Forming Adjacencies

  40. R1 R2 R6 R3 R5 R4 15 Router adjacencies (N*(N-1)/2) Router Adjacencies Without Designated Routers Echange de Link State

  41. Election process Hello Packet Priority Designated router (DR) Backup DR (BDR) DR other Router Designation

  42. R1 R2 R6 R3 R5 BDR 9 Router adjacencies R4 DR Router Adjacencies With Designated Routers

  43. Adjacencies The fact that routers are neighbors is not sufficient to guarantee an exchange of link-state updates; they must form adjacencies to exchange link-state updates. Adjacency is an advanced form of neighborship formed by routers that are willing to exchange routing information after negotiating parameters of such an exchange. Routers reach a FULL state of adjacency when they have synchronized views on a link-state database.

  44. Once a router decides to form an adjacency with a neighbor, it starts by exchanging a full copy of its link-state database. The neighbor, in turn, exchanges a full copy of its link-state database with the router. After passing through several neighbor states, the routers become fully adjacent.

  45. Neighbor in init State The init state indicates that a router sees HELLO packets from the neighbor, but two-way communication has not been established. A Cisco router includes the Router IDs of all neighbors in the init (or higher) state in the Neighbor field of its HELLO packets. For two-way communication to be established with a neighbor, a router also must see its own Router ID in the Neighbor field of the neighbor’s HELLO packets. Neighbor in 2-way State The 2-way state indicates that the router has seen its own Router ID in the Neighbor field of the neighbor’s HELLO packet.

  46. Neighbor in exstart State OSPF neighbors that are in exstart or exchange state are trying to exchange DBD packets. The router and its neighbor form a master and slave relationship. The adjacency should continue past this state. If it does not, there is a problem with the DBD exchange, such as a maximum transmission unit (MTU) mismatch or the receipt of an unexpected DBD sequence number. DBD= Database descriptors

  47. Exchange State In the exchange state, OSPF routers exchange database descriptor (DBD) packets. Database descriptors contain link-state advertisement (LSA) headers only and describe the contents of the entire link-state database. Each DBD packet has a sequence number which can be incremented only by master which is explicitly acknowledged by slave. Routers also send link-state request packets and link-state update packets (which contain the entire LSA) in this state. The contents of the DBD received are compared to the information contained in the routers link-state database to check if new or more current link-state information is available with the neighbor.

  48. Neighbor in loading State In the loading state, routers send link-state request packets. Full State Routers reach a FULL state of adjacency when they have synchronized views on a link-state database.

  49. Exemple

  50. RTA# hostname RTA interface Loopback0 ip address 203.250.13.41 255.255.255.0 interface Ethernet0 ip address 203.250.14.1 255.255.255.0 router ospf 10 network 203.250.13.41 0.0.0.0 area 1 network 203.250.0.0 0.0.255.255 area 0.0.0.0 RTF# hostname RTF interface Ethernet0 ip address 203.250.14.2 255.255.255.0 router ospf 10 network 203.250.0.0 0.0.255.255 area 0.0.0.0

More Related