December

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 35

(a) What is a Frame Relay ?

Explain the
advantages of Frame Relay over X.25
Network.
1. (a) Frame Relay is a packet-switching network
protocol that operates at the data link layer
of the network'. It's designed to connect Local Area
Networks (LANs) and transmit data
across Wide Area Networks (WANs). Frame Relay
is a better alternative to a point-to-point
network for connecting multiple nodes that require
separate dedicated links to be established
between each pair of nodes'. It allows transmission
of different size packets and dynamic
bandwidth allocation'. Also, it provides a congestion
control mechanism to reduce the
network overheads due to congestion'. However, it
does not have an error control and flow
management mechanism'.
The advantages of Frame Relay over X.25 Network
are:
- Higher Speed: Frame Relay offers higher speeds
because it does not incorporate error
detection, hence the overhead is less. It offers high
throughput compared to X.25%.
- Dynamic Bandwidth Allocation: The bandwidth
can be allocated dynamically as per need®. - Less
Network Overhead: The network overhead is less
due to the incorporation of a
congestion control mechanism®.
- Support for Bursty Data: It allows bursty data
which do not have a fixed data rate'.
- Efficiency: Frame Relay is more efficient than
X.25 since it does not repair errors and
regulate flow at the data connection layer".
- Variable-Length Packets: It provides variable-
length packets for various data and
applications'.
- Cost-Effectiveness: It is less expensive compared
to traditional WAN networks'. - Scalability: Frame
Relay is scalable, making it suitable for growing
networks®.
However, it's important to note that Frame Relay
lacks error correction mechanisms, may not be
compatible with legacy systems, is less reliable,
and provides limited network control compared to
X.258.
(b) How are Hubs, Switches and Routers different
from each other ?
1. (b) Hubs, Switches, and Routers are all devices
that let you connect one or more computers to other
computers, networked devices, or even other
networks. Each has two or
more connectors called ports into which you plug in
the cables to make the connection'. Here's how they
differ:
- Hub: Ahub operates at the physical layer (Layer 1)
of the OSI model'. tI is a device that connects multiple
Ethernet devices on your network and makes them
act as a single network segment'. It's like a splitter
that takes ni a signal and repeats ti out ot multiple
devices'. However, a hub is not "intelligent", ti doesn't
filter data, but instead retransmits incoming data
packets or frames to every device on the network'.
- Switch: Aswitch operates at the data link layer
(Layer 2) of the OSI model'. It is more
intelligent than a hub'. Unlike a hub, a switch can filter
and forward data to a specified destination'. Switches
use MAC addresses to forward data to the correct
destination'. It can "learn" the location of the devices
on the network and store this information in a MAC
address table'. This allows ti to deliver messages
directly to the intended device without broadcasting it
to all devices on the network'.
- Router: A router is the most sophisticated of these
three devices. It operates at the network layer (Layer
3) of the OSI model'. A router is used to connect two
or more networks, such as
your home network (a local area network, LAN) and
the Internet (a wide area network, WAN)'. Routers use
IP addresses to forward packets to their destination'.
They can calculate the best route for sending data
and can direct traffic to prevent head-on collisions'.
Routers can also provide additional features, such as
DHCP (to assign IP addresses to devices on the
network), NAT (to allow multiple devices on your
network to share a single public IP address), and
firewall functionality'.
In terms of cost, hubs are generally the cheapest,
followed by switches, and then routers 12. However,
the cost can vary depending on the brand, the
number of ports, and other added features?
(c) Explain POP and IMAP. What are the advantages of IMAP
over POP ?
**POP (Post Office Protocol)**24;
POP is a protocol used to download emails from a mail server
to a local device (like your
computer or phone). Once the emails are downloaded, they
are deleted from the server. This means that the emails can
only be accessed using the same device they were
downloaded to'. However, many POP setups allow you to
leave copies of your email on the server.
**Advantages of POP**57:
- Emails can be read offline.
- Uses less storage space on the server as emails are stored
locally.
- Quick and easy access ot emails as they are already on
your device. - Less requirement for server storage capacity.
**Disadvantages of POP**57:
- No real-time synchronization.
- Emails can't be accessed from multiple devices.
- Risk of losing emails fi the local storage is compromised.
**IMAP (Internet Message Access Protocol) *12:
IMAP is a more advanced protocol that allows you to access
your email from any device, as
the emails are stored on the server. When you read an email
using IMAP, you aren't actually downloading or storing ti on
your device; instead, you're reading ti from the email service'.
IMAP only downloads a message when you click on ,ti and
attachments aren't automatically downloaded'.
**Advantages of IMAP over POP**56:
- Two-way synchronized communication between the email
server and the email client,
allowing several devices to work on the same account and
see the changes made by everyone.
- Emails are on the server all the time, so they can be
accessed from any place with internet access.
- In case of a computer crash or accidental deletion of data,
since emails are on the mail server, it is possible to get the
emails back".
- Utilises minimal local storage as the emails are stored on the
mail server". - Allows for efficient searching and sorting of
emails on the server".
**Disadvantages of IMAP**5:
- Requires an active internet connection to read, reply, and
search messages'.
- If email usage is high, you would need a larger mailbox
storage which might cost more'. - Accessing mails can be
slower as compared to POP3, as al folders get synchronized
every time there is a Send/Receive.
In summary, if you only access your email from one device
and prefer to store emails locally, POP might be the better
choice. But if you want to access your email from multiple
devices
and prefer the flexibility of storing emails on the server, IMAP
would be the better option'
(d) Compare CSMA/CD and Ethernet protocol.
compare CSMA/CD and Ethernet protocol.
**CSMA/CD (Carrier Sense Multiple Access with Collision Detection)
*124:
CSMA/CD is a network protocol for carrier transmission that operates in
the medium access control layer?. tI is used to organise data
transmission properly in a local Ethernet network (EEE 802.3), where all
network participants usually meet on a common transmission medium -
a cable'. This technique isn't suitable for WLAN'.The acronym CSMA/CD
stands for "carrier-sense multiple access with collision detection," and it
describes how Ethernet regulates the communication between nodes
(devices) in a network®. In CSMA/CD, a device listens to the channel
before transmitting, to ensure that it is not currently in use by another
device'. If a collision is detected during transmission, the transmission is
stopped, and a jam signal is sent by the stations. Then the station waits
for a random time context before retransmission?.
**Ethernet Protocol**:
Ethernet is a family of computer networking technologies commonly
used in local area
networks (LAN), metropolitan area networks (MAN), and wide area
networks (WAN). It was commercially introduced in 1980 and first
standardized in 1983 as IEEE 802.35. Ethernet has
since been refined to support higher bit rates, a greater number of
nodes, and longer link distances, but retains much backward
compatibility.
CSMA/CD is a fundamental protocol in Ethernet. In other words,
Ethernet uses CSMA/CD for media access control. tI is the method used
to regulate traffic on the network and avoid collisions when multiple
devices start sending data at the same time".
In summary, CSMA/CD is a protocol used within Ethernet to ensure that
data transmissions occur without collisions. So, they are not exactly
comparable as one is a part of the other.
(e) How does circuit switching and packet
switching differ ? Give merits and demerits
of both.
discuss the differences between circuit switching and packet switching,
along with their merits and demerits.
**Circuit Switching**12121314:
Circuit switching is a communication method where a dedicated
communication path, or circuit, is established between two devices
before data transmission begins. The circuit remains dedicated to the
communication for the duration of the session, and no other devices can
use it while the session is in progress?.
*Merits of Circuit Switching*121314;
- Guaranteed bandwidth: Circuit switching provides a dedicated path for
communication, ensuring that bandwidth is guaranteed for the duration
of the call'.
- Low latency: Circuit switching provides low latency because the path is
predetermined, and there is no need to establish a connection for each
packet.
- Predictable performance: Circuit switching provides predictable
performance because the bandwidth is reserved, and there is no
competition for resources 21
- Suitable for real-time communication: Circuit switching is suitable for
real-time
communication, such as voice and video, because it provides low
latency and predictable performance 12
*Demerits of Circuit Switching*121314:
- Inefficient use of bandwidth: Circuit switching is inefficient because the
bandwidth is reserved for the entire duration of the call, even when no
data is being transmitted 2.
- Limited scalability: Circuit switching is limited in its scalability because
the number of
circuits that can be established is finite, which can limit the number of
simultaneous calls that c a n b e m a d e 21
- High cost: Circuit switching is expensive because it requires dedicated
resources, such as hardware and bandwidth, for the duration of the
call'2.
**Packet Switching**12679[^10^]:
Packet switching is a communication method where data is divided into
smaller units called
packets and transmitted over the network 2. Each packet contains the
source and destination addresses, as well as other information needed
for routing. The packets may take different paths to reach their
destination, and they may be transmitted out of order or delayed due to
network congestion12
*Merits of Packet Switching*67°[^109]":
- Efficient use of bandwidth: Packet switching is efficient because
bandwidth is shared
among multiple users, and resources are allocated only when data
needs to be transmitted". - Flexible: Packet switching is flexible and can
handle a wide range of data rates and packet sizes®
- Scalable: Packet switching is highly scalable and can handle large
amounts of traffic on a network®.
- Lower cost: Packet switching is less expensive than circuit switching
because resources are shared among multiple users®
*Demerits of Packet Switching *679[^10^]':
- Higher latency: Packet switching has higher latency than circuit
switching because packets must be routed through multiple nodes,
which can cause delay®.
- Limited QoS: Packet switching provides limited QoS guarantees,
meaning that different types of traffic may be treated equally®.
In summary, circuit switching is more suitable for real-time
communication with guaranteed bandwidth and low latency, but it si less
efficient and more costly. On the other hand, packet switching is more
efficient, flexible, scalable, and cost-effective, but it has higher latency
and limited QoS guarantees.
(f) Write the steps of Distance Vector Routing
Algorithm. Show case the working of this algorithm with
an example.
let's discuss the steps of the Distance Vector Routing
Algorithm and illustrate its working with an example.
**Steps of Distance Vector Routing Algorithm**12:
.1 **Initialization**: Each router prepares its routing table
using its local knowledge. By their local knowledge, each
router knows about all the routers present in the network
and the distance to its neighboring routers 12.
2. **Exchange of Distance Vectors**: Each router
exchanges its distance vector with its neighboring
routers. Each router prepares a new routing table using
the distance vectors it has obtained from its neighbors21
3. **Vector Update Iterative Process**: This step is
repeated for (n-2) times fi there are n routers in the
network. After this, routing tables converge or become
stable 12.
.4 **Routing Table Update**: The routing table is
updated based on the information received from
neighboring routers21
Now, let's consider an example to understand the
working of this algorithm':
Consider a network consisting of 4 routers A, B, C, and
D. The weights are mentioned on the edges. Weights
could be distances or costs or delays'.
**Step-01**: Each router prepares its routing table using
its local knowledge'. For instance, the routing table
prepared by router Ais:

