You are on page 1of 44

ROUTING

The process of transferring data from one local area network to another network. Layer 3 devices (Network Layer) Routed protocol Enables to forward packet from one router to another for example IP, IPX Routing protocol sends and receives routing information packets to and from other routers for example RIP, OSPF, IGRP Routing protocols gather and share the routing information used to maintain and update routing tables. That routing information is in turn used to route a routed protocol to its final destination

WHAT IS ROUTING?
10.120.2.0 172.16.1.0

To route, a router needs to know: Destination addresses Sources it can learn from Possible routes Best route

WHAT IS ROUTING? (CONT.)


10.120.2.0 E0 172.16.1.0 S0

Network Protocol Connected Learned

Destination Exit Network Interface 10.120.2.0 172.16.1.0 E0 S0

Routed Protocol: IP

Routers must learn destinations that are not directly connected

ROUTE TYPES

Static routing - network administrator configures information about remote networks manually. They are used to reduce overhead and for security. Dynamic routing - information is learned from other routers, and routing protocols adjust routes automatically. Because of the extra administrative requirements, static routing does not have the scalability of dynamic routing.

IP ROUTING

The different types of routing are: Static routing Default routing Dynamic routing

STATIC ROUTES

Benefits No overhead on the router CPU No bandwidth usage between routers Adds security Disadvantage Administrator must really understand the internetwork If a network is added to the internetwork, the administrator has to add a route to it on all routers Not feasible in large networks

STATIC ROUTE CONFIGURATION


20.0.0.1 10.0.0.1
E0 S0

20.0.0.2
S0

30.0.0.1
S1

30.0.0.2
S0 E0

R2# config t R2(config)#ip route 10.0.0.0 255.0.0.0 20.0.0.1 R2(config)#ip route 40.0.0.0 255.0.0.0 30.0.0.2

40.0.0.1

10.0.0.2

40.0.0.2

R1# config t R1(config)#ip route 30.0.0.0 255.0.0.0 20.0.0.2 R1(config)#ip route 40.0.0.0 255.0.0.0 20.0.0.2 R3# config t R3(config)#ip route 10.0.0.0 255.0.0.0 30.0.0.1 R3(config)#ip route 20.0.0.0 255.0.0.0 30.0.0.1

DEFAULT ROUTES

Can only use default routing on stub networks Stub networks are those with only one exit path out of the network The only routers that are considered to be in a stub network are R1 and R3

20.0.0.1 10.0.0.1
E0 S0

20.0.0.2
S0

30.0.0.1
S1

30.0.0.2
S0 E0

40.0.0.1

10.0.0.2

40.0.0.2

DEFAULT ROUTES
Stub Network
172.16.1.0 SO A 172.16.2.2 172.16.2.1 B B

ISP
10.0.0.0

ip route 0.0.0.0 0.0.0.0 172.16.2.2 or S0

This route allows the stub network to reach all known networks beyond router A.

DEFAULT ROUTE CONFIGURATION


20.0.0.1 10.0.0.1
E0 S0

20.0.0.2
S0

30.0.0.1
S1

30.0.0.2
S0 E0

40.0.0.1

10.0.0.2

A
R2# config t R2(config)#ip route 10.0.0.0 255.0.0.0 20.0.0.1 R2(config)#ip route 40.0.0.0 255.0.0.0 30.0.0.2

40.0.0.2

R1# config t R1(config)#ip route 0.0.0.0 0.0.0.0 20.0.0.2

R3# config t R3(config)#ip route 0.0.0.0 0.0.0.0 30.0.0.1

WHAT IS A ROUTING PROTOCOL?


10.120.2.0 E0 172.16.1.0 S0

Network Protocol

Destination Exit Network Interface 10.120.2.0 172.16.2.0 172.17.3.0 E0 S0 S1

172.17.3.0 Routed Protocol: IP Routing protocol: RIP, IGRP

Connected RIP IGRP

Routing protocols are used between routers to determine paths and


maintain routing tables. Once the path is determined a router can route a routed protocol.

AUTONOMOUS SYSTEMS: INTERIOR OR EXTERIOR


ROUTING PROTOCOLS

