0% found this document useful (0 votes)
47 views19 pages

CN Answers

A computer network connects computing devices to allow sharing of resources and exchange of data. It allows file sharing, remote access, and distributed applications using a client-server model. Key components include servers, clients, transmission media, shared data, printers, network interface cards, operating systems, hubs, switches, routers, and cables.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
47 views19 pages

CN Answers

A computer network connects computing devices to allow sharing of resources and exchange of data. It allows file sharing, remote access, and distributed applications using a client-server model. Key components include servers, clients, transmission media, shared data, printers, network interface cards, operating systems, hubs, switches, routers, and cables.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 19

UNIT 1

1. Define computer networks its advantages and applications?

A computer network is a digital telecommunications network which allows nodes to share


resources. In computer networks, computing devices exchange data with each other using
connections (data links) between nodes. These data links are established over cable media such as
wires or optic cables, or wireless media such as Wi-Fi.
Or
A computer 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 or receiving data
from the other node/device through the network.
Advantages of Computer Network
 File sharing: Fundamental goals of a computer network is to allow file sharing and remote file
access.

 Server-Client model: Client-server model is a distributed application framework. The server is


a master system which stores the data and provides the processing service.

 Resource sharing: All the resources such as printers, modems, scanners and fax machines etc
can be shared by all the system in a computer network.

 Better connectivity and communications: A computer network allows all the user or
computers at a different location to communicate easily, widely used example is email, video
conference etc.
Disadvantages of Computer Network
 Lack of data security and privacy due to the huge number of the user accessing the internet
from every corner of the earth, handling data is a challenging task and data can be stolen which
violate the privacy of the user.

 Presence of computer viruses and the malware: A virus can easily spread through an
interconnected workstation or over the internet which can damage or steal the data from the
computer system in a computer network.

 Lack of Independence: In most cases, the client is dependent on the centralized server and
client user lack any freedom whatsoever. the centralized server can make hinder in the decision
making of the user system.

 Lack of Robustness: As a client is dependent on the centralized server, if the centralized


server breaks down, the entire system of networks would be useless and also if any of the links
between the end system fail then the network will standstill.

 Need an efficient handler: As a computer network consisting of many devices and software,
so to handle the smooth functioning of the transmission of information, it requires high
technical skills and knows- how its administration and its operations.

2.Explain the basic components of a network?


Chadhivi ardham chesukoni rayandi brief ga any 6
Servers - Servers are computers that hold shared files, programs, and the network operating system. Servers provide access to
network resources to all the users of the network. There are many different kinds of servers, and one server can provide several
functions. For example, there are file servers, print servers, mail servers, communication servers, database servers, fax servers
and web servers, to name a few. Sometimes it is also called host computer, servers are powerful computer that store data or
application and connect to resources that are shared by the user of a network.
Clients - Clients are computers that access and use the network and shared network resources. Client computers are basically the
customers(users) of the network, as they request and receive services from the servers. These days, it is typical for a client to be a
personal computer that the users also use for their own non-network applications.
Transmission Media - Transmission media are the facilities used to interconnect computers in a network, such as twisted-pair
wire, coaxial cable, and optical fiber cable. Transmission media are sometimes called transmission medium channels, links or
lines.
Shared data - Shared data are data that file servers provide to clients such as data files, printer access programs and e-mail.
Shared printers and other peripherals - Shared printers and peripherals are hardware resources provided to the users of the
network by servers. Resources provided include data files, printers, software, or any other items used by clients on the network.
Network Interface Card - Each computer in a network has a special expansion card called a network interface card (NIC). The
NIC prepares(formats) and sends data, receives data, and controls data flow between the computer and the network. On the
transmit side, the NIC passes frames of data on to the physical layer, which transmits the data to the physical link. On the
receiver's side, the NIC processes bits received from the physical layer and processes the message based on its contents.
Local Operating System - A local operating system allows personal computers to access files, print to a local printer, and have
and use one or more disk and CD drives that are located on the computer. Examples are MS-DOS, Unix, Linux, Windows 2000,
Windows 98, Windows XP etc. The network operating system is the software of the network. It serves a similar purpose that the
OS serves in a stand-alone computer
Network Operating System - The network operating system is a program that runs on computers and servers that allows the
computers to communicate over the network.
Hub - Hub is a device that splits a network connection into multiple computers. It is like a distribution center. When a computer
requests information from a network or a specific computer, it sends the request to the hub through a cable. The hub will receive
the request and transmit it to the entire network. Each computer in the network should then figure out whether the broadcast data
is for them or not.
Switch - Switch is a telecommunication device grouped as one of computer network components. Switch is like a Hub but built
in with advanced features. It uses physical device addresses in each incoming messages so that it can deliver the message to the
right destination or port.
Unlike a hub, switch doesn't broadcast the received message to entire network, rather before sending it checks to which system or
port should the message be sent. In other words, switch connects the source and destination directly which increases the speed of
the network. Both switch and hub have common features: Multiple RJ-45 ports, power supply and connection lights.
Router - When we talk about computer network components, the other device that used to connect a LAN with an internet
connection is called Router. When you have two distinct networks (LANs) or want to share a single internet connection to
multiple computers, we use a Router. In most cases, recent routers also include a switch which in other words can be used as a
switch. You don’t need to buy both switch and router, particularly if you are installing small business and home networks. There
are two types of Router: wired and wireless. The choice depends on your physical office/home setting, speed and cost.
LAN Cable A local area Network cable is also known as data cable or Ethernet cable which is a wired cable used to connect a
device to the internet or to other devices like computer, printers, etc.

