Unit 3
Unit 3
( KCS-603 )
UNIT 3
Network Layer Design Goals
Computer Networks
Machine A Machine B
Application Application
Transport Transport
Router/Gateway
Internet Internet Internet
Network Network
Network
Interface Interface
Interface
Network 1 Network 2
Computer Networks
Network Layer Design Issues
• Store-and-forward packet switching
• Services provided to transport layer
• Implementation of connectionless service
• Implementation of connection-oriented service
• Comparison of virtual-circuit and datagram networks
Computer Networks
Design issues
• Store-and-forward packet switching
• Equipment of: carrier <> customer
• Algorithm at router
• Receive packet
• Check packet (e.g. checksum)
• Forward packet
Computer Networks
Design issues: services
• Interface
• Important: = interface between carrier and customer
• Designed with following goals in mind:
• Services should be independent of the subnet technology
• Transport layer should be shielded from the number, type,
topology of the subnets
• Network addresses should use a uniform numbering plan, even
across LANs and WANs
• Connections?
• Connection-oriented <> Connectionless!
Computer Networks
Design issues: services
• Connection-oriented <> Connectionless
• PTTs: connection-oriented
• 100 years of experience with the world-wide telephone
system
• Connection time billing!
• Internet
• Subnets are inherently unreliable
• Real issue: where to put the complexity as some/many
applications require reliable transfer (~ connection-
oriented service)
• Network layer
• Transport layer
Computer Networks
Design issues: services
• Connection-oriented <> Connectionless
(cont.)
• In favour of connectionless service
• Computing power is cheap: hosts can handle the
complexity
• Subnet is a large, long lasting investment: keep it
simple
• For some applications speedy delivery (low,
constant delay) is important
• In favour of connection-oriented service
• Users want a reliable trouble-free service
• Some services are easier to provide on top of
connection-oriented service
Computer Networks
Subnet Types
1. Virtual circuits (VC) - connection setup (choosing of the route to the
destination), forwarding packets over the exactly that route (the
router maintains a table with the unique virtual circuit # ), and
connection release (termination of the VC).
Computer Networks
• Virtual Circuit Network
• Routes chosen at connection time
• Connection identified by a virtual circuit number (VCn)
• Primary service of subnet is connection-oriented
Computer Networks
• Datagram subnet
• Each packet is routed independently
• Subnet has more work to do
• More robust, easier to adapt to failures and congestion
Computer Networks
- Rajat Verma
Desirable properties of a Routing Algorithm
Correctness and simplicity: The packets are to be correctly
delivered. Simpler the routing algorithm, it is better.
- Rajat Verma
Design Parameters of a Routing Algorithm
While designing a routing protocol it is necessary to take into
account the following design parameters:
Computer Networks
- Rajat Verma
Classification of a Routing Algorithm
Static versus Adaptive
Because static routing systems cannot react to network changes, they generally are
considered unsuitable for today's large, constantly changing networks. Most of the
dominant routing algorithms today are dynamic routing algorithms, which adjust to
changing network circumstances by analyzing incoming routing update messages. If the
message indicates that a network change has occurred, the routing software
recalculates routes and sends out new routing update messages. These messages
permeate the network, stimulating routers to rerun their algorithms and change their
routing tables accordingly. Dynamic routing algorithms can be supplemented with static
routes where appropriate.
- Rajat Verma
Single-Path versus Multi-path
This division is based upon the number of paths a router stores for a single
destination. Single path algorithms are where only a single path (or rather
single next hop) is stored in the routing table. Some sophisticated routing
protocols support multiple paths to the same destination; these are known as
multi-path algorithms. Unlike single-path algorithms, these multipath
algorithms permit traffic multiplexing over multiple lines. The advantages of
multipath algorithms are obvious: They can provide substantially better
throughput and reliability. This is generally called load sharing.
- Rajat Verma
Flat Versus Hierarchical
Some routing algorithms operate in a flat space, while others use routing hierarchies.
In a flat routing system, the routers are peers of all others. In a hierarchical routing
system, some routers form what amounts to a routing backbone. Packets from non-
backbone routers travel to the backbone routers, where they are sent through the
backbone until they reach the general area of the destination. At this point, they travel
from the last backbone router through one or more non-backbone routers to the final
destination.
Routing systems often designate logical groups of nodes, called domains, autonomous
systems, or areas. In hierarchical systems, some routers in a domain can communicate
with routers in other domains, while others can communicate only with routers within
their domain.
In very large networks, additional hierarchical levels may exist, with routers at the
highest hierarchical level forming the routing backbone. The primary advantage of
hierarchical routing is that it mimics the organization of most companies and therefore
supports their traffic patterns well. Most network communication occurs within small
company groups (domains). Because intradomain routers need to know only about
other routers within their domain, their routing algorithms can be simplified, and,
depending on the routing algorithm being used, routing update traffic can be reduced
accordingly.
- Rajat Verma
Host-Intelligent Versus Router-Intelligent
This division is on the basis of whether the source knows about the
entire route or just about the next-hop where to forward the packet.
Some routing algorithms assume that the source end node will
determine the entire route. This is usually referred to as source routing.
In the first system, the hosts have the routing intelligence. In the latter
system, routers have the routing intelligence.
- Rajat Verma
Routing Algorithm Metrics
Routing tables contain information used by switching software to
select the best route. In this section we will discuss the different nature
of information they contain, and the way they determine that one route
is preferable to others? Routing algorithms have used many different
metrics to determine the best route. Sophisticated routing algorithms
can base route selection on multiple metrics, combining them in a single
(hybrid) metric.
- Rajat Verma
Routing Algorithms
Properties
Shortest Path Routing
Flooding
Distance Vector Routing Most important
Link State routing
algorithms!
Hierarchical routing
Broadcast routing
Multicast routing
Routing for mobile hosts
Routing in Ad Hoc Networks
Node Lookup in Peer-to-Peer Networks
Computer Networks
- Rajat Verma
Optimality principle: sink tree
Destination
Computer Networks
- Rajat Verma
Routing: shortest path
Algorithm of Dijkstra: shortest path in graph
o Graph
• Node = router
• Arc = communication line
o Metric
• Number of hops
• Geographic distance
• Mean queueing and transmission delay
Computer Networks
- Rajat Verma
Routing: shortest path
Initial node
Elements of algorithm:
• Mark all nodes as free:
• Mark initial node as selected:
• repeat till destination is selected:
•Label all free nodes reachable from selected nodes with shortest
distance to a selected node
•Select free node with shortest distance to a selected node and
mark it as selected
Computer Networks
- Rajat Verma
Routing: shortest path
Computer Networks
- Rajat Verma
Routing: flooding
Flooding requires no network information whatsoever. Every incoming
packet to a node is sent out on every outgoing line except the one it
arrived on. All possible routes between source and destination are tried.
A packet will always get through if a path exists. As all routes are tried, at
least one packet will pass through the shortest route. All nodes, directly
or indirectly connected, are visited. Main limitation flooding is that it
generates vast number of duplicate packets. It is necessary to use
suitable damping mechanism to overcome this limitation. One simple is
to use hop-count; a hop counter may be contained in the packet header,
which is decremented at each hop, with the packet being discarded when
the counter becomes zero. The sender initializes the hop counter. If no
estimate is known, it is set to the full diameter of the subnet. Another
approach is keep track of packets, which are responsible for flooding
using a sequence number and avoid sending them out a second time. A
variation, which is slightly more practical, is selective flooding. The
routers do not send every incoming packet out on every line, only on
those lines that go in approximately in the direction of destination.
Computer Networks
- Rajat Verma
Routing: flooding
Some of the important utilities of flooding are:
Flooding is highly robust, and could be used to
send emergency messages (e.g., military
applications).
It may be used to initially set up the route in a
virtual circuit.
Flooding always chooses the shortest path, since
it explores every possible path in parallel.
Can be useful for the dissemination of important
information to all nodes (e.g., routing
information).
Computer Networks
- Rajat Verma
Routing: flooding
Computer Networks
- Rajat Verma
Routing Algorithms
Properties
Shortest Path Routing
Flooding
Distance Vector Routing Most important
Link State routing
algorithms!
Hierarchical routing
Broadcast routing
Multicast routing
Routing for mobile hosts
Routing in Ad Hoc Networks
Node Lookup in Peer-to-Peer Networks
Computer Networks
- Rajat Verma
Routing: Distance Vector
Distance vector algorithms (also known as Bellman-Ford
algorithms) is a Adaptive algorithm.
Computer Networks
- Rajat Verma
Routing: Distance Vector (contd.)
Routing table for A
To cost via
A 0 -
B 12 B
C 25 B
D 40 B
E 14 E
F 23 E
G 18 B
H 17 J
I 21 E
J 9 J
K 24 J
L 29 J
Computer Networks
- Rajat Verma
Routing: Distance Vector (contd.)
Algorithm
o At each step within a router:
• Get routing tables from neighbours
• Compute distance to neighbours
• Compute new routing table
o Characteristics:
• Iterative
• Asynchronous
• Distributed
Computer Networks
- Rajat Verma
Routing: Distance Vector (contd.)
Computer Networks
- Rajat Verma
Routing: Distance Vector (contd.)
Distributed algorithm
o Triggers:
• Change in delay to neighbour
• Receive new table from neighbour
o Update local tables
o If changed: forward routing tables to neighbours
Asynchronous
Iterative
o Stops? How fast are changes propagated?
• Good news?
• Bad news?
Computer Networks
- Rajat Verma
Routing: Distance Vector (contd.)
Count to Infinity Problem
Good news:
• A comes up again
Only distances to A
Computer Networks
- Rajat Verma
Routing: Distance Vector (contd.)
Count to Infinity Problem
Bad news:
• A goes down
Loops!!
Slow!!
= 5?
Computer Networks
- Rajat Verma
Routing: Link State
Key Features:
Computer Networks
- Rajat Verma
Routing: Link State
Overview of algorithm:
Each router must
o Discover its neighbours and learn their network
addresses
o Measure the delay or cost to each of its neighbours
o Construct a packet with these distances
o Send this packet to all other routers
o Compute the shortest path to every other router
Computer Networks
- Rajat Verma
Routing: Link State (contd.)
Algorithm:
Learning about neighbours:
o Upon boot of router
• Send HELLO packet on each point-to-point line
• Routers are supposed to send reply with a globally unique
name
o LAN
model
Computer Networks
- Rajat Verma
Routing: Link State (contd.)
Algorithm:
Building link state packets
o Packet containing: o When to build?
• Identity of sender • periodically
Computer Networks
- Rajat Verma
Routing: Link State (contd.)
Distributing link state packets
o Trickiest part of algorithm Algorithm:
• Arrival time for packets different
• How to keep consistent routing tables
o Basic algorithm
• Flooding +
• Sequence number (in each packet) to limit duplicates
o Manageable problems
• Wrap around of sequence numbers:
• Wrong sequence number used:
– lost in case of crash
– Corruption
o Refinements
• Link state packets are not forwarded immediately
• During holding time:
– duplicates are discarded
– Old packets are thrown out
Computer Networks
- Rajat Verma
Packet buffer for router B
Routing: Link State (contd.) o ACK flag: ACK to send
o Send flag: packet to forward
Computer Networks
- Rajat Verma
Routing: Link State (contd.)
Algorithm:
Computing new routes:
o With a full set of link state packets, a router can:
• Construct the entire subnet graph
• Run Dijkstra’s algorithm to compute the shortest path
to each destination
o Problems for large subnets
• Memory to store data
• Compute time
Computer Networks
- Rajat Verma
Differentiate between
Link State and Distance Vector routing algorithms
Link-state algorithms (also known as shortest path first algorithms)
flood routing information to all nodes in the internetwork. Each
router, however, sends only the portion of the routing table that
describes the state of its own links. In link-state algorithms, each
router builds a picture of the entire network in its routing tables.
Computer Networks
- Rajat Verma
Smilarities of Link State and Distance Vector
routing algorithms
Shortest-path routing
o Metric-based, using link weights
o Routers share a common view of how good a path is
As such, commonly used inside an organization
o RIP and OSPF are mostly used as intradomain protocols
o E.g., Princeton uses RIP, and AT&T uses OSPF
But the Internet is a “network of networks”
o How to stitch the many networks together?
o When networks may not have common goals
o … and may not want to share information
Computer Networks
- Rajat Verma
Hierarchical routing
Interdomain routing
Intradomain routing
Computer Networks
- Rajat Verma
Path Vector Routing
is similar to distance vector routing
Assuming that there is one node in each AS that acts as
on behalf of the entire AS : Speaker Node
Speaker node creates a routing table and advertises it
speaker nodes in the neighboring ASs
o advertising the path, not the metric of the nodes
Computer Networks
- Rajat Verma
Path Vector Routing (cont’d)
Initialization
o Each speaker node can know only the reachability of
nodes inside its AS
Computer Networks
- Rajat Verma
Path Vector Routing (cont’d)
Sharing and Updating
- AS3 -
- AS3 -
Computer Networks
- Rajat Verma
Popular Routing Protocols
RIP, OSPF, BGP
Dynamic protocols
o Sharing neighborhood information
Use different metrics.
RIP (one hop count, how many networks a packet crosses), Networks are
treated equally
BGP (depend on the policy, set by administrator)
OSPF (TOS, minimize delay, maximize throughput)
Computer Networks
- Rajat Verma
Popular Inter / Intra Domain Routing Protocols
RIP, OSPF, BGP
RIP (Routing Information Protocol) : treating each network
equals.
o The cost of passing through each network is the same.
• so if a packet passes through 10 networks to reach the destination,
the total cost is hop counts.
OSPF(Open Shortest Path First)
o allowing the administrator to assign a cost for passing through a
network based on the type of service required.
o A route through a network can have different costs (metrics)
BGP (Border Router Protocol)
o Criterion is the policy, which can be set by the administrator.
o Policy defines what paths should be chosen.
Static and Dynamic tables
Unicast Routing and Multicast Routing
Computer Networks
- Rajat Verma
Routing Information Protocol (RIP)
The Routing Information Protocol (RIP) is one of the most commonly used
Interior Gateway Protocol on internal networks which helps a router
dynamically adapt to changes of network connections by communicating
information about which networks each router can reach and how far away
those networks are. Although RIP is still actively used, it is generally
considered to have been obsolete by Link-state routing protocol such as OSPF.
As RIP is a distance vector routing protocol, it represents the routing
information in terms of the cost of reaching the specific destination. Circuit
priorities are represented using numbers between 1 and 15. This scale
establishes the order of use of links. The router decides the path to use base
on the priority list. Once the priorities are established, the information is
stored in a RIP routing table. Each entry in a RIP routing table provides a
variety of information, including the ultimate destination, the next hop on the
way to that destination, and a metric. The metric indicates the distance in
number of hops to the destination. Other information can also be present in
the routing table, including various timers associated with the route; these
timers will be discussed in the next section.
Computer Networks
- Rajat Verma
Routing Information Protocol (RIP) – contd.
Computer Networks
- Rajat Verma
Open Shortest Path First (OSPF) – contd.
OSPF is based on the SPF algorithm, which is also referred to as the
Dijkstra’s algorithm, named after the person credited with its creation.
OSPF is a link-state routing protocol that calls for the sending of link-
state advertisements (LSAs) to all other routers within the same
hierarchical area. Information on attached interfaces, metrics used, and
other variables are included in OSPF LSAs. As a link-state routing
protocol, OSPF contrasts with RIP, which are distance-vector routing
protocols.
Routers running the distance-vector algorithm send all or a portion of
their routing tables in routing-update messages only to their neighbors.
OSPF specifies that all the exchanges between routers must be
authenticated. It allows a variety of authentication schemes, even
different areas can choose different authentication schemes. The idea
behind authentication is that only authorized router are allowed to
advertise routing information.
OSPF include Type of service Routing. It can calculate separate routes for
each Type of Service (TOS), for example it can maintain separate routes to
a single destination based on hop-count and high throughput.
Computer Networks
- Rajat Verma
Open Shortest Path First (OSPF) – contd.
Computer Networks
- Rajat Verma
Border Gateway Protocol (BGP)
The Border Gateway Protocol (BGP) is an inter-autonomous
system routing protocol.
BGP is used to exchange routing information for the
Internet and is the protocol used between Internet service
providers (ISP), which are different ASes.
One of the most important characteristics of BGP is its
flexibility. The protocol can connect together any
internetwork of autonomous systems using an arbitrary
topology.
The only requirement is that each AS have at least one
router that is able to run BGP and that this router
connect to at least one other AS's BGP router. Beyond
that, “the sky's the limit,” as they say.
Computer Networks
- Rajat Verma
Border Gateway Protocol (BGP) – contd.
BGP can handle a set of ASs connected in a full mesh topology (each
AS to each other AS), a partial mesh, a chain of ASes linked one to the
next, or any other configuration. It also handles changes to topology
that may occur over time.
The primary function of a BGP speaking system is to exchange
network reachability information with other BGP systems. This
network reachability information includes information on the list of
Autonomous Systems (ASs) that reachability information traverses.
BGP constructs a graph of autonomous systems based on the
information exchanged between BGP routers.
As far as BGP is concerned, whole Internet is a graph of ASs, with each
AS identified by a Unique AS number. Connections between two ASs
together form a path and the collection of path information forms a
route to reach a specific destination. BGP uses the path information
to ensure the loop-free interdomain routing. Another important
assumption that BGP makes is that it doesn't know anything about
what happens within the AS. Computer Networks
- Rajat Verma
Border Gateway Protocol (BGP) – contd.
Computer Networks
- Rajat Verma
Comparison between RIP, OSPF and BGP
RIP OSPF BGP
Interior/Exterior? Interior Interior Exterior
Type Distance Vector Link-state Path Vector
Default Metric Hopcount Cost Multiple Attributes
Hop count Limit 15 None EBGP Neighbors: 1
(default) IBGP
Neighbors: None
Convergence Slow Fast Average
Update timers 30 seconds Only when changes occur; Only when changes
(LSA table is refreshed every occur
30 minutes, however)
Updates Full Table Only Changes Only Changes
Close loop: Protocols that allow system to enter congested state, detect
it, and remove it.
Open Loop solutions
The first category of solutions or protocols attempt to solve the
problem by a good design, at first, to make sure that it doesn’t
occur at all.
Once system is up and running, midcourse corrections are not
made. These solutions are somewhat static in nature, as the
policies to control congestion don’t change much according to
the current state of the system. Such Protocols are also known as
Open Loop solutions.
These rules or policies include deciding upon when to accept
traffic, when to discard it, making scheduling decisions and so on.
Main point here is that they make decision without taking into
consideration the current state of the network.
The open loop algorithms are further divided on the basis of
whether these acts on source versus that act upon destination.
Closed Loop solutions
Closed loop solutions are based on the concept of feedback.
During operation, some system parameters are measured and
feed back to portions of the subnet that can take action to
reduce the congestion.
This arrangement can be simulated in the operating system or can be built into the
hardware. Implementation of this algorithm is easy and consists of a finite queue.
Whenever a packet arrives, if there is room in the queue it is queued up and if there
is no room then the packet is discarded.
Figure a) Leaky bucket
Figure b) Leaky bucket implementation
Computer Networks
- Rajat Verma
A leaky bucket algorithm shapes bursty traffic
into fixed-rate traffic by averaging the data rate.
It may drop the packets if the bucket is full.
Computer Networks
- Rajat Verma
Token bucket
The leaky bucket algorithm enforces a rigid pattern at the output
stream, irrespective of the pattern of the input. For many applications
it is better to allow the output to speed up somewhat when a larger
burst arrives than to loose the data.
Token Bucket algorithm provides such a solution. In this algorithm
leaky bucket holds token, generated at regular intervals.
The congestion control in the choke packet scheme can be monitored in the following
manner –
Solution
We replace each group of 8 bits with its equivalent
decimal number and add dots for separation.
Change the following IPv4 addresses from dotted-
decimal notation to binary notation.
Solution
We replace each decimal number with its binary
equivalent.
Find the error, if any, in the following IPv4 addresses.
Solution
a. There must be no leading zero (045).
b. There can be no more than four numbers.
c. Each number needs to be less than or equal to 255.
d. A mixture of binary notation and dotted-decimal
notation is not allowed.
In classful addressing, the address space is
divided into five classes:
A, B, C, D, and E.
Finding the classes in binary and dotted-decimal notation
Find the class of each address.
a. 00000001 00001011 00001011 11101111
b. 11000001 10000011 00011011 11111111
c. 14.23.120.8
d. 252.5.15.111
Solution
a. The first bit is 0. This is a class A address.
b. The first 2 bits are 1; the third bit is 0. This is a class C
address.
c. The first byte is 14; the class is A.
d. The first byte is 252; the class is E.
Every IP address also has two parts-
• The first part identifies the network (Network ID) where the system is connected
• the second part identifies the system (Host ID)
Within the address range of each IPv4 network, we have three types of
addresses:
• Network address - The address by which we refer to the network
• Broadcast address - A special address used to send data to all hosts in the
network
• Host addresses - The addresses assigned to the end devices in the network
Class A :
No of Network: 27 (The first bit of a Class A address is always 0.)
No. of Usable Host address per Network: 224-2
(Minus 2 because 2 addresses are reserved for network and broadcast
address)
Class B :
No of Network: 214 (The first two bits of the first octet of a Class B
address are always 10.)
No. of Usable Host address per Network: 216-2
Class C :
No of Network: 221 (A Class C address begins with binary 110. )
No. of Usable Host address per Network: 28-2
Class D : The Class D address class was created to enable
multicasting in an IP address. A multicast address is a unique
network address that directs packets with that destination
address to predefined groups of IP addresses. Therefore, a
single station can simultaneously transmit a single stream of
data to multiple recipients. The Class D address space, much like
the other address spaces, is mathematically constrained. The
first four bits of a Class D address must be 1110.
Class E :
A Class E address has been defined. However, the Internet
Engineering Task Force (IETF) reserves these addresses for its
own research. Therefore, no Class E addresses have been
released for use in the Internet. The first four bits of a Class E
address are always set to 1s. Therefore, the first octet range for
Class E addresses is 11110000 to 11111111, or 240 to 255.
Number of blocks (Networks) and block (Hosts ) size
in classful IPv4 addressing
The addresses in color are the default masks for classes A, B, and C.
Thus, classful addressing is a special case of classless addressing.
In IPv4 addressing, a block of
addresses can be defined as
x.y.z.t /n
in which x.y.z.t defines one of the
addresses and the /n defines the mask.
Solution
Only two are eligible (a and c).
The address 205.16.37.32 is eligible because 32 is
divisible by 16.
The address 17.17.33.80 is eligible because 80 is
divisible by 16.
Figure below shows a block of addresses, in both binary and
dotted-decimal notation, granted to a small business that needs 16
addresses.
We can see that the restrictions are applied to this block. The
addresses are contiguous. The number of addresses is a power of 2
(16 = 24), and the first address is divisible by 16.
Solution
The binary representation of the given address is
11001101 00010000 00100101 00100111
If we set 32−28 rightmost bits to 0, we get
11001101 00010000 00100101 0010000
or
205.16.37.32.
Find the last address for the block in previous example
Solution
The binary representation of the given address is
11001101 00010000 00100101 00100111
If we set 32 − 28 rightmost bits to 1, we get
11001101 00010000 00100101 00101111
or
205.16.37.47
Find the number of host addresses in 205.16.37.39/28.
Solution
The value of n is 28, which means that number
of addresses is 2 32−28 or 16.
Note
N=2
H=6
Total subnets ( 2N ) :- 22 = 4
Block size (256 - subnet mask) :- 256 - 192 = 64
Valid subnets ( Count blocks from 0) :- 0,64,128,192
Total hosts (2H) :- 26 = 64
Valid hosts per subnet ( Total host - 2 ) :- 64 - 2 = 62
in this case, 12 zeroes allow for 212 = 4096 different IP addresses within
the subnet.
Of these, two (the first and the last) are unusable for a host, so you have
a maximum of 4094 hosts.
Example 2:
You work for a large communications corporation which has been assigned a
Class A network address.
Currently, the company has 1,000 subnets in offices around the world. You
want to add 100 new subnets over the next three years, and you want to allow
for the largest possible number of host addresses per subnet.
Answer: 255.255.224.0
Requirements: 1,000 subnets + 100 subnets = 1,100 subnets, and as many host
addresses as possible
2^10-2 = 1022 we Know from memory that 2^10= 1024, and will yield ONLY 1022 usable
subnets with 10 bits of subnetting
Because our requirements ask for over 1024 subnets, we must borrow one more host
bit for our subnetting:
2^11-2 = (1024 * 2) - 2 = 2046 unique usable subnets
Solution
The prefix length is 27, which means that we must
keep the first 27 bits as it is and change the
remaining bits (5) to 0s. The 5 bits affect only the
last byte. The last byte is 01010010. Changing the
last 5 bits to 0s, we get 01000000 or 64. The
network address is 167.199.170.64/27.
Example 8
An organization is granted the block 130.34.12.64/26.
The organization needs to have four subnets. What are the
subnet addresses and the range of addresses for each
subnet?
Solution
Answer: 255.255.240.0
2^3-2 = 6 subnets
2^4-2 = 14 subnets
(2^16 - 2^4) -2 = 2^12 - 2 = 4094 hosts possible per subnet
• ICMP is network diagnostic and error reporting protocol. ICMP belongs to IP protocol suite
and uses IP as carrier protocol. After constructing ICMP packet, it is encapsulated in IP
packet. Because IP itself is a best-effort non-reliable protocol, so is ICMP.
• Any feedback about network is sent back to the originating host. If some error in the
network occurs, it is reported by means of ICMP. ICMP contains dozens of diagnostic and
error reporting messages.
• ICMP-echo and ICMP-echo-reply are the most commonly used ICMP messages to check the
reachability of end-to-end hosts. When a host receives an ICMP-echo request, it is bound
to send back an ICMP-echo-reply. If there is any problem in the transit network, the ICMP
will report that problem.
Address Resolution Protocol(ARP)
If a machine talks to another machine in the same network, it requires its physical or MAC address.
But ,since the application has given the destination's IP address it requires some mechanism to bind
the IP address with its MAC address. This is done through Address Resolution protocol (ARP). IP
address of the destination node is broadcast and the destination node informs the source of its MAC
address.