An autonomous system is a collection of networks under a common administrative domain. AS parameter is 16-bit number for 0-65535 Internet is a Public network and IANA gives every Carrier or ISP a unique AS no. Every carrier or ISP has its own responsibility to manage and maintain its own network. PTCL and Transworld are only two AS in Pakistan IGPs operate within an autonomous system, RIP, IGRP, EIGRP, OSPF, IS-IS EGPs connect different autonomous systems, BGP

TYPES OR CLASSES OF ROUTING PROTOCOLS

DISTANCE VECTOR:
Exchange routing table between routers neighbors after periodic time interval for example RIP for 30sec and IGRP for 90 sec. Complete Routing table exchange.

Distance vector routing protocol only have best path information to reach destination. No complete information of network topology, just knows the information of best path to reach destination. Bandwidth is not efficiently utilized.

This is also know as routing by rumor


Examples are RIP, RIPV2 and IGRP.

LINK STATE:
Exchange routing updates not complete table, whenever there is some change in network topology. Have complete information of network topology. Bandwidth efficiently utilized. More accurate routing decisions. CPU and Memory intensive. Examples are OSPF and IS-IS.

TYPES OR CLASSES OF ROUTING PROTOCOLS

Distance Vector RIP V1 IGRP RIP V2

Link state OSPF IS-IS


Hybrid EIGRP

CLASSFUL ROUTING OVERVIEW


Classful

routing protocols do not include the subnet mask with the route advertisement. the same network, consistency of the subnet masks is assumed. routes are exchanged between foreign networks.

Within

Summary Not

Support VLSM

Examples

of classful routing protocols: RIP Version 1 (RIPv1) IGRP

CLASSLESS ROUTING OVERVIEW

Classless routing protocols include the subnet mask with the route advertisement. Classless routing protocols support variable-length subnet masking (VLSM) and subnetting Examples of classless routing protocols: RIP Version 2 (RIPv2) EIGRP OSPF IS-IS

DISTANCE VECTOR ROUTING PROTOCOLS

Routers

pass periodic copies of routing table to neighbor routers and accumulate distance vectors.

DISTANCE VECTOR
192.168.10.1 192.168.20.1

Uses Bellman Ford Algorithm It needs to find out the shortest path from one network to other There are two Distance Vector Protocol, Both uses different metric RIP Hop count as metric IGRP Uses composite Metric are bandwidth, Delay, Load, Reliability and MTU

DISTANCE VECTOR
2 1 0 2 1 192.168.20.1

R1

192.168.10.1

DV protocol are known as Routing by rumor RIP uses only Hop count RI routing table metric for 192.168.20.1 network will be
3 2

DISTANCE VECTOR
10 1 Mbps 1 Mbps 1 Mbps 10 10

R1

192.168.10.1

56 kbps 30 30 56 kbps 192.168.20.1

IGGRP uses bandwidth and delay as Metric


RI routing table metric for 192.168.20.1 network will be

30 60

SOURCES OF INFORMATION AND DISCOVERING ROUTES

Routers

discover the best path to destinations from each neighbor.

INCONSISTENT ROUTING ENTRIES

Each

node maintains the distance from itself to each possible destination network.

INCONSISTENT ROUTING ENTRIES (CONT.)

Slow

convergence produces inconsistent routing.

INCONSISTENT ROUTING ENTRIES (CONT.)

Router C concludes that the best path to network 10.4.0.0 is through router B.

INCONSISTENT ROUTING ENTRIES (CONT.)

Router A updates its table to reflect the new but erroneous hop count.

ROUTING LOOPS

Packets for network 10.4.0.0 bounce (loop) between routers B and C.

DEFINING A MAXIMUM HOP COUNT

Define a limit on the number of hops to prevent infinite loops.

One way of solving routing loop problem is to define a maximum hop count. RIP permits a hop count of up to 15, so anything that requires 16 hops is deemed unreachable

SPLIT HORIZON

The split horizon technique attempts to eliminate routing loops and speed up convergence. The rule of split horizon is that it is never useful to send information about a route back in the direction from which the original packet came. In the example: Router C originally announced a route to network 10.4.0.0 to router B. It makes no sense for router B to announce to router C that router B has access to network 10.4.0.0 through router C.