3.Differentiate between OSI and TCP/IP models?

OSI TCP/IP

OSI represents Open System Interconnection. TCP/IP model represents the Transmission Control
Protocol / Internet Protocol.

OSI is a generic, protocol independent standard. It is TCP/IP model depends on standard protocols about which
acting as an interaction gateway between the network the computer network has created. It is a connection
and the final-user. protocol that assigns the network of hosts over the
internet.

The OSI model was developed first, and then protocols The protocols were created first and then built the TCP/IP
were created to fit the network architecture’s needs. model.

It provides quality services. It does not provide quality services.

The OSI model represents defines administration, It does not mention the services, interfaces, and protocols.
interfaces and conventions. It describes clearly which
layer provides services.

The protocols of the OSI model are better unseen and The TCP/IP model protocols are not hidden, and we
can be returned with another appropriate protocol cannot fit a new protocol stack in it.
quickly.

It is difficult as distinguished to TCP/IP. It is simpler than OSI.


OSI TCP/IP

It provides both connection and connectionless oriented It provides connectionless transmission in the network
transmission in the network layer; however, only layer and supports connecting and connectionless-
connection-oriented transmission in the transport layer. oriented transmission in the transport layer.

It uses a horizontal approach. It uses a vertical approach.

The smallest size of the OSI header is 5 bytes. The smallest size of the TCP/IP header is 20 bytes.

Protocols are unknown in the OSI model and are In TCP/IP, returning protocol is not difficult.
returned while the technology modifies.

4. What are service primitives? Explain with neat diagram?

Service generally includes set of various primitives. A primitive simply means Operations.
A Service is specified by set of primitives that are available and given to user or other various
entities to access the service. All these primitives simply tell the service to perform some action or to
report on action that is taken by peer entity.
Primitives are called calling functions between the layers that are used to manage communication
among the adjacent protocol layers i.e., among the same communication node.
Classification of Service Primitives :
Primitive Meaning

Request This primitive is transferred or sent to Layer N by Layer (N+1) to just request
for service

Indicatio This primitive is returned by Layer N to Layer (N+1) to just advise of


activation of service that is being requested or of action that is initiated by the
n
service of Layer N.

Response This primitive is simply provided by Layer (N+1) in reply to indication


primitive. It might acknowledge or complete action that is previously invoked
by indication primitive.

Confirm This primitive is returned by the Nth layer to the requesting (N+1)st layer to
simply acknowledge or complete action that is previously invoked by request
primitive.
https://www.geeksforgeeks.org/service-primitives/

6.Explain about OSI model and illustrate the functions, protocols and services of
each layer
OSI Model
o OSI stands for Open System Interconnection is a reference model that describes how information
from a software application in one computer moves through a physical medium to the software
application in another computer.
o OSI consists of seven layers, and each layer performs a particular network function.
o OSI model was developed by the International Organization for Standardization (ISO) in 1984, and
it is now considered as an architectural model for the inter-computer communications.
o OSI model divides the whole task into seven smaller and manageable tasks. Each layer is assigned
a particular task.
o Each layer is self-contained, so that task assigned to each layer can be performed independently.

7 Layers of OSI Model


There are the seven OSI layers. Each layer has different functions. A list of seven layers are given below:

1. Physical Layer
2. Data-Link Layer
3. Network Layer
4. Transport Layer
5. Session Layer
6. Presentation Layer
7. Application Layer

1) Physical layer
o The main functionality of the physical layer is to transmit the individual bits from one node to
another node.
o It is the lowest layer of the OSI model.
o It establishes, maintains and deactivates the physical connection.
o It specifies the mechanical, electrical and procedural network interface specifications.

