COMPUTER NETWORKS
(DCO-513)
Program 4: Write in detail about Router and also write it’s types and functionality.
Submitted by:
UMAIR RIAZ
Roll. No. 16-DCS-067
Diploma in Computer Engineering- V Semester
Computer Engineering Section
University Polytechnic, Faculty of Engineering and Technology
Jamia Millia Islamia (A Central University)
New Delhi-110025
Session 2018-2019
ROUTER
A Router is a computer, just like any other computer including a PC. Routers have many of the same
hardware and software components that are found in other computers including:
• CPU
• RAM
• ROM
• Operating System
Router is the basic backbone for the Internet. The main function of the router is to connect two or more
than two network and forwards the packet from one network to another. A router connects multiple
networks. This means that it has multiple interfaces that each belong to a different IP network. When a
router receives an IP packet on one interface, it determines which interface to use to forward the packet
onto its destination. The interface that the router uses to forward the packet may be the network of the
final destination of the packet (the network with the destination IP address of this packet), or it may be a
network connected to another router that is used to reach the destination network.
Router connects two network
A router uses IP to forward packets from the source network to the destination network. The packets
must include an identifier for both the source and destination networks. A router uses the IP address of
the destination network to deliver a packet to the correct network. When the packet arrives at a router
connected to the destination network, the router uses the IP address to locate the specific computer on
the network.
A router is connected to two or more data lines from different networks. When a data packet comes in on one of
the lines, the router reads the network address information in the packet to determine the ultimate destination.
Then, using information in its routing table or routing policy, it directs the packet to the next network on its
journey.
The most familiar type of routers are home and small office routers that simply forward IP packets between the
home computers and the Internet. An example of a router would be the owner's cable or DSL router, which
connects to the Internet through an Internet service provider (ISP). More sophisticated routers, such as enterprise
routers, connect large business or ISP networks up to the powerful core routers that forward data at high speed
along the optical fiber lines of the Internet backbone. Though routers are typically dedicated hardware devices,
software-based routers also exist.
Types of router
The two major types of routers are:
Static Static routers require an administrator to manually set up and configure the routing table and to
specify each route.
Dynamic Dynamic routers are designed to discover routes automatically and therefore require a minimal
amount of setting up and configuration. More sophisticated than static routers, they examine information
from other routers and make packet-by-packet decisions about how to send data across the network.
Routing
The primary responsibility of a router is to direct packets destined for local and remote networks by:
• Determining the best path to send packets
• Forwarding packets toward their destination
The router uses its routing table to determine the best path to forward the packet. When the router receives
a packet, it examines its destination IP address and searches for the best match with a network address
in the router's routing table. The routing table also includes the interface to be used to forward the packet.
Once a match is found, the router encapsulates the IP packet into the data link frame of the outgoing or
exit interface, and the packet is then forwarded toward its destination.
Static Routes:
Static routes are configured manually, network administrators must add and delete static routes to reflect
any network topology changes. In a large network, the manual maintenance of routing tables could
require a lot of administrative time. On small networks with few possible changes, static routes require
very little maintenance. Static routing is not as scalable as dynamic routing because of the extra
administrative requirements. Even in large networks, static routes that are intended to accomplish a
specific purpose are often configured in conjunction with a dynamic routing protocol.
When to use static Routing:
A network consists of only a few routers. Using a dynamic routing protocol in such a case does not present
any substantial benefit. On the contrary, dynamic routing may add more administrative overhead.
A network is connected to the Internet only through a single ISP. There is no need to use a
dynamic routing protocol across this link because the ISP represents the only exit point to the Internet.
A large network is configured in a hub-and-spoke topology. A hub-and-spoke topology consists of a
central location (the hub) and multiple branch locations (spokes), with each spoke having only one
connection to the hub. Using dynamic routing would be unnecessary because each branch has only one
path to a given destination- through the central location.
Connected Routes:
Those network that are directly connected to the Router are called connected routes and are not needed
to configure on the router for routing. They are automatically routed by the Router.
Dynamic Routes:
Dynamic routing protocol uses a route that a routing protocol adjusts automatically for topology or
traffic changes.
non-adaptive routing algorithm When a ROUTER uses a non-adaptive routing algorithm it consults
a static table in order to determine to which computer it should send a PACKET of data. This is in
contrast to an ADAPTIVE ROUTING ALGORITHM, which bases its decisions on data which reflects
current traffic conditions (Also called static route)
adaptive routing algorithm When a ROUTER uses an adaptive routing algorithm to decide the next
computer to which to transfer a PACKET of data, it examines the traffic conditions in order to
determine a route which is as near optimal as possible. For example, it tries to pick a route which
involves communication lines which have light traffic. This strategy is in contrast to a NON-
ADAPTIVE ROUTING ALGORITHM. (Also called Dynamic route).
Function of an Router
All of these networks rely on NAPs, backbones and routers to talk to each other. What is incredible about this
process is that a message can leave one computer and travel halfway across the world through several different
networks and arrive at another computer in a fraction of a second!
The routers determine where to send information from one computer to another. Routers are specialized
computers that send your messages and those of every other Internet user speeding to their destinations along
thousands of pathways. A router has two separate, but related, jobs: