ROUTING ? 5 MINUTES ARE MORE THAN ENOUGH
Monday, September 1, 2008
CREDIT @ SPACY FREAK
As a candidate for CCNA Certification, one of main topics is ROUTING.
What is routing? What is difference between routing and switching?
Questions over Questions!
Here comes OSI Model (or TCP/IP, what is a "little" OSI Model) into the game.
Switches only work at Layer 2 (Datalink layer).
They dont need an IP-Address to do their job. Switches are only interested in MAC Addresses.
They learn the mac-address of connected pcs and write them in their mac-table.
Switches can only be used to connect devices, which are in the same subnet.
If we want to bring traffic from one subnet to another subnet, we need a router between the subnets.
The router holds a routing table. In the routing table are entries, which say, over which of the router ports a paket with a specific destination IP-Address has to be send.
Read slowly the following sentences, and then read them again.
Routing protocols are used to route a routed protocol. Routed Protocols are IP or IPX.
Routing protocols are used by routers to select best path to destination.
Routing protocols are used to send routing information to other routers.
There are three different "Types" of Routing Protocols
1. Distance Vector Routing
RIP1 RIP2 and IGRP
-advantage RIP: RIP is simple to configure, and works on all routers (compatibility)
-disadvantage:no VLSM support, higher bandwidth waste, metric is very simple and unintelligent
-RIP1 and IGRP do not support VLSM (Variable Length Subnet Mask) and so do not send Subnetmask Information via Route-Updates
-sends entire Routing-Table to directly connected Neighbours
-RIP uses as Metric (for best Path Selection) "Hopcounts".
A Hop is a router in the Path.
If there are 5 routers on the path to a destination, and 3 routers on another path,
the second route will be choosen, because it has less Hops to destination.
Maximum Hop Counts are 15 in RIP.
-IGRP uses "cost" as Metric. Dependent on Bandwidth and Delay is the best path selected.
-variance and traffic-share commands can be used for loadbalancing on IGRP
-IGRP maximum Hopcount is 255.
-IGRP is proprietary, can only be used between Cisco Routers.
2. Hybrid Routing
EIGRP
-rapid convergence
-reduces bandwidth useage on routing updates
-supports multiple network layer protocols (apple talk, ipx, ip)
-supports VLSM
-EIGRP uses same metrics as IGRP; Delay, Bandwidth, Reliability and Load. By default, only Delay and Bandwidth
-Only EIGRP Routers of the same Autonoumous System exchange Routingupdates.
-Maximum Hopcount is 255.
-EIGRP is proprietery, only between Cisco Routers useable.
EIGRP Tables:
1. Neighbour table
-lists adjacent routers, comparable to adjacencies database used by ospf
-only lists informations about directly connected neighbours
2. Topology table
-here are all route entries for all destinations that router has learned
-contains "Feasible Successors". These are backup routes, if "Successor Route" (which is primary route) fails.
3. Routing table
-the best route from topology table, becomes "Successor Route" or "Primary Route" and is choosen to forward traffic to destinations.
The "successor" is placed in topology table, and also in routing table!!!
Feasible successors (backup routes) are only saved in topology table. (ICND Book page 3-101)
The selection which feasible successor will become new successor, if successor fails, is done with DUAL (Diffusing Update Algorithm).
3. Links State Routing
OSPF and ISIS
-OSPF:Hirarchical System. One or more "Areas" are connected to a "Backbone Area" which is Area 0.
-Routers send Linkstate-Informations to all other Routers of their area.
-The Link States are Informations of bandwidth and status of the routerinterfaces.
-Based on the LSAs all Routers build a Topology Database, which is a "Model" of the entire area.
-Djikstra Algorythm calculates from the Information in Topology Database the shortest path and creates the Routing Table.
-OSPF: Hopcounts unlimited
-Used in huge Networks
-supports VLSM
-ospf: useable area numbers go from <0-4294967295>
VLSM Support
IGRP and RIP v1 do NOT support variable length subnet mask.
That means, no subnetmask information is sent to other routers via route-updates.
Also called "classfull" routing.
RIP v2, EIGRP, OSPF and ISIS support VLSM.
Administrative Distance
On a router can run more than one routing protocols in the same time.
The router has to decide, which of the configured protocols he will believe more.
That decisions are made with the aministrative distance.
The lower the AD is, the more will this route be prefered for selection of best path to destination.
0 Directly connected Interface
1 Static Route
90 EIGRP
100 IGRP
110 OSPF
120 RIP
How to configure...
1. RIP
router rip
network 132.43.54.0
network 145.65.76.0
The network command defines the networks hosted by THIS Router, depending on the IP of the Router Interfaces.
Networks of the other RIP routers will be learned by RIP updates.
2. IGRP
router igrp 33
network 134.43.54.0
network 143.56.76.0
The 33 is the Number of the Autonomous System.
Only IGRP Routers from the same AS exchange Routing Updates.
3. EIGRP
router eigrp 33
network 172.16.0.0
network 10.0.0.0
4. OSPF
router ospf 1
network 132.43.56.0 0.0.0.255 area 0
network 145.54.34.6 0.0.63.255 area 0
The 1 is the Process Number, which is only locally significant.
If there are more than one area, which represent a "part" of the hirarchy,
all areas must be connected to the backbone area.
5. Static Route
ip route 143.45.5.0 255.255.255.0 154.43.45.4 <
or
ip route 143.45.5.0 255.255.255.0 s0 <
6. Default Route or Gateway of last resort
ip route 0.0.0.0 0.0.0.0 143.45.65.6 <<<>
or
ip route 0.0.0.0 0.0.0.0 s0 <<
Means: Route all Pakets, for which are NO Routes in the Routing Table, over THIS Interface.
Troubleshooting:
To see in realtime, what a routing protocol is doing, give in command
debug ip ospf
To see the entries in routing table use command
show ip route
Check all active routing protocols with command
show ip protocols