Functions of a Physical layer:

o Line Configuration: It defines the way how two or more devices can be connected physically.
o Data Transmission: It defines the transmission mode whether it is simplex, half-duplex or full-
duplex mode between the two devices on the network.
o Topology: It defines the way how network devices are arranged.
o Signals: It determines the type of the signal used for transmitting the information.

2) Data-Link Layer
o This layer is responsible for the error-free transfer of data frames.
o It defines the format of the data on the network.
o It provides a reliable and efficient communication between two or more devices.
o It is mainly responsible for the unique identification of each device that resides on a local
network.
o It contains two sub-layers:
o Logical Link Control Layer
o Media Access Control Layer

Functions of the Data-link layer

o Framing: The data link layer translates the physical's raw bit stream into packets known as
Frames. The Data link layer adds the header and trailer to the frame. .

o Physical Addressing: The Data link layer adds a header to the frame that contains a destination
address. The frame is transmitted to the destination address mentioned in the header.
o Flow Control: Flow control is the main functionality of the Data-link layer. It is the technique
through which the constant data rate is maintained on both the sides so that no data get corrupted. It
ensures that the transmitting station such as a server with higher processing speed does not exceed
the receiving station, with lower processing speed.
o Error Control: Error control is achieved by adding a calculated value CRC (Cyclic Redundancy
Check) that is placed to the Data link layer's trailer which is added to the message frame before it is
sent to the physical layer. If any error seems to occurr, then the receiver sends the acknowledgment
for the retransmission of the corrupted frames.
o Access Control: When two or more devices are connected to the same communication channel,
then the data link layer protocols are used to determine which device has control over the link at a
given time.

3) Network Layer
o It is a layer 3 that manages device addressing, tracks the location of devices on the network.
o It determines the best path to move data from source to the destination based on the network
conditions, the priority of service, and other factors.
o The Data link layer is responsible for routing and forwarding the packets.

o The protocols used to route the network traffic are known as Network layer protocols. Examples of
protocols are IPv4 and Ipv6.

Functions of Network Layer:

o Internetworking: An internetworking is the main responsibility of the network layer. It provides a


logical connection between different devices.
o Addressing: A Network layer adds the source and destination address to the header of the frame.
Addressing is used to identify the device on the internet.
o Routing: Routing is the major component of the network layer, and it determines the best optimal
path out of the multiple paths from source to the destination.
o Packetizing: A Network Layer receives the packets from the upper layer and converts them into
packets. This process is known as Packetizing. It is achieved by internet protocol (IP).

4) Transport Layer
o The Transport layer is a Layer 4 ensures that messages are transmitted in the order in which they
are sent and there is no duplication of data.
o The main responsibility of the transport layer is to transfer the data completely.
o It receives the data from the upper layer and converts them into smaller units known as segments.

The two protocols used in this layer are:

o Transmission Control Protocol

User Datagram Protocol’


Functions of Transport Layer:

o Service-point addressing: Computers run several programs simultaneously due to this reason, the
transmission of data from source to the destination not only from one computer to another
computer but also from one process to another process.

o Segmentation and reassembly: When the transport layer receives the message from the upper
layer, it divides the message into multiple segments, and each segment is assigned with a sequence
number that uniquely identifies each segment. When the message has arrived at the destination,
then the transport layer reassembles the message based on their sequence numbers.
o Connection control: Transport layer provides two services Connection-oriented service and
connectionless service. A connectionless service treats each segment as an individual packet, and
they all travel in different routes to reach the destination. A connection-oriented service makes a
connection with the transport layer at the destination machine before delivering the packets.

o Flow control: The transport layer also responsible for flow control but it is performed end-to-end
rather than across a single link.
o Error control: The transport layer is also responsible for Error control. Error control is performed
end-to-end rather than across the single link. The sender transport layer ensures that message reach
at the destination without any error.

5) Session Layer
o It is a layer 3 in the OSI model.
o The Session layer is used to establish, maintain and synchronizes the interaction between
communicating devices.

Functions of Session layer:

o Dialog control: Session layer acts as a dialog controller that creates a dialog between two
processes or we can say that it allows the communication between two processes which can be
either half-duplex or full-duplex.
o Synchronization: Session layer adds some checkpoints when transmitting the data in a sequence.
If some error occurs in the middle of the transmission of data, then the transmission will take place
again from the checkpoint.

6) Presentation Layer

o A Presentation layer is mainly concerned with the syntax and semantics of the information
exchanged between the two systems.
o It acts as a data translator for a network.
o The Presentation layer is also known as the syntax layer.

Functions of Presentation layer:


o Translation: The processes in two systems exchange the information in the form of character
strings, numbers and so on. Different computers use different encoding methods, the presentation
layer handles the interoperability between the different encoding methods. It converts the data from
sender-dependent format into a common format and changes the common format into receiver-
dependent format at the receiving end.
o Encryption: Encryption is needed to maintain privacy. Encryption is a process of converting the
sender-transmitted information into another form and sends the resulting message over the
network.
o Compression: Data compression is a process of compressing the data, i.e., it reduces the number
of bits to be transmitted. Data compression is very important in multimedia such as text, audio,
video.

7) Application Layer

o An application layer serves as a window for users and application processes to access network
service.
o It handles issues such as network transparency, resource allocation, etc.
o An application layer is not an application, but it performs the application layer functions.
o This layer provides the network services to the end-users.

Functions of Application layer:

o File transfer, access, and management (FTAM): An application layer allows a user to access the
files in a remote computer, to retrieve the files from a computer and to manage the files in a remote
computer.
o Mail services: An application layer provides the facility for email forwarding and storage.
o Directory services: An application provides the distributed database sources and is used to provide
that global information about various objects.

7.Explain about TCP/IP model and illustrate the functions, protocols and
services of
each layer?

The OSI Model we just looked at is just a reference/logical model. It was designed to describe the
functions of the communication system by dividing the communication procedure into smaller and
simpler components. But when we talk about the TCP/IP model, it was designed and developed by
Department of Defense (DoD) in 1960s and is based on standard protocols. It stands for
Transmission Control Protocol/Internet Protocol. The TCP/IP model is a concise version of the OSI
model. It contains four layers, unlike seven layers in the OSI model. The layers are:
1. Process/Application Layer
2. Host-to-Host/Transport Layer
3. Internet Layer
4. Network Access/Link Layer
TCP/IP
TCP refers to Transmission Control Protocol.
TCP/IP has 4 layers.

TCP/IP is more reliable

TCP/IP does not have very strict boundaries.

TCP/IP follow a horizontal approach.

TCP/IP uses both session and presentation layer in the application layer itself.

TCP/IP developed protocols then model.

Transport layer in TCP/IP does not provide assurance delivery of packets.

TCP/IP model network layer only provides connection less services.

Protocols cannot be replaced easily in TCP/IP model.

1. Network Access Layer –

This layer corresponds to the combination of Data Link Layer and Physical Layer of the OSI model.
It looks out for hardware addressing and the protocols present in this layer allows for the physical
transmission of data.

2. Internet Layer –

This layer parallels the functions of OSI’s Network layer. It defines the protocols which are
responsible for logical transmission of data over the entire network. The main protocols residing at
this layer are :
1. IP – stands for Internet Protocol and it is responsible for delivering packets from the source host
to the destination host by looking at the IP addresses in the packet headers. IP has 2 versions:
IPv4 and IPv6. IPv4 is the one that most of the websites are using currently. But IPv6 is growing
as the number of IPv4 addresses are limited in number when compared to the number of users.
2. ICMP – stands for Internet Control Message Protocol. It is encapsulated within IP datagrams and
is responsible for providing hosts with information about network problems.
3. ARP – stands for Address Resolution Protocol. Its job is to find the hardware address of a host
from a known IP address. ARP has several types: Reverse ARP, Proxy ARP, Gratuitous ARP and
Inverse ARP.

3. Host-to-Host Layer –

This layer is analogous to the transport layer of the OSI model. It is responsible for end-to-end
communication and error-free delivery of data. It shields the upper-layer applications from the
complexities of data. The two main protocols present in this layer are :
1. Transmission Control Protocol (TCP) – It is known to provide reliable and error-free
communication between end systems. It performs sequencing and segmentation of data. It also
has acknowledgment feature and controls the flow of the data through flow control mechanism. It
is a very effective protocol but has a lot of overhead due to such features. Increased overhead
leads to increased cost.
2. User Datagram Protocol (UDP) – On the other hand does not provide any such features. It is
the go-to protocol if your application does not require reliable transport as it is very cost-
effective. Unlike TCP, which is connection-oriented protocol, UDP is connectionless.

4. Application Layer –

This layer performs the functions of top three layers of the OSI model: Application, Presentation and
Session Layer. It is responsible for node-to-node communication and controls user-interface
specifications. Some of the protocols present in this layer are: HTTP, HTTPS, FTP, TFTP, Telnet,
SSH, SMTP, SNMP, NTP, DNS, DHCP, NFS, X Window, LPD. Have a look at Protocols in
Application Layer for some information about these protocols. Protocols other than those present in
the linked article are :
1. HTTP and HTTPS – HTTP stands for Hypertext transfer protocol. It is used by the World Wide
Web to manage communications between web browsers and servers. HTTPS stands for HTTP-
Secure. It is a combination of HTTP with SSL(Secure Socket Layer).
2. SSH – SSH stands for Secure Shell. It is a terminal emulations software similar to Telnet. The
reason SSH is more preferred is because of its ability to maintain the encrypted connection. It
sets up a secure session over a TCP/IP connection.
3. NTP – NTP stands for Network Time Protocol. It is used to synchronize the clocks on our
computer to one standard time source. It is very useful in situations like bank transactions.
Assume the following situation without the presence of NTP.

8.Discuss about LAN, WAN, MAN in brief with an example?


The Network allows computers to connect and communicate with different computers via any
medium. LAN, MAN, and WAN are the three major types of networks designed to operate over the
area they cover. There are some similarities and dissimilarities between them. One of the major
differences is the geographical area they cover, i.e. LAN covers the smallest area; MAN covers an
area larger than LAN and WAN comprises the largest of all.
Local Area Network (LAN) –
LAN or Local Area Network connects network devices in such a way that personal computers and
workstations can share data, tools, and programs. The group of computers and devices are connected
together by a switch, or stack of switches, using a private addressing scheme as defined by the
TCP/IP protocol. Private addresses are unique in relation to other computers on the local network.
Routers are found at the boundary of a LAN, connecting them to the larger WAN.
Data transmits at a very fast rate as the number of computers linked is limited. By definition, the
connections must be high speed and relatively inexpensive hardware (Such as hubs, network
adapters, and Ethernet cables). LANs cover a smaller geographical area (Size is limited to a few
kilometers) and are privately owned. One can use it for an office building, home, hospital, schools,
etc. LAN is easy to design and maintain. A Communication medium used for LAN has twisted-pair
cables and coaxial cables. It covers a short distance, and so the error and noise are minimized.
Early LANs had data rates in the 4 to 16 Mbps range. Today, speeds are normally 100 or 1000 Mbps.
Propagation delay is very short in a LAN. The smallest LAN may only use two computers, while
larger LANs can accommodate thousands of computers.
Metropolitan Area Network (MAN) –
MAN or Metropolitan area Network covers a larger area than that of a LAN and smaller area as
compared to WAN. It connects two or more computers that are apart but reside in the same or
different cities. It covers a large geographical area and may serve as an ISP (Internet Service
Provider). MAN is designed for customers who need high-speed connectivity. Speeds of MAN range
in terms of Mbps. It’s hard to design and maintain a Metropolitan Area Network.
The fault tolerance of a MAN is less and also there is more congestion in the network. It is costly
and may or may not be owned by a single organization. The data transfer rate and the propagation
delay of MAN are moderate. Devices used for transmission of data through MAN are Modem and
Wire/Cable. Examples of a MAN are the part of the telephone company network that can provide a
high-speed DSL line to the customer or the cable TV network in a city.
Wide Area Network (WAN) –
WAN or Wide Area Network is a computer network that extends over a large geographical area,
although it might be confined within the bounds of a state or country. A WAN could be a connection
of LAN connecting to other LANs via telephone lines and radio waves and may be limited to an
enterprise (a corporation or an organization) or accessible to the public. The technology is high
speed and relatively expensive.
There are two types of WAN: Switched WAN and Point-to-Point WAN. WAN is difficult to design
and maintain. Similar to a MAN, the fault tolerance of a WAN is less and there is more congestion in
the network. A Communication medium used for WAN is PSTN or Satellite Link. Due to long-
distance transmission, the noise and error tend to be more in WAN.
WAN’s data rate is slow about a 10th LAN’s speed since it involves increased distance and
increased number of servers and terminals etc. Speeds of WAN ranges from a few kilobits per
second (Kbps) to megabits per second (Mbps). Propagation delay is one of the biggest problems
faced here. Devices used for the transmission of data through WAN are Optic wires, Microwaves,
and Satellites. An example of a Switched WAN is the asynchronous transfer mode (ATM) network
and Point-to-Point WAN is a dial-up line that connects a home computer to the Internet.

9.What is a topology and explain the various network topologies?


