0% found this document useful (0 votes)
3 views

3unitCOMPUTER NETWORK

Data communication involves the exchange of data between devices through a transmission medium, characterized by delivery, accuracy, timeliness, and jitter. Networks can be categorized into LANs, MANs, and WANs, with various topologies such as mesh, star, ring, and bus, each having its advantages and disadvantages. The document also discusses guided and unguided media for data transmission, including twisted-pair cables, coaxial cables, fiber-optic cables, and wireless communication methods.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

3unitCOMPUTER NETWORK

Data communication involves the exchange of data between devices through a transmission medium, characterized by delivery, accuracy, timeliness, and jitter. Networks can be categorized into LANs, MANs, and WANs, with various topologies such as mesh, star, ring, and bus, each having its advantages and disadvantages. The document also discusses guided and unguided media for data transmission, including twisted-pair cables, coaxial cables, fiber-optic cables, and wireless communication methods.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 56

COMPUTER NETWORK

Data communication

Data communications are the exchange of data between two devices via some transmission
medium.

The effectiveness of a data communications system depends on four fundamental characteristics:


delivery, accuracy, timeliness, and jitter. I. Delivery. The system must deliver data to the correct
destination. Data must be received by the intended device or user and only by that device or user. 2
Accuracy. The system must deliver the data accurately. Data that have been altered in transmission and
left uncorrected are unusable. 3. Timeliness. The system must deliver data in a timely manner. Data
delivered late are useless. In the case of video and audio, timely delivery means delivering data as they
are produced, in the same order that they are produced, and without significant delay. This kind of
delivery is called real-time transmission. 4. Jitter. Jitter refers to the variation in the packet arrival time.
It is the uneven delay in the delivery of audio or video packets. For example, let us assume that video
packets are sent every 30 ms. If some of the packets arrive with 30-ms delay and others with 40-ms
delay, an uneven quality in the video is the result.

A data communications system has five components

1.Message. The message is the information (data) to be communicated. Popular forms of


information include text, numbers, pictures, audio, and video. 2 Sender. The sender is the
device that sends the data message. It can be a computer, workstation, telephone handset,
video camera, and so on. 3. Receiver. The receiver is the device that receives the message. It
can be a computer, workstation, telephone handset, television, and so on. 4. Transmission
medium. The transmission medium is the physical path by which a message travels from sender
to receiver. Some examples of transmission media include twisted-pair wire, coaxial cable,
fiber-optic cable, and radio waves. 5. Protocol. A protocol is a set of rules that govern data
communications. It represents an agreement between the communicating devices. Without a
protocol, two devices may be connected but not communicating, just as a person speaking
French cannot be understood by a person who speaks only Japanese.
Transmission Mode
Data flow between two systems can be categorised into three types –

Simplex

The communication is unidirectional as a one-way street, one device always, other can always
receive. E.g. radio, mouse. The simplex mode can use the entire capacity of the channel to send data in
one direction.
Half duplex

Each station can both transmit and receive, but not at the same time. E.g. like a one lane road,
walkie-talkie etc.When one device is sending, the other can only receive, and vice versa.

In a half-duplex transmission, the entire capacity of a channel is taken over by whichever of the
two devices is transmitting at the time.

Walkie-talkies are both half-duplex systems.

Walkie-talkies
Full duplex

Both stations can transmit and receive at the same time. Actually, it is two half duplex
connections.

Telephone network is an example of full-duplex mode, when two people are communicating by
a telephone line, both can talk and listen at the same time.

The capacity of the channel, must be divided between the two directions.
NETWORKS

A network is a set of devices (often referred to as nodes) connected by communication links. A node can
be a computer, printer, or any other device capable of sending and/or receiving data generated by other
nodes on the network. “Computer network’’ to mean a collection of autonomous computers
interconnected by a single technology. Two computers are said to be interconnected if they are able to
exchange information. The connection need not be via a copper wire; fiber optics, microwaves, infrared,
and communication satellites can also be used. Networks come in many sizes, shapes and forms, as we
will see later. They are usually connected together to make larger networks, with the Internet being the
most well-known example of a network of networks. There is considerable confusion in the literature
between a computer network and a distributed system. The key distinction is that in a distributed
system, a collection of independent computers appears to its users as a single coherent system. Usually,
it has a single model or paradigm that it presents to the users. Often a layer of software on top of the
operating system, called middleware, is responsible for implementing this model. A well-known example
of a distributed system is the World Wide Web. It runs on top of the Internet and presents a model in
which everything looks like a document (Web page).

LAN (Local Area Network) Group of interconnected computers within a small area. (room, building,
campus) Two or more pc's can from a LAN to share files, folders, printers, applications and other
devices. Coaxial or CAT 5 cables are normally used for connections. Due to short distances, errors and
noise are minimum. Data transfer rate is 10 to 100 mbps. Example: A computer lab in a school.

MAN (Metropolitan Area Network) Design to extend over a large area. Connecting number of LAN's to
form larger network, so that resources can be shared. Networks can be up to 5 to 50 km. Owned by
organization or individual. Data transfer rate is low compare to LAN. Example: Organization with
different branches located in the city.

WAN (Wide Area Network) Are country and worldwide network. Contains multiple LAN's and MAN's.
Distinguished in terms of geographical range. Uses satellites and microwave relays. Data transfer rate
depends upon the ISP provider and varies over the location. Best example is the internet.
Physical topology

Refers to the way in which a network is laid out physically. Topology of a network is the
geometric representation of the relationship of all the links and linking devices to one another.

