0% found this document useful (0 votes)
3 views10 pages

Network Routing

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)
3 views10 pages

Network Routing

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

3.

1 Router Overview
A router is a network device that forwards data packets between computer networks. Routers
work at the Network Layer (Layer 3) of the OSI model and are responsible for determining the
best path for data to travel across interconnected networks. Routers use routing tables, protocols,
and algorithms to make decisions on packet forwarding.
Functions of a Router:
- Packet Forwarding: Directs data from source to destination through the most efficient route.
- Routing Tables: Maintain the routes for data transfer across networks.
- Interconnecting Networks: Connects different network segments and ensures communication
between them.
3.2 Static Routing
Static Routing involves manually configuring the router’s routing table with predefined paths.
These paths do not change unless the network administrator modifies them. Static routes are
simple to configure but are not flexible in dealing with network topology changes.
Advantages of Static Routing:
- Simple and Easy to Configure: Ideal for small networks with a simple topology.
- Low Overhead: No need for additional protocols or bandwidth to maintain the routes.
- Predictable Routing Paths: The administrator defines exactly which path data will follow.
Disadvantages of Static Routing:
- Scalability Issues: In large networks, managing static routes can become difficult.
- Lack of Adaptability: If a network failure occurs, static routing does not automatically reroute
traffic, requiring manual intervention.
Example of Static Routing:
If a router needs to route traffic from network `[Link]/24` to `[Link]/24` via a gateway
at `[Link]`, the static route command would be:
ip route [Link] [Link] [Link]
3.3 Dynamic Routing
Dynamic Routing allows routers to automatically learn and update routing tables using routing
protocols. These protocols enable routers to exchange routing information and adapt to changes
in network topology. Popular dynamic routing protocols include RIP, OSPF, EIGRP, and BGP.
Advantages of Dynamic Routing:

Page 1 of 10
- Automatic Updates: Routes are updated automatically, reducing administrative overhead.
- Scalability: Suitable for larger networks as it can adjust to changes without manual
intervention.
- Fault Tolerance: Dynamic protocols can automatically reroute traffic in case of network
failures.
Disadvantages of Dynamic Routing:
- Complexity: Configuration can be more complicated than static routing.
- Overhead: Requires additional CPU and memory resources to process routing updates.
- Convergence Time: It may take time for the network to adapt after a topology change.
Example of Dynamic Routing:
An example using OSPF (Open Shortest Path First) to advertise routes would involve the
command:
router ospf 1
network [Link] [Link] area 0
3.4 Introduction to Classless Routing
Classless Routing refers to routing protocols that do not rely on traditional classful IP addressing,
allowing for more flexible subnetting. Classless Inter-Domain Routing (CIDR) is a method used
to allocate IP addresses and route Internet Protocol packets more efficiently.
Key Concepts in Classless Routing:
- CIDR Notation: It represents an IP address and its associated network mask in the format
`IP_address/Prefix_Length` (e.g., `[Link]/24`).
- Variable Length Subnet Masking (VLSM): CIDR allows variable-length subnet masks,
enabling more efficient use of IP address space.
- Support for Subnetting: Classless routing allows routers to use any subnet mask, not just the
standard class-based ones (Class A, B, or C).
Advantages of Classless Routing:
- Efficient IP Addressing: Allows for more efficient distribution of IP addresses.
- Better Utilization of Address Space: More flexible allocation of IPs, especially for
organizations with varying network sizes.

Page 2 of 10
Example of Classless Routing: In classless routing, the prefix `[Link]/26` means the
network has 64 IP addresses, and it can be used for more specific routing without relying on
default class-based boundaries.
Static Routing Example Diagram: This diagram shows how a static route directs traffic
between two networks through a gateway router.

Dynamic Routing Example Diagram (OSPF): Here, OSPF dynamically updates routes
between two routers in a network.

Classless Routing Example Diagram: A network with CIDR notation and variable subnetting.

These diagrams illustrate how static and dynamic routing work in practice, as well as how
classless routing supports more efficient and flexible network design.
3.5 Distance Vector Routing Protocols
Distance vector routing protocols are a type of routing protocol where routers exchange
information about the distance (or cost) to reach destination networks. These protocols use

Page 3 of 10
metrics like hop count, which is the number of routers a packet must pass through to reach its
destination.
Key Features of Distance Vector Routing:
- Routing Table: Each router maintains a routing table containing destinations and the distance to
those destinations.
- Periodic Updates: Routers periodically send updates to their neighbors, announcing the routes
they know.
- Hop Count: A common metric for distance vector protocols, representing the number of routers
between the source and the destination.
- Bellman-Ford Algorithm: This is used to calculate the shortest path to a destination.
Common Distance Vector Routing Protocols:
- RIP (Routing Information Protocol): Uses hop count as its metric. RIP version 2 (RIPv2) also
supports classless inter-domain routing (CIDR) and multicast.
- IGRP (Interior Gateway Routing Protocol): Used in older Cisco networks, now replaced by
EIGRP.
- EIGRP (Enhanced Interior Gateway Routing Protocol): A hybrid protocol, combining features
of distance vector and link-state protocols.
Example of Distance Vector Routing (RIP):
Let's assume there are three routers: Router A, Router B, and Router C. Initially, Router A only
knows about itself, Router B knows about itself and Router A, and Router C knows about itself.
Over time, they exchange their routing tables, and Router A learns about Router C through
Router B.

3.6 Router Administrative Configurations


Router administrative configurations involve setting up various aspects of a router to ensure it
works efficiently in a network environment. These configurations can include network
interfaces, routing protocols, security policies, and management settings.
Basic Router Administrative Tasks:
- Hostname: Set the router's name for easier identification in the network.

Page 4 of 10
- Interface Configuration: Configure IP addresses for each interface.
- Routing Protocols: Enable routing protocols like RIP, OSPF, or EIGRP.
- Access Control Lists (ACLs): Define rules to control traffic flow.
- Password Configuration: Set passwords for console, auxiliary, and virtual terminal (VTY) lines
for remote access.
Example Commands for Administrative Configurations:
```bash
Router(config)# hostname Router1
Router1(config)# interface GigabitEthernet0/1
Router1(config-if)# ip address [Link] [Link]
Router1(config-if)# no shutdown
Router1(config)# router rip
Router1(config-router)# network [Link]
Router1(config-router)# version 2
3.7 Router Interfaces
Router interfaces are physical or logical connections used by the router to communicate with
other devices on the network. Each interface on a router must be assigned an IP address and
subnet mask to participate in routing decisions.
Types of Router Interfaces:
- Ethernet: Common for connecting to local networks.
- Serial: Often used for wide-area network (WAN) connections.
- Loopback: Virtual interface for testing purposes.
- Tunnel: Logical interfaces for VPNs or other encapsulation technologies.
Example Configuration of Router Interface:
```bash
Router1(config)# interface GigabitEthernet0/0
Router1(config-if)# ip address [Link] [Link]
Router1(config-if)# no shutdown

Page 5 of 10
3.8 Viewing, Saving, and Erasing Configurations
Managing the router configuration involves viewing, saving, and erasing the configuration files.
These tasks ensure the router functions as expected and any changes are stored or discarded
based on the requirements.
Viewing Configurations:
To view the router configuration, the following command is used:
```bash
Router1# show running-config
This shows the current configuration that is running on the router.
Saving Configurations:
After making changes, it's important to save the configuration to the startup configuration file, so
it persists after a reboot:
```bash
Router1# copy running-config startup-config
Erasing Configurations:
If you need to erase the current configuration and reset the router to its default state, use the
following command:
```bash
Router1# write erase
Router1# reload
This removes the startup configuration and reloads the router, effectively restoring it to factory
settings.
Example for Configuration Flow:

Page 6 of 10
3.9 Routing Information Protocol (RIP)
RIP is one of the oldest routing protocols and is used for determining the best path based on hop
count. It is a distance-vector protocol, meaning it determines the best route by counting the
number of hops (routers passed through) to the destination.
Characteristics of RIP:
- Hop Count: Maximum hop count is 15. A network with more than 15 hops is considered
unreachable.
- Updates: RIP sends updates every 30 seconds, regardless of changes in the network.
- Versions: RIP v1 (doesn't support VLSM) and RIP v2 (supports VLSM).
RIP Configuration Example:
To configure RIP on a router, you would enter the following commands:
```bash
Router# configure terminal
Router(config)# router rip
Router(config-router)# version 2
Router(config-router)# network [Link]
Router(config-router)# network [Link]
Router(config-router)# no auto-summary
Router(config-router)# exit
Router(config)# exit

3.9 Enhanced Interior Gateway Routing Protocol (EIGRP)


EIGRP is a Cisco proprietary protocol that combines the best features of both link-state and
distance-vector protocols. It uses a composite metric based on bandwidth, delay, load, and
reliability to choose the best path.
Characteristics of EIGRP:

Page 7 of 10
- Distance Vector Protocol: Though it behaves like a distance-vector protocol, EIGRP also has
some features of link-state protocols.
- Metric Calculation: EIGRP uses a composite metric based on bandwidth and delay.
- Protocol Support: EIGRP supports IPv4, IPv6, and other network protocols.
EIGRP Configuration Example:
```bash
Router# configure terminal
Router(config)# router eigrp 100
Router(config-router)# network [Link] [Link]
Router(config-router)# network [Link] [Link]
Router(config-router)# no auto-summary
Router(config-router)# exit
Router(config)# exit
Diagram:

3.10 Open Shortest Path First (OSPF)


OSPF is a link-state routing protocol used in large enterprise networks. It sends link-state
advertisements (LSAs) to other routers, which then build a complete map of the network
topology. OSPF uses the Shortest Path First (SPF) algorithm to determine the best path.
Characteristics of OSPF:
- Link-State Protocol: Routers exchange full topology information to determine the best path.
- Area-based Design: OSPF divides the network into areas for scalability.
- Cost Metric: OSPF uses cost as a metric, which is based on bandwidth (lower cost for higher
bandwidth).
- Faster Convergence: OSPF converges faster compared to RIP and EIGRP.
OSPF Configuration Example:
```bash

Page 8 of 10
Router# configure terminal
Router(config)# router ospf 1
Router(config-router)# network [Link] [Link] area 0
Router(config-router)# network [Link] [Link] area 0
Router(config-router)# exit
Router(config)# exit
Diagram:

Comparison Table
Feature RIP EIGRP OSPF
Protocol Type Distance Vector Hybrid (Distance-Vector + Link-State
Link-State)
Metric Hop Count Composite (Bandwidth, Cost (Bandwidth)
Delay)
Convergence Slow Fast Very Fast
Speed
Scalability Low (max 15 hops) High High
Classful/ Classful (RIP v1) Classless Classless
Classless
Updates Periodic (every 30 Triggered updates Event-based (LSA
seconds) updates)
Security Simple Password MD5 Authentication OSPF Authentication
Routing Table Example:
RIP:
R1# show ip route rip
[Link]/24 [120/1] via [Link], 00:00:21, Serial0
[Link]/24 [120/1] via [Link], 00:00:22, Ethernet0
EIGRP:
R1# show ip route eigrp

Page 9 of 10
D [Link]/24 [90/307200] via [Link], 00:00:21, Ethernet0
D [Link]/24 [90/307200] via [Link], 00:00:22, Serial0
OSPF:
R1# show ip route ospf
O [Link]/24 [110/2] via [Link], 00:00:21, Serial0
O [Link]/24 [110/2] via [Link], 00:00:22, Ethernet0

Page 10 of 10

You might also like