Network topology refers to the manner in which the links and nodes of a network are arranged to relate to
each other. Topologies are categorized as either physical network topology, which is the physical signal
transmission medium, or logical network topology, which refers to the manner in which data travels through
the network between devices, independent of physical connection of the devices. Logical network topology
examples include twisted pair Ethernet, which is categorized as a logical bus topology, and token ring, which
is categorized as a logical ring topology.
Physical network topology examples include star, mesh, tree, ring, point-to-point, circular, hybrid, and bus
topology networks, each consisting of different configurations of nodes and links. The ideal network
topology depends on each business’s size, scale, goals, and budget. A network topology diagram helps
visualize the communicating devices, which are modeled as nodes, and the connections between the devices,
which are modeled as links between the nodes.

Types of Network Topology


There are several different logical and physical network topologies from which administrators can choose to
build a secure, robust, and easily maintainable topology. The most popular configurations include:

 Bus network topology -- Also known as backbone network topology, this configuration connects
all devices to a main cable via drop lines. The advantages of bus network topology lie in its
simplicity, as there is less cable required than in alternative topologies, which makes for easy
installation.


 Mesh network topology -- A dedicated point-to-point link connects each device on the network to
another device on the network, only carrying data between two devices.

 Ring network topology -- Two dedicated point-to-point links connect a device to the two devices
located on either side of it, creating a ring of devices through which data is forwarded via repeaters
until it reaches the target device.


 Star network topology -- The most common network topology, star topology connects each device
in the network to a central hub. Devices can only communicate with each other indirectly through
the central hub.


 Hybrid network topology -- Any combination of two or more topologies is a hybrid topology.
 Tree network topology -- This topology consists of a parent-child hierarchy in which star networks
are interconnected via bus networks. Nodes branch out linearly from one root node, and two
connected nodes only share one mutual connection.


UNIT 2
1. Define flow control and error control?
Flow Control :
It is an important function of the Data Link Layer. It refers to a set of procedures that tells the sender
how much data it can transmit before waiting for acknowledgement from the receiver.
Purpose of Flow Control :
Any receiving device has a limited speed at which it can process incoming data and also a limited
amount of memory to store incoming data. If the source is sending the data at a faster rate than the
capacity of the receiver, there is a possibility of the receiver being swamped. The receiver will keep
losing some of the frames simply because they are arriving too quickly and the buffer is also getting
filled up.
This will generate waste frames on the network. Therefore, the receiving device must have some
mechanism to inform the sender to send fewer frames or stop transmission temporarily. In this way,
flow control will control the rate of frame transmission to a value that can be handled by the
receiver.
Example – Stop & Wait Protocol
2. Error Control :
The error control function of data link layer detects the errors in transmitted frames and re-transmit
all the erroneous frames.
Purpose of Error Control :
The function of the error control function of the data link layer helps in dealing with data frames that
are damaged in transit, data frames lost in transit, and the acknowledgement frames that are lost in
transmission. The method used for error control is called Automatic Repeat Request which is used
for the noisy channel. Example – Stop & Wait ARQ and Sliding Window ARQ

2. Discuss about checksum in brief. Also find the checksum at sender and
receiver for the sequence 10110011 10101011 01011010 11010101?
3. Differentiate between the backward error control and forward error control?
FEC
Forward Error Correction (FEC) is a type of error correction that involves encoding a message in a redundant way, which allows
the receiver to reconstruct lost bits without the need for retransmission.
FEC works by adding “check bits” to the outgoing data stream. Adding more check bits reduces the amount of
available bandwidth by increasing the overall block size of the outgoing data, but also enables the receiver to correct for more
errors without receiving any additional transmitted data.
This dynamic makes FEC ideal when bandwidth is plentiful, but retransmission is costly or impossible.
The “check bits,” or redundant bits, that the sender adds to the data stream are coded into the data in a very specific way, which
allows for efficient error correction by the receiving device.
BEC
Backward Error Correction, also known as an “Automatic Repeat Request” is an error correction technique in which a receiving
device sends a request to the source device to re-send information. Backward Error Correction is used in situations where some
of the transmitted data has been lost or corrupted during transit and the transmitting device must resend the information in order
for the receiving device to understand the transmission. Backward Error Correction is the opposite of “Forward Error
Correction”, in which a transmitting device simply sends redundant information to make up for any potential errors
Backward Error Correction is dependent on a number of protocols and algorithms, such as parity bits, cyclic redundancy checks,
and longitudinal redundancy checks, but relies on the same procedure. As usual, a transmitting device will send data to a
receiving device.

Forward Error Correction vs. Backward Error Correction


Forward Error Correction protocols impose a greater bandwidth overhead than backward error correction protocols, but are able
to recover from errors more quickly and with significantly fewer retransmissions.
Forward Error Correction also places a higher computational demand on the receiving device because the redundant information
in the transmission must be interpreted according to a predetermined algorithm.
.
4. Discuss about VRC and LRC with an example?

Parity check or vertical redundancy check (VRC) method

In this error detection technique, a redundant bit called parity bit is appended to every data unit so
that total number of 1's in the unit (including parity bit) becomes even. The system now transmits
entire extended unit across the network link. At the receiver, all eight received bits are checked
through even parity checking function. If it counts even 1's data unit passes. If it counts odd
number of 1's, it means error has been introduced in the data somewhere. Hence receiver rejects
the whole data unit. Similar way odd parity VRC can also be implemented. In this method, total
number of 1's in should be odd before transmission.

Longitudinal Redundancy Check (LRC) method

In this error detection method, a block of bits are organized in a table (of rows and columns). For
example, instead of sending block of 32 bits, first it is organized into four rows and eight columns.
Then parity bits for each column is calculated and new row of eight parity bits is formed. These
eight parity bits are appended to original data before transmission.

5. What is piggybacking?
(Piggybacking) –
A preferable solution would be to use each channel to transmit the frame (front and back) both ways,
with both channels having the same capacity. Assume that A and B are users. Then the data frames
from A to B are interconnected with the acknowledgement from A to B. and can be identified as a
data frame or acknowledgement by checking the sort field in the header of the received frame.
One more improvement can be made. When a data frame arrives, the receiver waits does not send
the control frame (acknowledgement) back immediately. The receiver waits until its network layer
moves to the next data packet.
Definition of Piggybacking :
This technique in which the outgoing acknowledgement is delayed temporarily is
called piggybacking.

Advantages of piggybacking :
1. The major advantage of piggybacking is the better use of available channel bandwidth. This
happens because an acknowledgement frame needs not to be sent separately.
2. Usage cost reduction
3. Improves latency of data transfer
Disadvantages of piggybacking :
1. The disadvantage of piggybacking is the additional complexity.
2. If the data link layer waits long before transmitting the acknowledgement (block the ACK for
some time), the frame will rebroadcast.

6.Differentiate between character stuffing and bit stuffing with examples


Byte or character stuffing – A byte (usually escape character(ESC)), which has a predefined bit
pattern is added to the data section of the frame when there is a character with the same pattern as
the flag. Whenever the receiver encounters the ESC character, it removes from the data section and
treats the next character as data, not a flag. But the problem arises when the text contains one or
more escape characters followed by a flag. To solve this problem, the escape characters that are part
of the text are marked by another escape character i.e., if the escape character is part of the text, an
extra one is added to show that the second one is part of the text. Example:

Note – Point-to-Point Protocol (PPP) is a byte-oriented protocol. Bit stuffing – Mostly flag is a
special 8-bit pattern “01111110” used to define the beginning and the end of the frame. Problem
with the flag is the same as that was in case of byte stuffing. So, in this protocol what we do is, if we
encounter 0 and five consecutive 1 bits, an extra 0 is added after these bits. This extra stuffed bit is
removed from the data by the receiver. The extra bit is added after one 0 followed by five 1 bits
regardless of the value of the next bit. Also, as the sender side always knows which sequence is data
and which is flag it will only add this extra bit in the data sequence, not in the flag sequence.

Example:
Note – High-Level Data Link Control(HDLC) is a bit-oriented protocol.

7.Explain the design issues of data link layer?

Design Issues of the Data Link Layer

Service Agreement to the Network Layer


The main aim of this service is to give services to the network layer. The concept of this layer is to transfer
the data from the network layer on the source machine to the layer on the destination machine.
Communication between the two data layers is done via Data Link Control Protocol.
Here are the important services given by the Data Link layer to the Network layer −
Unacknowledged connectionless services
Acknowledged connectionless service
Acknowledged-oriented service
Framing
Service given to the network layer data link uses the services given to the physical layer. The source
machine sends the data in the form of frames to the destination machine. Starting point and the endpoint of
the frame should point out so that the destination machine can easily identify the frame.
The data link layer breaks the bitstream and calculates the checksum for each layer. At the destination layer,
the checksum is enumerated. Therefore, breaking the bitstream by placing spaces and time gaps is known
as framing.
It is quite difficult and dangerous to count on timing and mark the starting and endpoints of each frame.
Simple techniques used for framing are −

Character Count
Starting and ending character with character filling
Starting and ending flags with little fillings.