The term physical topology refers to the way in which a network is laid out physically. Two or more
devices connect to a link; two or more links form a topology. The topology of a network is the geometric
representation of the relationship of all the links and linking devices (usually called nodes) to one
another. There are four basic topologies possible: mesh, star, bus, and ring
MESH:

A mesh topology is the one where every node is connected to every other node in the network. A mesh
topology can be a full mesh topology or a partially connected mesh topology. In a full mesh topology,
every computer in the network has a connection to each of the other computers in that network.

The number of connections in this network can be calculated using the following formula (n is the
number of computers in the network): n(n-1)/2 In a partially connected mesh topology, at least two of
the computers in the network have connections to multiple other computers in that network. It is an
inexpensive way to implement redundancy in a network.

In the event that one of the primary computers or connections in the network fails, the rest of the
network continues to operate normally.

MESH TOPOLOGY DIAGRAM-

Advantages of a mesh topology

 Can handle high amounts of traffic, because multiple devices can transmit data simultaneously.

 A failure of one device does not cause a break in the network or transmission of data.

 Adding additional devices does not disrupt data transmission between other devices.

Disadvantages of a mesh topology

 The cost to implement is higher than other network topologies, making it a less desirable option.
 Building and maintaining the topology is difficult and time consuming.

 The chance of redundant connections is high, which adds to the high costs and potential for reduced
efficiency.

STAR:
A star network, star topology is one of the most common network setups. In this configuration, every
node connects to a central network device, like a hub, switch, or computer. The central network device
acts as a server and the peripheral devices act as clients. Depending on the type of network card used in
each computer of the star topology, a coaxial cable or a RJ-45 network cable is used to connect
computers together.

Advantages of Star topology

1. A star topology is less expensive than a mesh topology.


2. It is easy to install and reconfigure and less costly.
3. It is robust , if one link fails ,only that link is affected.
4. Easy to fault identification and fault isolation.
Disadvantages of star topology
 Can have a higher cost to implement, especially when using a switch or router as the central
network device.
 The central network device determines the performance and number of nodes the network
can handle.
 If the central computer, hub, or switch fails, the entire network goes down and all
computers are disconnected from the network
A ring topology is a network configuration in which device connections create a circular data
path. In a ring network, packets of data travel from one device to the next until they reach their
destination. Most ring topologies allow packets to travel only in one direction, called a
unidirectional ring network. Others permit data to move in either direction, called bidirectional.
The major disadvantage of a ring topology is that if any individual connection in the ring is
broken, the entire network is affected. Ring topologies may be used in either local area
networks (LANs) or wide area networks (WANs).

Advantages of ring topology


 All data flows in one direction, reducing the chance of packet collisions.
 A network server is not needed to control network connectivity between each workstation.
 Data can transfer between workstations at high speeds.
 Additional workstations can be added without impacting performance of the network.
Disadvantages of ring topology
 All data being transferred over the network must pass through each workstation on the
network, which can make it slower than a star topology.
 The entire network will be impacted if one workstation shuts down.
 The hardware needed to connect each workstation to the network is more expensive than
Ethernet cards and hubs/switches.
A bus topology, is multipoint. One long cable acts as a backbone to link all the devices in a
network.

•Nodes are connected to the bus cable by drop lines and taps.

•A drop line is a connection running between the device and the main cable.

•A tap is a connector that either splices into the main cable or punctures the sheathing of a
cable to create a contact with the metallic core.

a line topology, a bus topology is a network setup in which each computer and network device
are connected to a single cable or backbone.

Advantages of bus topology


 It works well when you have a small network.
 It's the easiest network topology for connecting computers or peripherals in a linear fashion.
 It requires less cable length than a star topology.
Disadvantages of bus topology
 It can be difficult to identify the problems if the whole network goes down.
 It can be hard to troubleshoot individual device issues.
 Bus topology is not great for large networks.
 Terminators are required for both ends of the main cable.
 Additional devices slow the network down.
 If a main cable is damaged, the network fails or splits into two.
Differences between OSI Model and TCP/IP Model

Parameters OSI Model TCP/IP Model

OSI stands for Open Systems TCP/IP stands for Transmission Control
Full Form
Interconnection. Protocol/Internet Protocol.

Layers It has 7 layers. It has 4 layers.

Usage It is low in usage. It is mostly used.

Approach It is vertically approached. It is horizontally approached.

Delivery of the package is guaranteed Delivery of the package is not


Delivery
in OSI Model. guaranteed in TCP/IP Model.

Replacement of tools and changes can Replacing the tools is not easy as it is in
Replacement
easily be done in this model. OSI Model.

Reliability It is less reliable than TCP/IP Model. It is more reliable than OSI Model.
Repeater

Repeaters boost the strength of a signal as it travels through a communication channel, like a
telephone line or a radio frequency, to help it cover longer distances.

In situations where signals lose power due to resistance or distance, a repeater amplifies the
signal before sending it further.

In computer networking, repeaters operate on the physical layer of the OSI model, as they only
work with the actual signal and don't interpret data.

Repeaters are used to extend transmissions so that the signal can cover longer distances or be received
on the other side of an obstruction.

