0% found this document useful (0 votes)
13 views25 pages

Iprouting

The document provides an overview of IP routing, including static, default, and dynamic routing methods, and the use of routing protocols like RIP. It explains how routers operate, the factors they must know for effective routing, and the configuration of static and default routes. Additionally, it covers the advantages and disadvantages of different routing methods and includes examples of configuring routes on various routers.

Uploaded by

Milind Jha
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views25 pages

Iprouting

The document provides an overview of IP routing, including static, default, and dynamic routing methods, and the use of routing protocols like RIP. It explains how routers operate, the factors they must know for effective routing, and the configuration of static and default routes. Additionally, it covers the advantages and disadvantages of different routing methods and includes examples of configuring routes on various routers.

Uploaded by

Milind Jha
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 25

IP Routing

Static, Default, & RIP

SDC CNW (CSE 4541)

CSE, FET, ITER


SOA University, BBSR-30

CNW CSE4541 IPR


CNW CSE4541 IPR
References

Glen E. Clarke & Richard Deal


CCT/CCNA
Routing & Switching Exam Guide
McGrawHll

Todd Lammle
CCNA
Routing & Switching Study Guide
SYBEX, A Wiley Brand

CNW CSE4541 IPR


Discussion Flow

Introduction Static routing

Routing basics
Default routing

Different routing methods


Dynamic routing

Review Questions

CNW CSE4541 IPR


Introduction
 IP routing is the process of moving packets from one network to another
network using routers.

Routers use routing protocols to dynamically find all networks within the
greater internetwork and to ensure that all routers have the same routing
table.

Routing protocols are also employed to determine the best path a packet
should take through an internetwork to get to its destination most effi-
ciently.

Examples of the most common routing protocols: RIP, RIPv2, EIGRP,


and OSPF

Once all routers know about all networks, a routed protocol can be used
to send user data (packets) through the established enterprise.

Routed protocols are assigned to an interface and determine the method


of packet delivery. Examples of routed protocols are IP and IPv6.

CNW CSE4541 IPR


Routing Basics
 Routing refers to taking a packet from one device and sending it through
the network to another device on a different network.

Once an internetwork is created by connecting WANs and LANs to a


router, it would be needed to configure logical network addresses, like
IP addresses, to all hosts on that internetwork for them to communicate
successfully throughout it.

Routers don’t really care about hosts. They only care about networks
and the best path to each one of them rather

The logical network address of the destination host is key to getting pack-
ets through a routed network.

It’s the hardware address of the host that’s used to deliver the packet
from a router and ensure it arrives at the correct destination host.

Routing is irrelevant if the network has no routers because their job is to


route traffic to all the networks in the internetwork.

CNW CSE4541 IPR


Factors a Router Must Know
The list of minimum factors a router must know to be able to effectively route
packets:
Destination address
Neighbor routers from which it can learn about remote networks
Possible routes to all remote networks
The best route to each remote network
How to maintain and verify routing information?

How router works?


The router learns about remote networks from neighboring routers or from
an administrator. The router then builds a routing table, which is basically a
map of the internetwork, and it describes how to find remote networks. If a
network is directly connected, then the router already knows how to get to
it.

If a network isn’t directly connected to the router, the router must use one of two ways
(i.e static routing or dynamic routing) to learn how to get to the remote network.

CNW CSE4541 IPR


Uses of Routing Table
Commands
Lab A has four interfaces.
which interface will be used to forward an
IP datagram to a host with a destination
IP address of 10.10.10.30?
To show routing table
Lab A# show ip route

Routing Table at Lab A Routing


10.0.0.0/8 is variably subnetted, 6 subnets, 4 masks C- Directly connected
L- Local
C 10.0.0.0/8 is directly connected, FastEthernet0/3 new Cisco IOS 15 code.
L 10.0.0.1/32 is directly connected, FastEthernet0/3 called a local host route.
Each local route has a /32 pre-
C 10.10.0.0/16 is directly connected, FastEthernet0/2 fix, defining a route just for the
one address.
L 10.10.0.1/32 is directly connected, FastEthernet0/2
Forward packets to the router
C 10.10.10.0/24 is directly connected, FastEthernet0/1 itself.
The router will forward the packet to in-
L 10.10.10.1/32 is directly connected, FastEthernet0/1
terface FastEthernet 0/1. How ??
S∗ 0.0.0.0/0 is directly connected, FastEthernet0/0