**Step-02**: Each router exchanges its distance vector


obtained ni Step-01 with its neighbors. After exchanging
the distance vectors, each router prepares a new
routing table'. For instance, router Areceives distance
vectors from its neighbors B and D. Router A prepares a
new routing table as:
The cost of reaching destination Bfrom
router Ais calculated as the minimum of
{2+0, 1+7} = 2 via B'. Similarly, the cost of
reaching destination C from router A is
calculated as the minimum of {2+3, 1+11} =
5 via B'. The cost of reaching destination
Dfrom router Ais calculated as the minimum
of {2+7, 1+0} = 1 via D'.
This process is repeated until the routing
tables at all routers converge or become
stable'2. The final routing table at router A is:

This is how the Distance Vector Routing


Algorithm works
Q. Explain the working of 3 way handshake
used in TCP using suitable diagram.
This is how the Distance Vector Routing
Algorithm works 12.
Sure, let's discuss the working of the 3-way
handshake used in TCP.
The 3-way handshake is a process used in
the TCP/IP protocol to establish a
connection between a client and a servers. It
is called a "3-way handshake" because ti
involves three steps*5:
.1 **SYN**: The client sends a SYN
(Synchronize Sequence Number) packet to
the server. This packet informs the server
that the client wants to establish a
connection and indicates
the sequence number that the client wil use
to start the sequence of packets 5
2. **SYN-ACK**: The server responds ot the
client's SYN packet with a SYN-ACK packet.
The ACK (Acknowledgement) part of this
packet confirms that the server has received
the
client's SYN packet. The SYN part of this
packet indicates the sequence number that
the server will use to start its sequence of
packets*s
3. **ACK**: Finally, the client sends an ACK
packet to the server to acknowledge the
receipt of the server's SYN-ACK packet.
This completes the 3-way handshake, and
the connection is establisheds.
Here's a simple diagram to illustrate the
process: ..•