In computer networking, because repeaters work with the actual physical signal, and do not attempt to
interpret the data being transmitted, they operate on the physical layer, the first layer of theOSI model.
Guided Media:
Guided media, which are those that provide a medium from one device to
another, include twisted-pair cable, coaxial cable, and fiber-optic cable.
Twisted-Pair Cable: A twisted pair consists of two conductors (normally copper),
each with its own plastic insulation, twisted together. One of the wires is used to
carry signals to the receiver, and the other is used only as a ground reference.
Unshielded Versus Shielded Twisted-Pair Cable
The most common twisted-pair cable used in communications is referred to as
unshielded twisted-pair (UTP). STP cable has a metal foil or braided mesh covering
that encases each pair of insulated conductors. Although metal casing improves
the quality of cable by preventing the penetration of noise or crosstalk, it is
bulkier and more expensive.
Applications Twisted-pair cables are used in telephone lines to provide voice and
data channels. Local-area networks, such as l0Base-T and l00Base-T, also use
twisted-pair cables.
Coaxial Cable Coaxial cable (or coax) carries signals of higher frequency ranges
than those in twisted pair cable. coax has a central core conductor of solid or
stranded wire (usuallycopper) enclosed in an insulating sheath, which is, in turn,
encased in an outer conductor of metal foil, braid, or a combination of the two.
The outer metallic wrapping serves both as a shield against noise and as the
second conductor, which completes the circuit.This outer conductor is also
enclosed in an insulating sheath, and the whole cable is protected by a plastic
cover.

Applications Coaxial cable was widely used in analog telephone networks,digital telephone networks
Cable TV networks also use coaxial cables. Another common application of coaxial cable is in traditional
Ethernet LANs
Fiber-Optic Cable A fiber-optic cable is made of glass or plastic and transmits
signals in the form of light. Light travels in a straight line as long as it is moving
through a single uniform substance. If a ray of light traveling through one
substance suddenly enters another substance(of a different density), the ray
changes direction. Bending of light ray.
UNGUIDED MEDIA: WIRELESS
Unguided media transport electromagnetic waves without using a physical
conductor. This type of communication is often referred to as wireless
communication. Radio Waves Microwaves Infrared
Radio Waves Electromagnetic waves ranging in frequencies between 3 kHz and 1
GHz are normally called radio waves. Radio waves are omni directional. When an
antenna transmits radio waves, they are propagated in all directions. This means
that the sending and receiving antennas do not have to be aligned. A sending
antenna sends waves that can be received by any receiving antenna. The omni
directional property has a disadvantage, too. The radio waves transmitted by one
antenna are susceptible to interference by another antenna that may send signals
using the same frequency or band. Omni directional Antenna Radio waves use
omnidirectional antennas that send out signals in all directions. Based on the
wavelength, strength, and the purpose of transmission, we can have several types
of antennas. Figure shows an omnidirectional antenna.

Applications

The Omni directional characteristics of radio waves make them useful for
multicasting, in which there is one sender but many receivers. AM and FM radio,
television, maritime radio, cordless phones, and paging are examples of
multicasting.

Microwaves Electromagnetic waves having frequencies between 1 and 300 GHz


are called microwaves. Microwaves are unidirectional. The sending and receiving
antennas need to be aligned. The unidirectional property has an obvious
advantage. A pair of antennas can be aligned without interfering with another
pair of aligned antennas Unidirectional Antenna Microwaves need unidirectional
antennas that send out signals in one direction. Two types of antennas are used
for microwave communications: the parabolic dish and the horn
Applications: Microwaves are used for unicast communication such as cellular
telephones, satellite networks, and wireless LANs
Infrared Infrared waves, with frequencies from 300 GHz to 400 THz (wavelengths
from 1 mm to 770 nm), can be used for short-range communication. Infrared
waves, having high frequencies, cannot penetrate walls. This advantageous
characteristic prevents interference between one system and another; a
shortrange communication system in one room cannot be affected by another
system in the next room. When we use our infrared remote control, we do not
interfere with the use of the remote by our neighbors. Infrared signals useless for
long-range communication. In addition, we cannot use infrared waves outside a
building because the sun's rays contain infrared waves that can interfere with the
communication.
Applications:
Infrared signals can be used for short-range communication in a closed area using
line-of-sight propagation.
UNIT 2

Errors
When bits are transmitted over the computer network, they are subject to get
corrupted due to interference and network problems. The corrupted bits leads to
spurious data being received by the destination and are called errors.

Types of Errors
Errors can be of three types, namely single bit errors, multiple bit errors, and
burst errors.

 Single bit error − In the received frame, only one bit has been corrupted, i.e. either changed
from 0 to 1 or from 1 to 0.

Multiple bits error − In the received frame, more than one bits are corrupted.
Burst error − In the received frame, more than one consecutive bits are
corrupted.
LRC (longitudinal redundancy check ) is also known as 2-D parity check. In this
method, data which the user want to send is organised into tables of rows and
columns. A block of bit is divided into table or matrix of rows and columns. In
order to detect an error, a redundant bit is added to the whole block and this
block is transmitted to receiver. The receiver uses this redundant row to detect
error. After checking the data for errors, receiver accepts the data and discards
the redundant row of bits.
Examples :
If a block of 32 bits is to be transmitted, it is divided into matrix of four rows and
eight columns which as shown in the following figure :
In this matrix of bits, a parity bit (odd or even) is calculated for each column. It
means 32 bits data plus 8 redundant bits are transmitted to receiver. Whenever
data reaches at the destination, receiver uses LRC to detect error in data.
Advantage :
LRC is used to detect burst errors.
Example : Suppose 32 bit data plus LRC that was being transmitted is hit by a
burst error of length 5 and some bits are corrupted as shown in the following
figure :

The LRC received by the destination does not match with newly corrupted LRC.
The destination comes to know that the data is erroneous, so it discards the
data.
Disadvantage :
The main problem with LRC is that, it is not able to detect error if two bits in a
data unit are damaged and two bits in exactly the same position in other data
unit are also damaged.
Example : If data 110011 010101 is changed to 010010110100.
Two bits at same bit position damaged in 2 data units.