Flow Control
Flow control is done to stop the data flow at the receiver's end. The transmitter will transfer the frames very
quickly to the receiver. However, the receiver will not accept them as quickly as the sender sends because
the sender runs on a lightly loaded machine while the receiver runs on a heavily loaded machine.
It doesn't matter if the transmission is error-free at some point. The receiver will not be able to control the
frames as they will arrive.
For stopping the transmission, a mechanism is there which requests the transmitter to block the incorrect
messages.

Error Control
It is done so that there is no copying of the frames for the safe delivery of the frames at the destination. In
addition, Positive and negative acceptance is sent about the incoming frames.
Therefore, if the sender gets positive acceptance, that means the frame appears safely, while negative
appearance means that something is wrong with the frame and the frame will be retransferred.
The timer is put at the receiver's and sender's end. Besides, the sequence number is given to the outgoing
transmission. So that receiver will easily identify that it is a retransmitted frame. It is one of the main parts
of the data link layer responsibilities.

8.Explain about CRC and Generate the CRC code for message
1101010101.Given
generator polynomial g(x)=x 4 +x 2 +1?

9.Explain any 2 elementary data link layer protocols

Elementary Data Link protocols are classified into three categories, as given below −
Protocol 1 − Unrestricted simplex protocol
Protocol 2 − Simplex stop and wait protocol
Protocol 3 − Simplex protocol for noisy channels.
Let us discuss each protocol one by one.

Unrestricted Simplex Protocol


Data transmitting is carried out in one direction only. The transmission (Tx) and receiving (Rx) are always
ready and the processing time can be ignored. In this protocol, infinite buffer space is available, and no
errors are occurring that is no damage frames and no lost frames.
The Unrestricted Simplex Protocol is diagrammatically represented as follows −

Simplex Stop and Wait protocol


In this protocol we assume that data is transmitted in one direction only. No error occurs; the receiver can
only process the received information at finite rate. These assumptions imply that the transmitter cannot
send frames at rate faster than the receiver can process them.
The main problem here is how to prevent the sender from flooding the receiver. The general solution for
this problem is to have the receiver send some sort of feedback to sender, the process is as follows −
Step1 − The receiver send the acknowledgement frame back to the sender telling the sender that the last
received frame has been processed and passed to the host.
Step 2 − Permission to send the next frame is granted.
Step 3 − The sender after sending the sent frame has to wait for an acknowledge frame from the receiver
before sending another frame.
This protocol is called Simplex Stop and wait protocol, the sender sends one frame and waits for feedback
from the receiver. When the ACK arrives, the sender sends the next frame.
The Simplex Stop and Wait Protocol is diagrammatically represented as follows −
Simplex Protocol for Noisy Channel
Data transfer is only in one direction, consider separate sender and receiver, finite processing capacity and
speed at the receiver, since it is a noisy channel, errors in data frames or acknowledgement frames are
expected. Every frame has a unique sequence number.
After a frame has been transmitted, the timer is started for a finite time. Before the timer expires, if the
acknowledgement is not received , the frame gets retransmitted, when the acknowledgement gets corrupted
or sent data frames gets damaged, how long the sender should wait to transmit the next frame is infinite.
The Simplex Protocol for Noisy Channel is diagrammatically represented as follows −

10.Differentiate between selective repeat and Go-back n protocols?


S.NOGo-Back-N Protocol Selective Repeat Protocol
1. In Go-Back-N Protocol, if the sent frame are In selective Repeat protocol, only those frames are
find suspected then all the frames are re- re-transmitted which are found suspected.
transmitted from the lost packet to the last
packet transmitted.
2. Sender window size of Go-Back-N Protocol is Sender window size of selective Repeat protocol
N. is also N.
3. Receiver window size of Go-Back-N Protocol Receiver window size of selective Repeat protocol
is 1. is N.
4. Go-Back-N Protocol is less complex. Selective Repeat protocol is more complex.
5. In Go-Back-N Protocol, neither sender nor at In selective Repeat protocol, receiver side needs
receiver need sorting. sorting to sort the frames.
6. In Go-Back-N Protocol, type of In selective Repeat protocol, type of
Acknowledgement is cumulative. Acknowledgement is individual.
7. In Go-Back-N Protocol, Out-of-Order packets In selective Repeat protocol, Out-of-Order packets
are NOT Accepted (discarded) and the entire are Accepted.
window is re-transmitted.
8. In Go-Back-N Protocol, if Receives a corrupt In selective Repeat protocol, if Receives a corrupt
packet, then also, the entire window is re- packet, it immediately sends a negative
transmitted. acknowledgement and hence only the selective
packet is retransmitted.
9. Efficiency of Go-Back-N Protocol is Efficiency of selective Repeat protocol is also
N/(1+2*a)
N/(1+2*a)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy