57
Chapter 8: Single-Area OSPF Routing & Switching

Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

  • Upload
    letruc

  • View
    231

  • Download
    2

Embed Size (px)

Citation preview

Page 1: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

Chapter 8: Single-Area OSPF

Routing & Switching

Page 2: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

2

Evolution of OSPF

Interior Gateway Protocols

19881989

updated in 2008

Page 3: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

3

Features of OSPF

Page 4: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

4

Components of OSPF

Page 5: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

5

Components of OSPF

OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to maintain accurate information about the network

Page 6: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

6

Link-State Operation

If a neighbor is present, the OSPF-enabled router attempts to establish a neighbor adjacency with that neighbor

Page 7: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

7

Link-State Operation

LSAs contain the state and cost of each directly connected link

Routers flood their LSAs to adjacent neighbors Adjacent neighbors receiving the LSA immediately flood the

LSA to other directly connected neighbors, until all routers in the area have all LSAs

Page 8: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

8

Link-State Operation

It is a link-state database that represents the network topology. Build the topology table based on the received LSAs. This database eventually holds all the information about the

topology of the network. When converged, all routers in an area have identical

topology tables. Execute the SPF Algorithm. The table can be viewed via the show ip ospf database command.

Page 9: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

9

Link-State Operation

From the SPF tree, the best paths are inserted into the routing table

Page 10: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

10

Single-area and Multiarea OSPF

Page 11: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

11

Single-area and Multiarea OSPF

Page 12: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

12

Encapsulating OSPF Messages

Page 13: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

13

Types of OSPF Packets

Page 14: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

14

Hello Packet

OSPF Type 1 packet = Hello packet:• Discover OSPF neighbors and establish neighbor

adjacencies.• Advertise parameters on which two routers must agree to

become neighbors.• Elect the Designated Router (DR) and Backup Designated

Router (BDR) on multiaccess networks like Ethernet and Frame Relay.

Page 15: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

15

Hello Packet

Page 16: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

16

Hello Packet Intervals

OSPF Hello packets are transmitted:• To 224.0.0.5 in IPv4 and FF02::5 in IPv6 (all OSPF

routers)• Every 10 seconds (default on multiaccess and point-to-

point networks)• Every 30 seconds (default on non-broadcast multiaccess

[NBMA] networks)• Dead interval is the period that the router waits to receive

a Hello packet before declaring the neighbor down• Router floods the LSDB with information about down

neighbors out all OSPF enabled interfaces• Cisco’s default is 4 times the Hello interval

Page 17: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

17

Hello Packet Intervals

What will always happen if the dead interval expires before the router receives a hello packet from an adjacent DROTHER OSPF router?

OSPF will remove that neighbor from the router link-state database.

Page 18: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

18

Link-State Updates

A LSU packet contains the different types of link-state advertisements

Page 19: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

19

OSPF Operational States

When an OSPF router is initially connected to a network, it attempts to:

• Create adjacencies with neighbors• Exchange routing information• Calculate the best routes• Reach convergence• OSPF progresses through several states while attempting

to reach convergence.

Page 20: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

20

Establish Neighbor Adjacencies

Page 21: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

21

Establish Neighbor Adjacencies

The election of a DR and a BDR takes place on multiaccessnetworks, such as Ethernet networks.

Page 22: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

22

OSPF DR and BDR

Page 23: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

23

Synchronizing OSPF Database

Page 24: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

24

Synchronizing OSPF Database

Page 25: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

25

OSPF Network Topology

Page 26: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

26

Router IDs

Purposes of an OSPF router ID:• To uniquely identify the router within the OSPF domain • To facilitate router participation in the election of the

designated router Router ID Order of Precedence:

• Configured Router ID address• Loopback interface address• Highest active configured IP address

Page 27: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

27

The network Command

Which wildcard mask would be used to advertise the 192.168.5.96/27 network as part of an OSPF configuration?

0.0.0.31

Page 28: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

28

Passive Interface

By default, OSPF messages are forwarded out all OSPF-enabled interfaces. However, these messages really only need to be sent out interfaces connecting to other OSPF-enabled routers. Sending out unneeded messages on a LAN affects the

network in three ways:• Inefficient Use of Bandwidth• Inefficient Use of Resources• Increased Security Risk

The Passive Interface feature helps limiting the scope of routing updates advertisements.

Page 29: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

29

Configuring Passive Interfaces

Use the passive-interface router configuration mode command to prevent the transmission of routing messages through a router interface, but still allow that network to be advertised to other routers.

Page 30: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

30

OSPF Metric = Cost

Cost = reference bandwidth / interface bandwidth(default reference bandwidth is 10^8) Cost = 100,000,000 bps / interface bandwidth in bps

Page 31: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

31

OSPF Accumulates Costs

Cost of an OSPF route is the accumulated value from one router to the destination network.

Page 32: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

32

Adjusting the Reference Bandwidth

Use the command auto-cost reference-bandwidth Must be configured on every router in the OSPF domain Notice that the value is expressed in Mb/s:

Gigabit Ethernet - auto-cost reference-bandwidth 1000 10 Gigabit Ethernet - auto-cost reference-bandwidth 10000

Page 33: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

33

Default Interface Bandwidths

On Cisco routers, the default bandwidth on most serial interfaces is set to 1.544 Mb/s

Page 34: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

34

Adjusting the Interface Bandwidths

Page 35: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

35

Manually Setting the OSPF Cost

Both the bandwidth BW interface command and the ip ospf cost cost# command achieve the same result, which is to provide an accurate value for use by OSPF in determining the best route. The show interface interfaceID will show the

bandwidth of the interface

Page 36: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

36

Verify OSPF Neighbors

Verify that the router has formed an adjacency with its neighboring routers Shows the Neighbor ID

Page 37: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

37

Verify OSPF Protocol Settings

The show ip protocols command is used to check:• The OSPF process ID• The router ID• The networks the router is

advertising• The neighbors the router is

receiving updates from• The default administrative

distance

Page 38: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

38

Verify OSPF Process Information

Verify OSPF Process and ID

Page 39: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

39

Verify OSPF Interface Settings

Page 40: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

40

Basic OSPF Configuration

R1router ospf 10

network 192.168.2.0 0.0.0.255 area 0

network 10.0.10.0 0.0.0.3 area 0

R2router ospf 10

network 10.0.10.0 0.0.0.3 area 0

network 10.0.10.4 0.0.0.3 area 0

network 172.16.5.0 0.0.0.255 area 0

Process ID of 10Area 0

Configure R1 & R2 to use OSPF

Who is DR?

Page 41: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

41

OSPFv2 vs. OSPFv3

Page 42: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

42

Similarities Between OSPFv2 to OSPFv3

Similarities between OSPFv2 and OSPFv3:• They both are link-state protocols. • They both share the concept of multiple areas. • They both use the same DR/BDR election process• They both use the same packet types• They both use the same metric

Page 43: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

43

Differences Between OSPFv2 to OSPFv3

Which OSPFv3 function works differently from OSPFv2? authentication

Page 44: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

44

Link-Local Addresses

A Cisco router automatically uses an Ethernet interface MAC address available on the router, the FE80::/10 prefix, and the EUI-64 process to create link-local addresses on serial interfaces when OSPFv3 is implemented.

FF02::5 address is the all OSPF router addressFF02::6 is the DR/BDR multicast address

Page 45: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

45

Configuring Global-Unicast Addresses

Page 46: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

46

Configuring OSPFv3

A network administrator enters the command ipv6 router ospf 64 in global configuration mode. What is the result of this command?

The OSPFv3 process will be assigned an ID of 64 When configuring OSPFv3 on a router, which command

would be issued immediately before configuring the router ID?

ipv6 router ospf #

Page 47: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

47

Configuring OSPFv3

Single area OSPFv3 has been enabled on a router via the ipv6 router ospf 20 command. Which command will enable this OSPFv3 process on an interface of that router?

ipv6 ospf 20 area 0

Page 48: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

48

Link-Local Addresses

Link-local addresses are automatically created when anIPv6 global unicast address

is assigned to the interface (required).

Global unicast addresses are not required.

Cisco routers create the link-local address using FE80::/10 prefix and the EUI-64 process unless the router is configured manually,

EUI-64 involves using the 48-bit Ethernet MAC address, inserting FFFE in the middle and flipping the seventh bit. For serial interfaces, Cisco uses the MAC address of an Ethernet interface.

Notice in the figure that all three interfaces are using the same link-local address.

Page 49: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

49

Assigning Link-Local Addresses

Manually configuring the link-local address provides the ability to create an address that is recognizable and easier to remember.

Page 50: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

50

Configuring the OSPFv3 Router ID

Same as OSPFv2

Page 51: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

51

Configuring the OSPFv3 Router ID

Page 52: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

52

Enabling OSPFv3 on Interfaces

Instead of using the network router configuration mode command to specify matching interface addresses, OSPFv3 is configured directly on the interface.

Page 53: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

53

Verify OSPFv3 Neighbors/Protocol Settings

The show ipv6 ospf neighbor command will verify that a router that is running OSPFv3 has formed an adjacency with other routers in its OSPF area

Page 54: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

54

Verify OSPFv3 Neighbors/Protocol Settings

The show ipv6 protocols command will verify OSPFv3 configuration information including the OSPF process ID, the router ID, and the interfaces enabled for OSPFv3

Page 55: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

55

Verify OSPFv3 Interfaces

Page 56: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

56

Verify IPv6 Routing Table

The show ipv6 route ospf command will provide information specific to OSPFv3 routes in the routing table

Page 57: Chapter 8: Single-Area OSPF - Elk Technologies · OSPF Routers Exchange Packets - These packets are used to discover neighboring routers and also to exchange routing information to

57