In this example 1st and 6th bit in one data unit is changed . Also the 1st and 6th
bit in second unit is changed.
Vertical Redundancy Check is also known as Parity Check. In this method, a
redundant bit also called parity bit is added to each data unit. This method
includes even parity and odd parity. Even parity means the total number of 1s in
data is to be even and odd parity means the total number of 1s in data is to be
odd. Example – If the source wants to transmit data unit 1100111 using even
parity to the destination. The source will have to pass through Even Parity
Generator.

Fig. Even parity VRC


Parity generator will count number of 1s in data unit and will add parity bit. In
the above example, number of 1s in data unit is 5, parity generator appends a
parity bit 1 to this data unit making the total number of 1s even i.e 6 which is
clear from above figure. Data along with parity bit is then transmitted across the
network. In this case, 11001111 will be transmitted. At the destination, This data
is passed to parity checker at the destination. The number of 1s in data is
counted by parity checker. If the number of 1s count out to be odd, e.g. 5 or 7
then destination will come to know that there is some error in the data. The
receiver then rejects such an erroneous data unit.
Advantages :
 VRC can detect all single bit error.
 It can also detect burst errors but only in those cases where number of bits
changed is odd, i.e. 1, 3, 5, 7, …….etc.
 VRC is simple to implement and can be easily incorporated into different
communication protocols and systems.
 It is efficient in terms of computational complexity and memory requirements.
 VRC can help improve the reliability of data transmission and reduce the
likelihood of data corruption or loss due to errors.
 VRC can be combined with other error detection and correction techniques
to improve the overall error handling capabilities of a system.

Disadvantages :

 The major disadvantage of using this method for error detection is that it is
not able to detect burst error if the number of bits changed is even, i.e. 2, 4,
6, 8, …….etc.
 Example – If the original data is 1100111. After adding VRC, data unit that
will be transmitted is 11001111. Suppose on the way 2 bits are 01011111.
When this data will reach the destination, parity checker will count number of
1s in data and that comes out to be even i.e. 8. So, in this case, parity is not
changed, it is still even. Destination will assume that there is no error in data
even though data is erroneous.
 VRC is not capable of correcting errors, only detecting them. This means
that it can identify errors, but it cannot fix them.
 VRC is not suitable for applications that require high levels of error detection
and correction, such as mission-critical systems or safety-critical
applications.
 VRC is limited in its ability to detect and correct errors in large blocks of
data, as the probability of errors increases with the size of the data block.
Difference between VRC and LRC :

Vertical Redundancy Check Longitudinal Redundancy Check


S.No. (VRC) (LRC)
It stands for Vertical It stands for Longitudinal
1. Redundancy Check. Redundancy Check.
In this redundant bit called
parity bit is added to each In this redundant row of bits is
2. data unit. added to the whole block.
VRC can detect single bit
3. errors. LRC can detect burst errors.
It is also known as parity It is also known as 2-D parity
4. checker. checker.
The advantage of using VRC
is that it can checks all single
bit errors but can check odd The advantage of using LRC over
parity only in the case of VRC is that it can check all the
5. change of odd bits. burst errors.
If two bits in data unit is damaged
and also in other data unit the
It is not capable of checking same bits are damaged at same
the burst error in case of position, then it is not capable of
6. change of bits is even. detecting such kind of error.
Cyclic Redundancy Check
We can create cyclic codes to correct errors. In the encoder, the
dataword has k bits (4 here); the codeword has n bits (7 here). The size
of the dataword is augmented by adding n - k (3 here) Os to the right-
hand side of the word.
The n-bit result is fed into the generator. The generator uses a
divisor of size n - k + 1 (4 here), predefined and agreed upon. The
generator divides the augmented dataword by the divisor (modulo-2
division). The quotient of the division is discarded; the remainder (r2 r1
r0) is appended to the dataword to create the codeword .
ENCODER FIGURE.
DECODER FIGURE
UNIT 3
Message Switching –
Message switching was a technique developed as an alternative to circuit
switching before packet switching was introduced. In message switching, end-
users communicate by sending and receiving messages that included the entire
data to be shared. Messages are the smallest individual unit.
Also, the sender and receiver are not directly connected. There are a number of
intermediate nodes that transfer data and ensure that the message reaches its
destination. Message switched data networks are hence called hop-by-hop
systems.
They provide 2 distinct and important characteristics:
1. Store and forward – The intermediate nodes have the responsibility of
transferring the entire message to the next node. Hence, each node must
have storage capacity. A message will only be delivered if the next hop and
the link connecting it are both available, otherwise, it’ll be stored indefinitely.
A store-and-forward switch forwards a message only if sufficient resources
are available and the next hop is accepting data. This is called the store-
and-forward property.

2. Message delivery – This implies wrapping the entire information in a single


message and transferring it from the source to the destination node. Each
message must have a header that contains the message routing information,
including the source and destination.
Characteristics of message switching –
Message switching is advantageous as it enables efficient usage of network
resources. Also, because of the store-and-forward capability of intermediary
nodes, traffic can be efficiently regulated and controlled. Message delivery as
one unit, rather than in pieces, is another benefit.
However, message switching has certain disadvantages as well. Since
messages are stored indefinitely at each intermediate node, switches require a
large storage capacity. Also, these are pretty slow. This is because at each
node, first there is a wait till the entire message is received, then it must be
stored and transmitted after processing the next node and links to it depending
on availability and channel traffic. Hence, message switching cannot be used
for real-time or interactive applications like a video conference.
An example of message switching is email in which the message is sent through different
intermediate servers to reach the mail server for storing. Unlike packet switching, the message is not
divided into smaller units and sent independently over the network.
Advantages of Message Switching –
Message switching has the following advantages:
1. As message switching is able to store the message for which communication
channel is not available, it helps in reducing the traffic congestion in the
network.
2. In message switching, the data channels are shared by the network devices.
3. It makes traffic management efficient by assigning priorities to the
messages.
4. Because the messages are delivered via a store and forward method, it is
possible to include priority in them.
5. It allows for infinite message lengths.
6. Unlike circuit switching, it does not necessitate the actual connection of
source and destination devices.

Disadvantages of Message Switching –


Message switching has the following disadvantages:
1. Message switching cannot be used for real-time applications as storing
messages causes delay.
2. In message switching, the message has to be stored for which every
intermediate device in the network requires a large storing capacity.
3. Because the system is so intricate, people are frequently unaware of
whether or not messages are correctly conveyed. This could cause problems
in social relationships.
4. The type of message switching does not create a dedicated path between
the devices. It is not dependable communication because there is no direct
relationship between sender and receiver.
Difference between Circuit Switching and Packet Switching:

Circuit Switching Packet Switching

In-circuit switching has there are 3 phases:


i) Connection Establishment. In Packet switching directly
ii) Data Transfer. data transfer takes place.
iii) Connection Released.

In Packet switching, each data


In-circuit switching, each data unit knows unit just knows the final
the entire path address which is provided destination address
by the source. intermediate path is decided by
the routers.

In Packet switching, data is


In-Circuit switching, data is processed at processed at all intermediate
the source system only nodes including the source
system.

The delay between data units


The delay between data units in circuit
in packet switching is not
switching is uniform.
uniform.

Resource reservation is the feature of There is no resource


circuit switching because the path is fixed reservation because bandwidth
for data transmission. is shared among users.

Packet switching is less


Circuit switching is more reliable.
reliable.

Wastage of resources is more in Circuit Less wastage of resources as


Switching compared to Circuit Switching

It is a store and forward


It is not a store and forward technique.
technique.
Circuit Switching Packet Switching

Transmission of the data is


Transmission of the data is done by the done not only by the source
source. but also by the intermediate
routers.

Congestion can occur during the Congestion can occur during


connection establishment phase because the data transfer phase, a large
there might be a case where a request is number of packets comes in no
being made for a channel but the channel time.
is already occupied.

Circuit switching is not convenient for Packet switching is suitable for


handling bilateral traffic. handling bilateral traffic.
What is the ARP Protocol?
ARP stands for “Address Resolution Protocol”. It is a network protocol used to
determine the MAC address (hardware address) from any IP address.
In other words, ARP is used to translate IP Address into MAC Address. When
one device wants to communicate with another device in a LAN (local area
network) network, the ARP protocol is used.
ARP protocol finds the MAC address based on IP address. IP address is used
to communicate with any device at the application layer. But to communicate
with a device at the data link layer or to send data to it, a MAC address is
required.

Important ARP Terms


 ARP Cache :- After receiving the MAC address, ARP passes it to the sender
where it is stored in a table for future reference. And this is called ARP
Cache which is later used to obtain the MAC address.
 ARP Cache Timeout :- This is the time in which the MAC address can
remain in the ARP Cache.
 ARP request :- Broadcasting a packet over the network to verify whether we
have arrived at the destination MAC address.
 ARP response/reply :- It is a MAC address response that the sender
receives from the receiver which helps in further communication of data.

Below is a Working flow diagram of ARP Protocol


Below is the working of address resolution protocol is being explained in some
steps :-
 When a sender wants to communicate with a receiver, the sender first
checks its ARP cache. Sender checks whether the receiver’s MAC address
is already present in the ARP cache or not?
 If the receiver’s MAC address is already present in the ARP cache, the
sender will communicate with the receiver using that MAC address.
 If the MAC address of the receiver device is not already present in the ARP
cache, then in such a situation an ARP request message is prepared by the
sender device.This message contains the MAC address of the sender, IP
address of the sender and IP address of the receiver. The field containing
the MAC address of the receiver is left blank because it is being searched.
 Sender device broadcasts this ARP request message in the LAN. Because
this is a broadcast message, every device connected to the LAN receives
this message.
 All devices match the receiver IP address of this request message with their
own IP address. Devices whose IP address does not match drop this
request message.
 The device whose IP address matches the receiver IP address of this
request message receives this message and prepares an ARP reply
message. This is a unicast message which is sent only to the sender.
 In ARP reply message, the sender’s IP address and MAC address are used
to send the reply message. Besides, in this message the receiver also sends
its IP address and MAC address.

 As soon as the sender device receives this ARP reply message, it updates
its ARP cache with the new information (Receiver’s MAC address). Now the
MAC address of the receiver is present in the ARP cache of the sender. The
sender can send and receive data without any problem.
Message Format of ARP Protocol

All the fields given in ARP message format are being explained in detail below:-
 Hardware Type: The size of this field is 2 bytes. This field defines what type
of Hardware is used to transmit the message. The most common Hardware
type is Ethernet. The value of Ethernet is 1.
 Protocol Type: This field tells which protocol has been used to transmit the
message. substantially the value of this field is 2048 which indicates IPv4.
 Hardware Address Length: It shows the length of the tackle address in
bytes. The size of Ethernet MAC address is 6 bytes.
 Protocol Address Length: It shows the size of the IP address in bytes. The
size of IP address is 4 bytes.
 OP law: This field tells the type of message. If the value of this field is 1 also