CNW CSE4541 IPR


Different Routing Methods
Routing Protocols

Default Static Dynamic

Interior Gateway Exterior Gateway


Protocols(IGP) Protocols(EGP)

Distance Vector Link State Path Vector Routing


Routing Protocols Routing protocols Protocols
RIP V1 IGRP OSPF IS-IS BGP
RIP V2 EIGRP

CNW CSE4541 IPR


Static Routing
The process of adding manual routes in each router’s routing table.
Syntax:
ip route [destination_network] [mask]
[next-hop_address or ExitInterface Name]
[administrative_distance] [permanent]

Example: Static Route at R1


R1 R2

192.168.10.0/24
Gig0/0/0 Gig0/1/0
10.10.10.0/30
10.10.10.1
Next hop address:
Exit Interface
at R1 towards R2 Next hop

ip route 192.168.10.0 255.255.255.0 10.10.10.1


or
ip route 192.168.10.0 255.255.255.0 Gig0/0/0

CNW CSE4541 IPR


Syntax Static Routing
ip route [destination_network] [mask]
[next-hop_address or ExitInterface Name]
[administrative_distance] [permanent]

ip route: The command used to create the static route.


destination network:The network required to be placed in the routing table.
mask:The subnet mask being used on the network
next-hop address:This is the IP address of the next-hop router that will re-
ceive packets and forward them to the remote network.
exitinterface Name: An alternate to use in place of the next-hop address.
administrative distance: By default, static routes have an administrative
distance of 1 or 0 if you use an exit interface instead of a next-hop address. The
default value can be changed by adding an administrative weight at the end of the
command.
permanent:If the interface is shut down or the router can’t communicate to the
next-hop router, the route will automatically be discarded from the routing table
by default. Choosing the permanent option keeps the entry in the routing table no
matter what happens.
Example:
Router(config)#ip route 172.16.3.0 255.255.255.0 192.16.2.4 150 permanent

CNW CSE4541 IPR


Configure Static Routing
Configure all PCs with IP , sub-
net mask and default gateway
Configure the routers interfaces
Add static route at Corp Router
Add static route at SF Router
Add static route at LA Router
Verify the configuration through
ping or simulation

Default Routing
Remove the static route at SF
router
Add default route at SF router
Verify the configuration
Network Loops ???
Differentiate static vs default
route
CNW CSE4541 IPR
Static Route at Corp Router
The Corp router is connected to three networks. For the Corp router to be able
to route to all networks, the following networks have to be configured into its
routing table:
192.168.10.0/24
192.168.20.0/24

Corp#config t
Corp(config)#ip route 192.168.10.0 255.255.255.0 172.16.10.2 150
Corp(config)#ip route 192.168.20.0 255.255.255.0 s0/1 150

To show static routes on the Corp router

1) Corp(config)#do show run


or
1) Corp(config)#do show run | begin ip route

2) Corp(config)#do show ip route

CNW CSE4541 IPR


Static Route at SF Router
The SF router is directly connected to networks 172.16.10.0/30 and 192.168.10.0/24,
which means the following static routes to be configured on the SF router:
10.10.10.0/24
192.168.20.0/24
172.16.10.4/30

SF# config t
SF(config)#ip route 10.10.10.0 255.255.255.0 172.16.10.1 150
SF(config)#ip route 172.16.10.4 255.255.255.252 172.16.10.1 150
SF(config)#ip route 192.168.20.0 255.255.255.0 172.16.10.1 150

To show static routes on the Corp router

1) SF(config)#do show run


or
1) SF(config)#do show run | begin ip route

2) SF(config)#do show ip route

CNW CSE4541 IPR


Static Route at LA Router
The LA router is directly connected to 192.168.20.0/24 and 172.16.10.4/30,
so these are the routes that must be added:
10.10.10.0/24
172.16.10.0/30
192.168.10.0/24