SPLIT HORIZON

Solution to the Routing Loop problem Split Horizon is a rule that routing information cannot be sent back in the direction from which it was received Had split horizon been used in our example, Router B would not have included information about network 10.4.0.0 in its update to Router C.

ROUTE POISONING

Route Poisoning. Usually used in conjunction with split horizon Route poisoning involves explicitly poisoning a routing table entry for an unreachable network Once Router C learned that network 10.4.0.0 was unavailable it would have immediately poisoned the route to that network by setting its hop count to the routing protocols infinity value In the case of RIP, that would mean a hop count of 16.

TRIGGERED UPDATES
oNew routing tables are sent to neighboring routers on a regular basis. oRIP updates occur every 30 seconds oHowever a triggered update is sent immediately in response to some change in the routing table. oThe router that detects a topology change immediately sends an update message to adjacent routers that, in turn, generate triggered updates notifying their adjacent neighbors of the change. oTriggered updates, used in conjunction with route poisoning, ensure that all routers know of failed routes.

TRIGGERED UPDATES GRAPHIC

RIP TIMERS

Route update timer Sets the interval (typically 30 seconds) between periodic routing updates Route invalid timer Determines the length of time (180 seconds) before a router determines that a route has become invalid Holddown timer This sets the amount of time during which routing information is suppressed. This continues until either an update packet is received with a better metric or until the holddown timer expires. The default is 180 seconds Route flush timer Sets the time between a route becoming invalid and its removal from the routing table (240 seconds).

ROUTING INFORMATION PROTOCOL (RIP)


Routing Information Protocol (RIP) is a true distance-vector routing protocol. It sends the complete routing table out to all active interfaces every 30 seconds RIP only uses hop count to determine the best way to a remote network It has a maximum allowable hop count of 15 AD is 120 Bellman-ford algorithm Works well in small networks, but its inefficient on large networks RIP version 1 uses only classful routing, which means that all devices in the network must use the same subnet mask RIP version 2 does send subnet mask information with the route updates. This is called classless routing. RIP enable routers can perform EQUAL CAST LOAD BALANCING by default for 4 paths (max-upto 6 paths)

RIP CONFIGURATION
192.168.20.1 192.168.30.1

192.168.10.1 E0

S0

S1 S0
192.168.20.2

S0
192.168.30.2

E0 192.168.40.1

192.168.10.2

R2# config t R2(config)#router rip R2(config)#network 192.168.20.0 R2(config)#network 192.168.30.0

192.168.40.2

R1# config t R1(config)# )#router rip R1(config)#network 192.168.10.0 R1(config)#network 192.168.20.0

R3# config t R3(config)# )#router rip R3(config)#network 192.168.30.0 R3(config)#network 192.168.40.0

DISPLAYING THE IP ROUTING TABLE

DEBUG IP RIP

COMMAND

RIP VERSION 2 (RIPV2)

RIP VERSION 2 CONFIGURATION


192.168.0.4/30 192.168.0.8/30

E0
192.168.0.16/29

S0

S1 S0

S0 E0
192.168.0.32/28

Find out the IP Address and SNM of each interfaces

RIP VERSION 2 CONFIGURATION


192.168.0.5 255.255.255.252 192.168.0.9 255.255.255.252

E0
192.168.0.17 255.255.255.248

S0

S1 S0
192.168.0.6 255.255.255.252

S0
192.168.0.10 255.255.255.252

E0

192.168.0.33 255.255.255.240

A
192.168.0.18 255.255.255.248

192.168.0.34 255.255.255.240

RIP VERSION 2 CONFIGURATION


192.168.0.4/30 192.168.0.8/30

E0
192.168.0.16/29

S0

S1 S0
R2# config t R2(config)#router rip R2(config)#network 192.168.0.4 R2(config)#network 192.168.0.8 R2(config)#version 2

S0 E0
192.168.0.32/28

R1# config t R1(config)# )#router rip R1(config)#network 192.168.0.4 R1(config)#network 192.168.0.16 R1(config)#version 2

R3# config t R3(config)# )#router rip R3(config)#network 192.168.0.8 R3(config)#network 192.168.0.32 R3(config)#version 2

You might also like