it’s a request message and if the value of this field is 2 also it’s a reply
message.
 Sender Hardware Address: This field contains the MAC address of the
device transferring the message.
 Sender Protocol Address: This field contains the IP address of the device
transferring the message.
 Target Hardware Address: This field is empty in the request message. This
field contains the MAC address of the entering device.
 Target Protocol Address: This field contains the IP address of the entering
device.

What is RARP
The Reverse Address Resolution Protocol (RARP) is a networking protocol
that is used to map a physical (MAC) address to an Internet Protocol (IP)
address. It is the reverse of the more commonly used Address Resolution
Protocol (ARP), which maps an IP address to a MAC address.
Difference between ARP and RARP that are as follows:

ARP RARP

A protocol used to map an IP


A protocol used to map a physical
address to a physical (MAC)
(MAC) address to an IP address
address

To obtain the MAC address of a To obtain the IP address of a network


network device when only its IP device when only its MAC address is
address is known known

Client broadcasts its IP address and Client broadcasts its MAC address and
requests a MAC address, and the requests an IP address, and the server
server responds with the responds with the corresponding IP
corresponding MAC address address

IP addresses MAC addresses

Widely used in modern networks to Rarely used in modern networks as


resolve IP addresses to MAC most devices have a pre-assigned IP
addresses address

ARP stands for Address Resolution Whereas RARP stands for Reverse
Protocol. Address Resolution Protocol.

Whereas through RARP, (48-bit) MAC


Through ARP, (32-bit) IP address
address of 48 bits mapped into (32-
mapped into (48-bit) MAC address.
bit) IP address.

In ARP, broadcast MAC address is While in RARP, broadcast IP address is


used. used.
ARP RARP

In ARP, ARP table is managed or While in RARP, RARP table is managed


maintained by local host. or maintained by RARP server.

In Address Resolution Protocol,


While in RARP, IP address is fetched.
Receiver’s MAC address is fetched.

In ARP, ARP table uses ARP reply While in RARP, RARP table uses RARP
for its updation. reply for configuration of IP addresses .

Hosts and routers uses ARP for


While RARP is used by small users
knowing the MAC address of other
having less facilities.
hosts and routers in the networks.

ARP is used in sender’s side to map RARP is used in receiver’s side to map
the receiver’s MAC address. the sender’s IP.

Difference between Circuit switching and Message switching:


S.NO Circuit Switching Message Switching

In message Switching, data is first


Circuit Switching is done by
stored by one node then forward to
1. setting a physical path between
another node to transfer the data to
two systems.
another system.

In message Switching, data is first


In circuit switching, data is not
2. stored, then forwarded to the next
stored.
node.

Circuit Switching needs a Message switching does not need a


dedicated physical path that’s dedicated physical path and on
3.
why the messages need not be Message switching, The messages
addressed. are addressed independently.

Circuit Switching Message Switching is Hierarchical


4.
is Geographical addressing. addressing.

Circuit Switching is costlier than The cost of message switching is


5.
message Switching. less than circuit switching.

Message Switching routing is not


Circuit switching routing is
6. manual type routing, here route is
manual type routing.
selected during call setup.

Circuit switching reserves the full Message Switching does not


bandwidth in advance. because reserve the entire bandwidth in
7.
of that, there is a lot of wastage advance. and that’s why bandwidth
of bandwidth is used to its maximum extent.

In message switching, the charge is


In-circuit switching, the charge
8. based on the number of bytes and
depends on time and distance.
distance.
S.NO Circuit Switching Message Switching

In message switching, no
Congestion occurs per minute in
9. congestion or very little congestion
circuit switching.
occurs.

Circuit switching uses Analog Whereas Message switching uses


10. and digital media on a variety of digital media on a variety of
platforms. platforms.

In-circuit switching there is no While In Message switching there is


11.
propagation delay. a propagation delay.

The transmission capacity of while the transmission capacity of


12.
circuit switching is very low. message switching is high.

In a circuit switching, Messages In message switching, Messages


13. need not be addressed as there are addressed as independent
is one dedicated path. routes are established.

Ex. Real time transfer of voice


14. Ex. Transmission of telegram.
signals.
DHCP

Dynamic Host Configuration Protocol (DHCP) is a network management protocol used to


dynamically assign an IP address to nay device, or node, on a network so they can communicate
using IP (Internet Protocol). DHCP automates and centrally manages these configurations. There
is no need to manually assign IP addresses to new devices. Therefore, there is no requirement for
any user configuration to connect to a DHCP based network.
DHCP can be implemented on local networks as well as large enterprise networks. DHCP is the
default protocol used by the most routers and networking equipment. DHCP is also called RFC
(Request for comments) 2131.
Working of DHCP
The working of DHCP is as follows:
DHCP works on the Application layer of the TCP/IP Protocol. The main task of
DHCP is to dynamically assigns IP Addresses to the Clients and allocate
information on TCP/IP configuration to Clients. For more, you can refer to the
Article Working of DHCP.
The DHCP port number for the server is 67 and for the client is 68. It is a client-
server protocol that uses UDP services. An IP address is assigned from a pool
of addresses. In DHCP, the client and the server exchange mainly 4 DHCP
messages in order to make a connection, also called the DORA process, but
there are 8 DHCP messages in the process.
Components of DHCP
The main components of DHCP include:
 DHCP Server: DHCP Server is basically a server that holds IP Addresses and
other information related to configuration.
 DHCP Client: It is basically a device that receives configuration information
from the server. It can be a mobile, laptop, computer, or any other electronic
device that requires a connection.
 DHCP Relay: DHCP relays basically work as a communication channel