In this diagram, x' and y' are the initial


sequence numbers chosen by the client and
server, respectively. The client initiates the
handshake by sending a SYN packet with
sequence number x. The server responds
with a SYN-ACK packet with sequence
number y and acknowledgement number x'
+1*. Finally, the client sends an ACK packet
with sequence number x+1 and
acknowledgement number y+1*, completing
the handshake*s
This 3-way handshake process allows both
the client and the server to synchronize their
sequence numbers before any actual data
transmission begins. It ensures that both
sides are ready for data transmission and
have agreed on initial sequence numbers+5

(b) What is Windowing ? How are flow


control
and reliability achieved through
windowing at transport layer ?
**Windowing**", also known as the
sliding window protocol, is a method
used in networking
for controlling the flow of data packets
between two network devices'3. It
ensures the reliable and sequential
delivery of data packets. The concept of
windowing is used in the Transmission
Control Protocol (TCP) at the transport
layer'3.
Here's how **flow control** and
**reliability** are achieved through
windowing at the transport layer:
**Flow Control**6712:
Flow control is achieved in TCP using the
sliding window protocol. The receiver
advertises a
window size, indicating the number of
bytes its buffer can hold®. The sender
transmits data segments up to this
advertised window. This prevents the
sender from flooding the receiver with
data, ensuring that the receiver can work
efficiently?. If the receiver's buffer starts
to fil
up, it advertises a smaller window size ot
the sender, slowing down the data
transmission®?. Conversely, fi the
receiver's buffer has plenty of free space,
it advertises a larger window size,
allowing the sender to transmit data
faster"
**Reliability**°[^10^]":
Reliability is achieved through the use of
acknowledgements and retransmissions.
When the sender transmits a segment, it
starts a timer and waits for an
acknowledgement from the
receiver'[^10^]". fI the acknowledgement
is not received within a certain time
period (known as the timeout period), the
sender assumes that the segment was
lost in transit and retransmits it'[^10^]".
This ensures that even fi data segments
are lost or arrive out of order, they can be
retransmitted or reordered to provide a
reliable, in-order stream of data'[^10%]".
In summary, windowing in TCP allows for
efficient data transmission by controlling
the flow of data and ensuring reliability
through the use of acknowledgements
and retransmissions
3. (a) List various connecting devices in a
LAN. Explain the functioning of each. Also
show the interconnectivity between devices
with suitable diagram.

