Post on 26-Dec-2015
1
Routing
Introduction to Routing
Static Routing
2
Objectives
• Review• IP Addressing
• Introduction to • Routing
• Static Routing• Dynamic Routing overview• Examples – static routing
3
Data Forwarding
How to send information to a distant host? What path is it sent on?
How to find the path?
When a computer wants to send data, how does the sending computer know if the Destination computer is on the same network?
Host A Host B Host C
LAN 1
hostF hostD hostE
LAN 2router router routerWA
NWAN
128.2.254.15/24 112.32.224.60/24128.2.254.11/24
4
Review – IP Addressing
What do all devices on a LAN segment have in common?
Host Stevens: 172.16.10.10 255.255.255.0 172.16.10.0
Host Cerf:
172.16.10.25
255.255.255.0
172.16.10.0
Host Perlman
172.16.20.12
255.255.255.0
172.16.20.0
5
Data Flow Through a Network
6
Routers –Interfaces
Routers have LAN interfaces
Ethernet interfaces: Have MAC Addresses IP addresses
WAN interfaces Serial interfaces Have IP addresses
Serial 0
192.168.10.1 255.255.255.252
Ethernet 1172.16.2.1/ 255.255.255.0 MAC: 0abbccddeeff
Ethernet 0
172.16.1.1/ 255.255.255.0 MAC: 0cddeeffaabb
7
What is Routing?
Routing - Selecting the correct path towards destination Build Routing table for path
selection Two methods
Static Dynamic
Router
1
23
0111
value in arrivingpacket’s header
routing algorithm
local forwarding table
header value output link
0100010101111001
3221
8
Static Routes
A network administrator manually enters route into the router's configuration When network only consists of a few routers -Network is connected to internet only through one
ISP route entry manually updated whenever network
topology changes Static routing reduces overhead Better security
9
Dynamic Routes
Route knowledge is updated automatically by a routing process whenever new information is received from the network.
10
Routing Table Structure Routing Table is stored in RAM
and contains information about: Directly connected networks
when a device is connected to another router interface
Remotely connected networks network that is not
directly connected to a particular router
Show ip route command is used to view a routing table
11
Static Routes
Specifying Outgoing Interface
12
Static Routes
Specifying the Next-hop IP Address
13
Routing Table Structure
Static routes in the routing table -Includes: network
address and subnet mask
IP address of next hop router or exit interface
Denoted with the code S in the routing table
14
Review: Default Gateway
When a LAN is connected to a Router, Default Gateway is the address of router interface connected to that LAN.
The IP address and subnet mask is on the same network as the hosts on that network
Router
LAN
Router
Default Gateway
15
Static Routes
Verifying Static Route Configuration: The command show running-config is used to
view the active configuration in RAM to verify that the static route was entered correctly.
The show ip route command is used to make sure that the static route is present in the routing table.
16
Static Routes
• Troubleshooting Static Route Configuration:• The show interfaces command• The ping command• The traceroute command
17
Review: Cisco Router backplane Identify the different interfaces on router
Interface 1 Interface 2 Interface 3 Interface 4
Serial interface
console interfaceEthernet interface
Interface 1 Interface 2
Interface 3
Interface 4
18
Review: Establishing a Hyper-terminal Session
• All Cisco routers include an EIA/TIA-232 asynchronous serial console port (RJ-45).
• How do you connect to router to configure?
• Router configured from PC connected to router console port using a rollover cable
• Rollover cable has•Serial interface adapter on one side and •RJ45 adapter on the other
PC
Serial adapter
RJ45 adapter
19
Connections to the Router- cables
Connections of a Router for Ethernet 2 types of cables can be used:
Straight through and Cross-over Straight through used to connect
dissimilar devices Switch-to-Router, Switch-to-PC,
Cross-over used to connect
similar devices: Switch-to-Switch, Router to PC (Host) PC-to-PC, Switch-to-Hub, Hub-to-Hub, Router-to-Router
Cross-over Straight-thru
Straight-thru
20
Configuring router Interfaces
-By default all interfaces are down Ethernet Serial
Interface configured with IP address and subnet mask
No Shutdown command used to enable the interface
Ethernet interface
21
To configure an Ethernet interface -Enter interface configuration mode (config) -Enter IP address and subnet mask -Enter no shutdown command Example:
-R2(config)#interface fastethernet 0/0 -R2(config-if)#ip address 172.16.1.1 255.255.255.0 -R2(config-if)#no shutdown
Configuring Interfaces –Ethernet Interface