between DHCP Client and Server.
 IP Address Pool: It is the pool or container of IP Addresses possessed by
the DHCP Server. It has a range of addresses that can be allocated to devices.
 Subnets: Subnets are smaller portions of the IP network partitioned to keep
networks under control.
 Lease: It is simply the time that how long the information received from the
server is valid, in case of expiration of the lease, the tenant must have to re-
assign the lease.
 DNS Servers: DHCP servers can also provide DNS (Domain Name System)
server information to DHCP clients, allowing them to resolve domain names
to IP addresses.
 Default Gateway: DHCP servers can also provide information about the
default gateway, which is the device that packets are sent to when the
destination is outside the local network.
 Options: DHCP servers can provide additional configuration options to
clients, such as the subnet mask, domain name, and time server information.
 Renewal: DHCP clients can request to renew their lease before it expires to
ensure that they continue to have a valid IP address and configuration
information.
 Failover: DHCP servers can be configured for failover, where two servers
work together to provide redundancy and ensure that clients can always obtain
an IP address and configuration information, even if one server goes down.
 Dynamic Updates: DHCP servers can also be configured to dynamically
update DNS records with the IP address of DHCP clients, allowing for easier
management of network resources.
 Audit Logging: DHCP servers can keep audit logs of all DHCP transactions,
providing administrators with visibility into which devices are using which IP
addresses and when leases are being assigned or renewed.

Components of DHCP
The main components of DHCP include:
 DHCP Server: DHCP Server is basically a server that holds IP Addresses and
other information related to configuration.
 DHCP Client: It is basically a device that receives configuration information
from the server. It can be a mobile, laptop, computer, or any other electronic
device that requires a connection.
 DHCP Relay: DHCP relays basically work as a communication channel
between DHCP Client and Server.
 IP Address Pool: It is the pool or container of IP Addresses possessed by
the DHCP Server. It has a range of addresses that can be allocated to devices.
 Subnets: Subnets are smaller portions of the IP network partitioned to keep
networks under control.
 Lease: It is simply the time that how long the information received from the
server is valid, in case of expiration of the lease, the tenant must have to re-
assign the lease.
 DNS Servers: DHCP servers can also provide DNS (Domain Name System)
server information to DHCP clients, allowing them to resolve domain names
to IP addresses.
 Default Gateway: DHCP servers can also provide information about the
default gateway, which is the device that packets are sent to when the
destination is outside the local network.
 Options: DHCP servers can provide additional configuration options to
clients, such as the subnet mask, domain name, and time server information.
 Renewal: DHCP clients can request to renew their lease before it expires to
ensure that they continue to have a valid IP address and configuration
information.
 Failover: DHCP servers can be configured for failover, where two servers
work together to provide redundancy and ensure that clients can always obtain
an IP address and configuration information, even if one server goes down.
 Dynamic Updates: DHCP servers can also be configured to dynamically
update DNS records with the IP address of DHCP clients, allowing for easier
management of network resources.
 Audit Logging: DHCP servers can keep audit logs of all DHCP transactions,
providing administrators with visibility into which devices are using which IP
addresses and when leases are being assigned or renewed.

Advantages of DHCP
The advantages of using DHCP include:
 Centralized management of IP addresses.
 Centralized and automated TCP/IP configuration.
 Ease of adding new clients to a network.
 Reuse of IP addresses reduces the total number of IP addresses that are
required.
 The efficient handling of IP address changes for clients that must be updated
frequently, such as those for portable devices that move to different locations
on a wireless network.
 Simple reconfiguration of the IP address space on the DHCP server without
needing to reconfigure each client.
 The DHCP protocol gives the network administrator a method to configure the
network from a centralized area.
 With the help of DHCP, easy handling of new users and the reuse of IP
addresses can be achieved.
The BOOTP protocol is a networking protocol, the main goal of BOOTP is to find
IP addresses from a server. It was developed to replace the RARP. BOOTP was
designed to let systems discover what they need to function correctly after
booting up. It uses a relay agent which listens to port 68 of UDP, which lets the
local network transfer the packets by using standard IP routing, allowing only a
single BOOTP server to assist hosts on several subnets. Later on, BOOTP was
succeeded by a more advanced and effective protocol known as DHCP, which
has more flexibility and additional options.
During the bootstrap process, it is used to create a network connection. Initially,
BOOTP uses floppy disks, but it was soon integrated into network adapters and
motherboards, so that no external drive is required and also for launching the
initial network connection, later the process was added into the BIOS of
motherboards and NICs to allow direct network booting.
It is a broadcast protocol as it needs to send messages in order to get resources
or answers from hosts present in the network. BOOTP was planned for diskless
systems because they needed a protocol that could communicate to a server to
get its network address and some other information like which OS to use. The
computer then downloads the OS through TFTP.

Working of BOOTP

A BOOTP client does not know its IP address nor does it know the IP address of
the BOOTP server when it starts, so it broadcasts a message that carries its MAC
address in the network. This general broadcast message is known as a
“BOOTREQUEST” and this request is sent to the broadcast address. It is then
picked up by the server listening on port 67 of UDP, after receiving the request it
processes it by assigning an IP address to the MAC address of the client. The
request that it replies to the client with is known as “BOOTREPLY” which include
network information and is sent back to the client through broadcast and has the
following information:
 The client’s IP address (ciaddr and yiaddr), default gateway address (giaddr),
and subnet mask.
 The hostname and IP address of the BOOTP server (siaddr).
 The IP address of the server containing the boot image.