LA#config t
LA(config)#ip route 10.10.10.0 255.255.255.0 172.16.10.5 150
LA(config)#ip route 172.16.10.0 255.255.255.252 172.16.10.5 150
LA(config)#ip route 192.168.10.0 255.255.255.0 172.16.10.5 150

To show static routes on the Corp router

1) LA(config)#do show run


or
1) LA(config)#do show run | begin ip route

2) LA(config)#do show ip route

CNW CSE4541 IPR


Default Routing
Default route is used by IP to forward any packet with a destination not found
in the routing table, which is why it is also called a gateway of last resort.
Syntax:
ip route 0.0.0.0 0.0.0.0
[next-hop_address or ExitInterface Name]
[administrative_distance] [permanent]

Example: Default Route at R1


R1 R2

192.168.10.0/24
Gig0/0/0 Gig0/1/0
10.10.10.0/30
10.10.10.1
Next hop address:
Exit Interface
at R1 towards R2 Next hop

ip route 0.0.0.0 0.0.0.0 10.10.10.1


or
ip route 0.0.0.0 0.0.0.0 Gig0/0/0
CNW CSE4541 IPR
Default Route at LA Router

To remove static route: no ip route command

LA#config t
LA(config)#no ip route 10.10.10.0 255.255.255.0 172.16.10.5 150
LA(config)#no ip route 172.16.10.0 255.255.255.252 172.16.10.5
150
LA(config)#no ip route 192.168.10.0 255.255.255.0 172.16.10.5 150

Adding default route:ip route command

LA#config t
LA(config)#ip route 0.0.0.0 0.0.0.0 172.16.10.5

To show Routing Table:

LA#config t
LA(config)#do sho ip route

CNW CSE4541 IPR


Verifying Configuration at Routers

show ip route and ping command


(1) Corp#do sho ip route

(2) Corp#ping 192.168.10.1

(3) Corp#ping 192.168.20.1

CNW CSE4541 IPR


Dynamic Routing

Dynamic routing is when protocols are used to find networks and update
routing tables on routers.
This is whole lot easier than using static or default routing, but it will cost
you in terms of router CPU processing and bandwidth on network links.
A routing protocol defines the set of rules used by a router when it com-
municates routing information between neighboring routers.
Two types of routing protocols are used in internetworks: interior gateway
protocols (IGPs) and exterior gateway protocols (EGPs).
IGPs are used to exchange routing information with routers in the same
autonomous system (AS). An AS is either a single network or a collec-
tion of networks under a common administrative domain, which basically
means that all routers sharing the same routing-table information are in
the same AS. Examples: RIP, OSPF etc.
EGPs are used to communicate between ASs. An example of an EGP
is Border Gateway Protocol (BGP)

CNW CSE4541 IPR


RIP at Corp Router

Static Route:

Corp#config t
Corp(config)#ip route 192.168.10.0 255.255.255.0 172.16.10.2 150
Corp(config)#ip route 192.168.20.0 255.255.255.0 s0/1 150

Now shifted to RIP routing in stead of static route:

Corp#config t
Corp(config)#router rip
Corp(config-router)#network 10.0.0.0
Corp(config-router)#network 172.16.0.0
Corp(config-router)#version 2

CNW CSE4541 IPR


How RIP Works?

CNW CSE4541 IPR


How RIP Works?

CNW CSE4541 IPR


How RIP Works?

CNW CSE4541 IPR


Review Questions
1. You are viewing the routing table and you see an entry 10.1.1.1/32. What
legend code would you expect to see next to this route?

(A) C (C) S
(B) L (D) D

2. Which of the following is not an advantage of static routing?

(A) Less overhead on the (C) Adds security


router CPU
(B) No bandwidth usage be- (D) Recovers automatically
tween routers from lost routes

3. If your routing table has a static, an RIP, and an EIGRP route to the same
network, which route will be used to route packets by default?

(A) Any available route (D) EIGRP route


(B) RIP route
(C) Static route (E) They will all load-balance.

CNW CSE4541 IPR


Routing: The begin−→

CNW CSE4541 IPR

You might also like