1. **Network Interface Card (NIC)**[^10^]: A


NIC, also known as a network adapter or
Ethernet adapter, is a hardware device that
allows devices to connect to a LAN. tI acts as
an interface between the device and the
network, facilitating communication and data
transfer .21
2. **Repeater**: Arepeater operates at the
physical layer. Its job is to regenerate the
signal
over the same network before the signal
becomes too weak or corrupted, to extend the
length to which the signal can be transmitted
over the same network'.
3. **Hub**1: Ahub is a multi-port repeater. tI
connects multiple wires coming from different
branches. Hubs cannot filter data, so data
packets are sent to al connected devices'.
There are three types of hubs':
- **Active Hub**: These hubs have their power
supply and can clean, boost, and relay the
signal along with the network'.
- **Passive Hub**: These hubs collect wiring
from nodes and power supply from the active
hub. They relay signals onto the network
without cleaning and boosting them'.
- **Intelligent Hub**: tI works like an active hub
and includes remote management capabilities.
They also provide flexible data rates to
network devices'.
4. **Bridge**: A bridge operates at the data link
layer. It is a repeater, with the added
functionality of filtering content by reading the
MAC addresses of the source and destination.
It is also used for interconnecting two LANs
working on the same protocol'.
5. **Switch**: Aswitch is a device that
connects multiple devices on a LAN. tI uses
packet switching to receive, process, and
forward data to the destination device.
6. **Router**: A router is a device that
forwards data packets between computer
networks. Routers perform the traffic directing
functions on the internet. Adata packet is
typically forwarded from one router to another
through the networks that constitute the
internetwork until it reaches its destination
node.
Here's a simple diagram to illustrate the
interconnectivity between these devices