After obtaining the data from the BOOTP server, it initializes the TCP/IP stack
and configures it, and after that, it connects to the server containing the boot
image. Finally, the client loads the image and uses the data to load and launch
its OS.
BOOTP Message Format:

Bits Description

0–7 Opcode
8 – 15 Hardware type
16 – 23 Hardware address length
24 – 31 Hop count
32 – 63 Transaction ID
64 – 79 secs
80 – 95 Flags
96 – 127 Client IP
128 – 159 Your IP
160 – 191 Server IP
192 – 223 Gateway IP
224 – 351 Client hardware address (16 bytes)
352 – 863 Server hostname (64 bytes)
864 – 1887 Boot filename (128 bytes)
1888 – 2400 Manufacturer-specific information (64 bytes)
Difference between BOOTP and DHCP:

S.NO BOOTP DHCP

BOOTP stands for Bootstrap While DHCP stands for Dynamic host
1.
Protocol. configuration protocol.

While DHCP provides temporary IP


BOOTP does not provide
2. addressing for only limited amount of
temporary IP addressing.
time.

BOOTP does not support


3. While it support BOOTP clients.
DHCP clients.

In BOOTP, manual- While in DHCP, auto-configuration takes


4.
configuration takes place. place.

BOOTP does not support Whereas DHCP supports mobile


5.
mobile machines. machines.

BOOTP can have errors due Whereas in DHCP errors do not occur
6.
to manual-configuration. mostly due to auto-configuration.
S.No Intradomain Routing Interdomain Routing
Routing algorithm works only Routing algorithm works within
1. within domains. and between domains.
It need to know only about It need to know only about other
other routers within their routers within and between their
2. domain. domain.
Protocols used in intradomain Protocols used in interdomain
routing are known as Interior- routing are known as Exterior-
3. gateway protocols. gateway protocols.
In this Routing, routing takes In this Routing, routing takes
place within an autonomous place between the autonomous
4. network. networks.
Interdomain routing protocol
assumes that the internet
Intradomain routing protocols contains the collection of
ignores the internet outside the interconnected AS(autonomous
5. AS(autonomous system). systems).
Some Popular Protocols of this Popular Protocols of this routing
routing are RIP(routing is BGP(Border Gateway Protocol)
information protocol) and used to connect two or more
6. OSPF(open shortest path first). AS(autonomous system).
Link state routing is a technique in which each router shares the knowledge of
its neighborhood with every other router i.e. the internet work. The three keys to
understand the link state routing algorithm.
1. Knowledge about the neighborhood: Instead of sending its routing table, a
router sends the information about its neighborhood only. A router broadcast
its identities and cost of the directly attached links to other routers.
2. Flooding: Each router sends the information to every other router on the
internetwork except its neighbors. This process is known as flooding. Every
router that receives the packet sends the copies to all the neighbors. Finally
each and every router receives a copy of the same information.
3. Information Sharing: A router send the information to every other router
only when the change occurs in the information.

Link state routing has two phase:


1. Reliable Flooding: Initial state– Each node knows the cost of its neighbors.
Final state- Each node knows the entire graph.
2. Route Calculation: Each node uses Dijkstra’ s algorithm on the graph to
calculate the optimal routes to all nodes. The link state routing algorithm is
also known as Dijkstra’s algorithm which is used to find the shortest path
from one node to every other node in the network.

Characteristics of Link State Protocol


 It requires a large amount of memory.
 Shortest path computations require many CPU circles.
 If a network uses little bandwidth; it quickly reacts to topology changes
 All items in the database must be sent to neighbors to form link-state
packets.
 All neighbors must be trusted in the topology.
 Authentication mechanisms can be used to avoid undesired adjacency and
problems.
 No split horizon techniques are possible in the link-state routing.
 OSPF Protocol
Open Shortest Path First (OSPF): Open Shortest Path First (OSPF) is a
unicast routing protocol developed by a working group of the Internet
Engineering Task Force (IETF). It is an intradomain routing protocol. It is an
open-source protocol. It is similar to Routing Information Protocol (RIP). OSPF
is a classless routing protocol, which means that in its updates, it includes the
subnet of each route it knows about, thus, enabling variable-length subnet
masks. With variable-length subnet masks, an IP network can be broken into
many subnets of various sizes. This provides network administrators with extra
network configuration flexibility. These updates are multicasts at specific
addresses (224.0.0.5 and 224.0.0.6). OSPF is implemented as a program in the
network layer using the services provided by the Internet Protocol. IP datagram
that carries the messages from OSPF sets the value of the protocol field to 89.
OSPF is based on the SPF algorithm, which sometimes is referred to as the
Dijkstra algorithm.

A distance-vector routing protocol in data networks determines the best route for data packets
based on distance. Distance-vector routing protocols measure the distance by the number
of routers a packet has to pass; one router counts as one hop. Some distance-vector protocols also
take into account network latency and other factors that influence traffic on a given route. To
determine the best route across a network, routers using a distance-vector protocol exchange
information with one another, usually routing tables plus hop counts for destination networks and
possibly other traffic information. Distance-vector routing protocols also require that a router inform
its neighbours of network topology changes periodically.
Distance-vector routing protocols use the Bellman–Ford algorithm to calculate the best route.
Another way of calculating the best route across a network is based on link cost, and is implemented
through link-state routing protocols.
The term distance vector refers to the fact that the protocol manipulates vectors (arrays) of distances
to other nodes in the network. The distance vector algorithm was the original ARPANET routing
algorithm and was implemented more widely in local area networks with the Routing Information
Protocol (RIP).

You might also like