In this diagram, the router connects the


LAN to the internet. The switch connects
multiple devices on the LAN, including
the NIC (which connects PC1), the hub
(which connects PC2),

and the bridge (which connects PC3).


The lines between the devices represent
Ethernet cables or wireless
connections34511.

4. (a) Differentiate between Analog and


Digital Modulation. Compare and contrast
between ASK, PSK and FSK (digital
modulation techniques).

**Analog Modulation vs Digital


Modulation**678:
- **Analog Modulation**: In analog
modulation, both the carrier and message
signals are
analog waves. The signal is varied in
amplitude or frequency. It's a continuous
signal that can take up any value (in a
possible range)*?.
- **Digital Modulation**: In digital modulation,
only the carrier signal is analog and the
message signal is in digital form. The signal
is converted into a digital format. It's a
discrete signal that can only convey binary
information®. The main difference between
analog and digital modulation is that analog
signals can be recovered without any error,
while digital signals may suffer from errors
during recovery®.
Now, let's compare and contrast between
ASK, PSK, and FSK:
**Amplitude Shift Keying (ASK) *135:
- In ASK, each symbol ni the message signal
gives a unique amplitude to the carrier
wave'. - ASK is simple to generate and has
less complex circuitry ni comparison ot FSK
and PSK.
- However, as noise is very sensitive to
amplitude, ASK has poor noise immunity?. -
ASK is less expensive to set up than digital
modulation'.
**Frequency Shift Keying (FSK)**123:
- In FSK, the frequency of the RF carrier is
varied in accordance with the baseband
digital
input'.
- FSK is less susceptible to errors than ASK.
- FSK is suitable for high-frequency
communication as modulation deals with two
different high carrier frequencies?.
- FSK is less expensive to set up than digital
modulations.
**Phase Shift Keying (PSK)**124:
-In PSK, the phase of the carrier wave is
varied in accordance with the baseband digital
input'.
- PSK has good noise rejection capability and
the system generates a smaller noise
bandwidth'.
- PSK is less expensive to set up than digital
modulation'.
In summary, ASK, FSK, and PSK are al digital
modulation techniques that vary the amplitude,
frequency, and phase of the carrier signal
respectively, based on the digital input signal
12345
(b) What is MD5 ? Write step by step
procedure for generating 128 bit MD5
Digest.

**MD5 (Message Digest Algorithm 5) *


is a widely used cryptographic hash
function that produces a 128-bit (16-
byte) hash value. tI is commonly used
to verify data integrity?. MD5 was
designed by Ronald Rivest in 199112.
Here is the step-by-step procedure for
generating a 128-bit MD5 digest':
.1 **Append Padding Bits**: The
original message is padded so that its
length becomes
equal to 448, modulo 512'. This means
that the length of the message after
padding is 64 bits less than an exact
multiple of 512'. Padding is done even fi
the length of the message is
already 448 mod 512'.
2. **Append Length Bits**: A64-bit
representation of the length of the
original message (before the padding)
is appended to the result of the
previous step'. After this step, the
length of the message wil be an exact
multiple of 512'.
3. **Initialize MD Buffer**: Four buffers
(A, B, C, D) of 32-bit each are used.
They are initialized to certain fixed
constants'
4. **Process Message ni 16-Word
Blocks**: The prepared message from
the previous steps
si processed in 512-bit blocks, each
block containing 16 words of 32 bits'.
Each block si processed ni four rounds,
and each round has 16 operations
based on a non-linear function F,
modular addition, and left rotation'.
Note that the functions used in each
round are different'.
5. **Output**: After al 512-bit blocks
have been processed, the digest is
formed by the concatenation of the
buffers (A, B, C, D) ni that order'.

This is a high-level overview of the


MD5 algorithm. The actual
implementation would involve bitwise
operations and manipulations for the
processing of the 512-bit blocks'.
5. (a) Differentiate between adaptive and
non adaptive routing. Explain the working of
hierarchical routing using suitable
topological structure and routing table

.1 **Adaptive Routing**:
- **Definition**: Adaptive routing refers to a
dynamic approach where routing decisions
are made based on real-time network
conditions. tI adapts ot changes ni link
status, traffic load, and topology.
- **Working**:
- When a packet needs to be forwarded, the
router evaluates various paths based on
metrics (e.g., delay, bandwidth, congestion).
- The router selects the best path
dynamically, considering the current state of
the network.
- Examples of adaptive routing algorithms
include **Distance Vector**, **Link State**,
and **Path Vector** protocols.

b) Discuss the error control techniques used


at the data link layer. Also write the step
by step procedure of Go-BACK-N ARQ
Method.
Certainly! Let's start by discussing error
control techniques at the data link layer, and
then I'l provide a step-by-step procedure for
the Go-Back-N Automatic Repeat Request
(ARQ) method.
## Error Control Techniques in Data Link
Layer
### .1 **Error Detection**:
- Error detection involves identifying errors in
transmitted data frames. Common
techniques include:
- **Parity Check**: Adds an extra bit (parity
bit) to each data frame. The receiver checks
parity to detect errors.
- **Checksum**: Computes a checksum
value based on the frame's content. The
receiver
verifies the checksum to detect errors.
- **Cyclic Redundancy Check (CRC)**: Uses
polynomial division to generate a checksum.
Widely used due to its effectiveness?.
### 2. **Error Correction**:
- Error correction aims to fix errors in
received data. However, it is more complex
and
costly.
- **Forward Error Correction (FEC)**: Adds
redundant bits to the data frame. The
receiver
uses these redundant bits to correct errors
without requesting retransmission.
- FEC methods include **Hamming Codes**,
**Reed-Solomon Codes**, and * Turbo
C odes**
### Flow Control Techniques:
- Flow control ensures efficient data transfer
between sender and receiver. It prevents
congestion and overloading.
- **Stop-and-Wait ARQ**: Simplest flow
control mechanism. Sender waits for
acknowledgement (ACK) after sending each
frame. fI no ACK, retransmit the frame. -
**Sliding Window ARQ**:
- **Go-Back-N ARQ**: N represents the
sender's window size. Multiple frames are
sent
before expecting ACK. fI ACK not received
within a timeout, retransmit al subsequent
frames.
- **Selective Repeat ARQ**: Allows
retransmission of only the lost frames,
improving efficiency®.
# Go-Back-N ARQ Method (Step-by-Step)
.1 **Sender Side**:
- Divide the data stream into fixed-size
frames.
- Maintain a sliding window of size N
(number of frames). - Send N frames
sequentially to the receiver.
- Wait for ACK from the receiver.
2. **Receiver Side**:
- Receive frames in order.
- fI a frame is received correctly, send an
ACK for that frame. - fI a frame is lost or
corrupted, discard it.
- If a frame is out of order, discard ti (Go-
Back-N does not handle out-of-order
frames).
3. **Sender Actions**:
- If ACK received for frame ,i slide the
window to include frame i+1.
- If ACK is not received within a timeout,
retransmit al frames from it onward.

- Continue sending frames until the entire


data stream is transmitted.
4. **Receiver Actions**:
- If a frame is received out of order,
discard .ti
- fI a frame is lost or corrupted, discard it.
- Send cumulative ACK for the last correctly
received frame (ACK for frame i means all
frames up to i have been received).
5. **Timeout Handling**:
- Sender sets a timeout for receiving ACK.
-fIatimeoutoccurs,retransmitalframesni
thecurrentwindow.
6. **Advantages of Go-Back-N ARQ*:
- Simple implementation.
- Efficient for reliable channels with low error
rates.
- Minimal buffer requirements.
7. **Disadvantages of Go-Back-N ARQ**:
- Inefficient for high error rates (due ot
frequent retransmissions).
- Wastes bandwidth when only a few frames
are lost.
Remember, Go-Back-N ARQ balances
simplicity and efficiency, making ti suitable
for specific network conditions.

You might also like