0% found this document useful (0 votes)
70 views44 pages

Unit 1 Exam CN Notes

The document discusses different types of computer networks including personal area networks, local area networks, metropolitan area networks, and wide area networks. It also covers transmission media, protocols, data representation, transmission modes, distributed processing, physical network structures, and point-to-point vs multipoint connections.
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)
70 views44 pages

Unit 1 Exam CN Notes

The document discusses different types of computer networks including personal area networks, local area networks, metropolitan area networks, and wide area networks. It also covers transmission media, protocols, data representation, transmission modes, distributed processing, physical network structures, and point-to-point vs multipoint connections.
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/ 44

NETWORKS

A network consists of two or more computers that are linked in order to share resources (such
as printers and CDs), exchange files, or allow electronic communications. The computers on a
network may be linked through cables, telephone lines, radio waves, satellites, or infrared light
beams.

Network Types

SOHO: Small office, home office

Enterprise Network: Having many devices

For example, we talk a company, Bank

PAN (Personal Area Network)

Personal Area Network is a network arranged within an individual person, typically within a
range of 10 meters.

Personal Area Network is used for connecting the computer devices of personal use is known as
Personal Area Network.

Thomas Zimmerman was the first research scientist to bring the idea of the Personal Area
Network.

Personal Area Network covers an area of 30 feet.

Personal computer devices that are used to develop the personal area network are the laptop,
mobile phones, media player and play stations.

There are two types of PANS

Wireless Personal Area Network: Wireless Personal Area Network is developed by simply using
wireless technologies such as Wi-Fi, Bluetooth. It is a low range network.

Wired Personal Area Network: Wired Personal Area Network is created by using the USB.
LAN (Local Area Network)

Local Area Network is a group of computers connected to each other in a small area such as
building, office.

LAN is used for connecting two or more personal computers through a communication medium
such as twisted pair, coaxial cable, etc.

It is less costly as it is built with inexpensive hardware such as hubs, network adapters, and
ethernet cables.

The data is transferred at an extremely faster rate in Local Area Network.

Local Area Network provides higher security

MAN (Metropolitan Area Network)

A metropolitan area network is a network that covers a larger geographic area by


interconnecting a different LAN to form a larger network.

Government agencies use MAN to connect to the citizens and private industries.

In MAN, various LANs are connected to each other through a telephone exchange line.

The most widely used protocols in MAN are RS-232, Frame Relay, ATM, ISDN, OC-3, ADSL, etc.

It has a higher range than Local Area Network (LAN).

WAN (Wide Area Network)

A Wide Area Network is a network that extends over a large geographical area such as states or
countries.

A Wide Area Network is quite bigger network than the LAN.

A Wide Area Network is not limited to a single location, but it spans over a large geographical
area through a telephone line, fiber optic cable or satellite links.
The internet is one of the biggest WAN in the world.

A Wide Area Network is widely used in the field of Business, government, and education.

Transmission medium

The transmission medium is the physical path by which a message travels from sender to
receiver.

Transmission Media is broadly classified into the following types:

Guided Media

It is also referred to as Wired or Bounded transmission media. Signals being transmitted are
directed and confined in a narrow pathway by using physical links.

Features:

High Speed

Secure

Used for comparatively shorter distances

There are 3 major types of Guided Media:

Twisted Pair Cable –


It consists of 2 separately insulated conductor wires wound about each other. Generally,
several such pairs are bundled together in a protective sheath. They are the most widely used
Transmission Media.

Advantages:

⇢ Least expensive

⇢ Easy to install

⇢ High-speed capacity
Disadvantages:

⇢ Susceptible to external interference

⇢ Lower capacity and performance in comparison to STP

Applications:

Used in telephone connections and LAN networks

(ii) Coaxial Cable –


It has an outer plastic covering containing an insulation layer made of PVC or Teflon and 2
parallel conductors each having a separate insulated protection cover. The coaxial cable
transmits information in two modes: Baseband mode (dedicated cable bandwidth) and
Broadband mode (cable bandwidth is split into separate ranges). Cable TVs and analog
television networks widely use Coaxial cables.

Advantages:

High Bandwidth

Better noise Immunity

Easy to install and expand

Inexpensive

Disadvantages:

Single cable failure can disrupt the entire network

Applications:

Radio frequency signals are sent over coaxial wire. It can be used for cable television signal
distribution, digital audio (S/PDIF), computer network connections (like Ethernet), and feedlines
that connect radio transmitters and receivers to their antennas.

(iii) Optical Fiber Cable –


It uses the concept of refraction of light through a core made up of glass or plastic. The core is
surrounded by a less dense glass or plastic covering called the cladding. It is used for the
transmission of large volumes of data.

The cable can be unidirectional or bidirectional. The WDM (Wavelength Division Multiplexer)
supports two modes, namely unidirectional and bidirectional mode.

Advantages:

Increased capacity and bandwidth

Lightweight

Less signal attenuation

Immunity to electromagnetic interference

Resistance to corrosive materials

Disadvantages:

Difficult to install and maintain

High cost

Fragile

Applications:

Radio frequency signals are sent over coaxial wire. It can be used for cable television signal
distribution, digital audio (S/PDIF), computer network connections (like Ethernet), and feedlines
that connect radio transmitters and receivers to their antennas.

2. Unguided Media:
It is also referred to as Wireless or Unbounded transmission media. No physical medium is
required for the transmission of electromagnetic signals.

Features:
The signal is broadcasted through air

Less Secure

Used for larger distances

There are 3 types of Signals transmitted through unguided media:

Radio waves –
These are easy to generate and can penetrate through buildings. The sending and receiving
antennas need not be aligned. Frequency Range:3KHz – 1GHz. AM and FM radios and cordless
phones use Radio waves for transmission.

(ii) Microwaves –
It is a line-of-sight transmission i.e., the sending and receiving antennas need to be properly
aligned with each other. The distance covered by the signal is directly proportional to the height
of the antenna. Frequency Range:1GHz – 300GHz. These are majorly used for mobile phone
communication and television distribution.

(iii) Infrared –
Infrared waves are used for very short distance communication. They cannot penetrate through
obstacles. This prevents interference between systems. Frequency Range:300GHz – 400THz. It
is used in TV remotes, wireless mouse, keyboard, printer, etc

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

Data representation

Text, numbers, audio, video, image etc.

Data Flow
Communication between two devices can be simplex, half-duplex, or full-duplex

Transmission mode

It means transferring data between two devices. It is also known as a communication mode.
Buses and networks are designed to allow communication to occur between individual devices
that are interconnected. There are three types of transmission modes:

Simplex:

In simplex mode, the communication is unidirectional, as on a one-way street. Only one of the
two devices on a link can transmit; the other can only receive (see Figure a). Keyboards and
traditional monitors are examples of simplex devices. The keyboard can only introduce input;
the monitor can only accept output. The simplex mode can use the entire capacity of the
channel to send data in one direction.

Half-Duplex:

In half-duplex mode, each station can both transmit and receive, but not at the same time.
When one device is sending, the other can only receive, and vice versa The half-duplex mode is
like a one-lane road with traffic allowed in both directions. Walkie-talkies and CB (citizens band)
radios are both half-duplex systems.

Full-Duplex:

In full-duplex both stations can transmit and receive simultaneously. One common example of
full-duplex communication is the telephone network. When two people are communicating by
a telephone line, both can talk and listen at the same time. The full-duplex mode is used when
communication in both directions is required all the time.

Distributed Processing

Most networks use distributed processing, in which a task is divided among multiple
computers. Instead of one single large machine being responsible for all aspects of a process,
separate computers (usually a personal computer or workstation) handle a subset.
Physical Structures:

The term physical topology refers to the way in which a network is laid out physically. One 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, ring and
Point-to-Point

A point-to-point connection provides a dedicated link between two devices. The entire
capacity of the link is reserved for transmission between those two devices. Most point-to-
point connections use an actual length of wire or cable to connect the two ends, but other
options, such as microwave or satellite links, are also possible. When you change television
channels by infrared remote control, you are establishing a point-to-point connection between
the remote control and the television's control system.

Multipoint

A multipoint (also called multidrop) connection is one in which more than two specific devices
share a single link. In a multipoint environment, the capacity of the channel is shared, either
spatially or temporally. Multipoint connection is used in BUS Topology. All the devices are
connected to a single transmission medium, which acts as the Backbone of the connection. This
links all the devices in the network.

Physical Topology

The term physical topology refers to the way in which a network is arranged physically. One 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 Topology:

Every device has point to point link with every other device.

Message can travel in any direction.

If n devices present, then (n – 1) ports must be present on each device.

And total number of physical link is n(n–1)/2.

Full mesh vs. partial mesh topology

In a full mesh network topology, each node is connected directly to all the other nodes. In a
partial mesh topology, only some nodes connect directly to one another. In some cases, a node
must go through another node to reach a third node.

Advantage:

If one node gets down, still message can flow through another path.

Fault detection is easy because of dedicated link.

Disadvantage:

Installation is not easy.

Expensive as a greater number of cables are used.

There is a possibility of redundant path

Ring Topology:

Each device has point to point connection only with two devices that
are either side of a device.

If any device fails, entire network gets down.

Each device in a ring has a repeater.

Message travel in single direction.


If n nodes are present, then n physical links.

Advantages:

Using Token each device gets a fair chance to send a message.

Easy to install, good for long distance.

Disadvantage:

If nodes get moved it affect the performance.

If node get down entire network gets down

Bus Topology:

All the nodes are connected to shared cable.

There will be no central node. One long cable act as a back bone of this network.

For n devices, only 1 link is required.

Advantage:

Installation is easy, used for small networks, less cables required.

Disadvantage:

Can be used with limited nodes, cable length is also limited.

Star Topology:

Each device has point to point link through a central node (hub or switch) that may act as
Controller. There is a central node which act as an exchange medium.

Devices are not directly connected with each other.

For n devices, n links is required.

Advantage:
Easy to manage when faults occur, installation is easy, easy to expand.

Disadvantage:

Require more cable than bus, if central node gets down then all nodes get down.

Tree topology

A tree topology is a sort of structure in which each node is related to the others in a hierarchy.
In a topological hierarchy, there are at least three distinct levels. Sometimes it is also called
hierarchical topology as in this topology, all elements are arranged like the branches of a tree. It
is a lot like the star and bus topologies. Tree topologies are commonly used to arrange data in
databases and workstations in corporate networks. In a tree topology, any two linked nodes
can only have one mutual connection, hence there can only be one link between them.

Hybrid Topology

A network structure whose design contains more than one topology is said to be hybrid
topology. Hybrid topology inherits merits and demerits of all the incorporating topologies.

Internetwork

When two or more computer LANs or WANs or computer network segments are connected
using devices such as a router and configure by logical addressing scheme with a protocol such
as IP, then it is called as computer internetworking. An internetworking uses the internet
protocol.

The reference model used for internetworking is Open System Interconnection (OSI).

Types Of Internetworks:

1. Extranet: An extranet is a communication network based on the internet protocol such


as Transmission Control protocol and internet protocol. It is used for information sharing. The
access to the extranet is restricted to only those users who have login credentials. An extranet
is the lowest level of internetworking. It can be categorized as MAN, WAN or other computer
networks.

2. Intranet: An intranet is a private network based on the internet protocol such


as Transmission Control protocol and internet protocol. An intranet belongs to an organization
which is only accessible by the organization's employee or members. The main aim of the
intranet is to share the information and resources among the organization employees.

Computer Network Architecture

Computer Network Architecture is defined as the physical and logical design of the software,
hardware, protocols, and media of the transmission of data. Simply we can say that how
computers are organized and how tasks are allocated to the computer.

The two types of network architectures are used:

Peer-To-Peer network:

Peer-To-Peer network is a network in which all the


computers are linked together with equal privilege and
responsibilities for processing the data.

Peer-To-Peer network is useful for small environments,


usually up to 10 computers.

Peer-To-Peer network has no dedicated server.

Special permissions are assigned to each computer for sharing the resources, but this can lead
to a problem if the computer with the resource is down.

Client/Server network

Client/Server network is a network model designed for the end users called clients, to access
the resources such as songs, video, etc. from a central computer known as Server.
The central controller is known as a server while all other computers in the network are
called clients.

A server performs all the major operations such as security and network management.

A server is responsible for managing all the resources such as files, directories, printer, etc.

All the clients communicate with each other through a server.

HUB

A hub is a type of device that’s commonly used as a connection point for various devices in a
Local Area Network (LAN). It works by receiving packets that arrive at one of its multiple ports,
copying the packets, and sending them to its other ports so that all LAN segments can see the
data.

When a single port in the hub responds, all other ports will also receive the response. The hub
does not have any capability to distinguish which port it should send a data packet to. As such,
all connected devices will receive the response and must determine whether they should
accept it or not.

In comparison to routers and switches, a hub is the least complex and least expensive device.
While they have often been used as a quick and easy way to connect a small network, they are
becoming increasingly replaced by switches.

Types of hubs

1. Passive Hub

It has quiescent creatures as the name portraits, and it does not impact performance, but it
helps identify the bugs and detect the faulty hardware. They are a simple that receives the
packet on a port and is then broadcast to all the port.

It has a 10base-2 port and RJ-45 connectors, which is connected to each local area network
device. This connecter is applied as a standard one in your network. AUI ports are placed in
advanced passive hubs, which are connected as the transceiver as per the network design.
2. Active Hub

They have some additional features apart from passive hubs. It monitors the data which is sent
out to the connected devices. It has a unique role in this network communication by using Store
technology to check the data before sending it out and prioritizing which packet to send first.

It has the option to fix the damaged packets and hold the direction and distribution of the rest
of the packets. If a week signal is received in port, but it’s still readable, then the active hub
amplifies it to a stronger signal before its retransmitted to other ports.

If any connecting device is not functioning in the network, it can boost the signal, which other
devices view with passive hubs. Hence it helps in the continuation of service in the local area
network.

Intelligent Hub

These give many advantages than passive and active hubs. The management who wants to
expand their business in networking can assign users to share a common pool efficiently and
work more quickly using intelligent hubs. The technique behind them is explored recently, and
now its great demand in the market.

It is proved that it delivers unparallel performance for your local area network. If any problem is
detected with any physical device, it is easily detected, diagnosed, and solved using
management data that the hub can rectify.

SWITCH

A networking switch is a type of hardware that uses packet


switching to receive and forward data to its intended destination
within a network. Essentially, a switch is a more efficient, more
intelligent version of a hub.
Perhaps the biggest difference between a hub and a switch is the way that it delivers data
packets. Rather than blindly passing along data to all devices in a network, a switch records the
addresses of the connected devices. In doing so, it learns which devices are connected to which
ports. Then, when a port receives a data packet, the switch reads its destination address and
sends it directly to the intended device in the network instead of every single port. As a result, a
switch can greatly improve the speed of networks that receive a lot of traffic.

ROUTER

A router is the most intelligent and complex of the three network connection devices listed in
this article. Rather than just forwarding data packets to other devices in a single network,
routers are designed to forward data packets between two or more networks, as well as direct
traffic between them. They are typically located at gateways and can be programmed to
understand, direct, and manipulate network traffic.

Network Reference Model

It is a conceptual layout mainly used to describe how the communication between devices
should occur.

 One of the main advantages of the reference model is that it defines the standards for
building components of the network thereby permitting multiple-vendor development.

 Reference models define which functions should be performed at each layer of the model and
thus they promote standardization. The most important reference models are:

1. OSI reference model.

2. TCP/IP reference model.

OSI Model

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.
OSI consists of seven layers, and each layer performs a particular network function.

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.

OSI model divides the whole task into seven smaller and manageable tasks. Each layer is
assigned a particular task.

Each layer is self-contained, so that task assigned to each layer can be performed
independently.

Characteristics of OSI Model:

The OSI model is divided into two layers: upper layers and lower layers.

The upper layer of the OSI model mainly deals with the application related issues, and they are
implemented only in the software. The application layer is closest to the end user. Both the end
user and the application layer interact with the software applications. An upper layer refers to
the layer just above another layer.

The lower layer of the OSI model deals with the data transport issues. The data link layer and
the physical layer are implemented in hardware and software. The physical layer is the lowest
layer of the OSI model and is closest to the physical medium. The physical layer is mainly
responsible for placing the information on the physical medium.

Functions of the OSI Layers

There are the seven OSI layers. Each layer has different functions.
Physical layer

The main functionality of the physical layer is to transmit the individual bits from one node to
another node.

It is the lowest layer of the OSI model.

It establishes, maintains and deactivates the physical connection.


It specifies the mechanical, electrical and procedural network interface specifications.

Functions of a Physical layer:

Line Configuration: It defines the way how two or more devices can be connected physically.

Data Transmission: It defines the transmission mode whether it is simplex, half-duplex or


full-duplex mode between the two devices on the network.

Topology: It defines the way how network devices are arranged.

Signals: It determines the type of the signal used for transmitting the information.

Data-Link Layer

This layer is responsible for the error-free transfer of data frames.

It defines the format of the data on the network.

It provides a reliable and efficient communication between two or more devices.

It is mainly responsible for the unique identification of each device that resides on a local
network.
It contains two sub-layers:

Logical Link Control Layer It is responsible for transferring the packets to the Network layer of
the receiver that is receiving.

It identifies the address of the network layer protocol from the header.

It also provides flow control.

Media/Multiple Access Control Layer: Media access control layer is a link between the Logical
Link Control layer and the network's physical layer.

It is used for transferring the packets over the network.

Functions of the Data-link layer

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. The header which is added
to the frame contains the hardware destination and source address.

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.

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.

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 occur, then the receiver sends the
acknowledgment for the retransmission of the corrupted frames.

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.
Network Layer

It is a layer 3 that manages device addressing, tracks the location of devices on the network.

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.

The Data link layer is responsible for routing and forwarding the packets.

Routers are the layer 3 devices, they are specified in this layer and used to provide the routing
services within an internetwork.

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

Functions of Network Layer:

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


a logical connection between different devices.

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.

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.

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).

Transport Layer
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.

The main responsibility of the transport layer is to transfer the data completely.

It receives the data from the upper layer and converts them into smaller units known as
segments.

This layer can be termed as an end-to-end layer as it provides a point-to-point connection


between source and destination to deliver the data reliably.

The two protocols used in this layer are:

Transmission Control Protocol It is a standard protocol that allows


the systems to communicate over the internet.

It establishes and maintains a connection between hosts.

When data is sent over the TCP connection, then the TCP protocol
divides the data into smaller units known as segments. Each
segment travels over the internet using multiple routes, and they
arrive in different orders at the destination. The transmission control
protocol reorders the packets in the correct order at the receiving
end.

User Datagram Protocol: User Datagram Protocol is a transport layer protocol.


It is an unreliable transport protocol as in this case receiver does not send any acknowledgment
when the packet is received, the sender does not wait for any acknowledgment. Therefore, this
makes a protocol unreliable.

Functions of Transport Layer:

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. The transport layer adds the header
that contains the address known as a service-point address or port address. The responsibility
of the network layer is to transmit the data from one computer to another computer and the
responsibility of the transport layer is to transmit the message to the correct process.

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.

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. In connection-oriented service, all the packets travel in the single route.

Flow control: The transport layer also responsible for flow control but it is performed end-to-
end rather than across a single link.

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.

Session Layer
The Session layer is used to establish, maintain and synchronizes the interaction between
communicating devices.

Functions of Session layer:

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.

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. This process is known as Synchronization and
recovery.

Presentation Layer

A Presentation layer is mainly concerned with the syntax and semantics of the information
exchanged between the two systems.

It acts as a data translator for a network.

This layer is a part of the operating system that converts the data from one presentation format
to another format.

The Presentation layer is also known as the syntax layer.

Functions of Presentation layer:

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.
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.

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.

Application Layer

Application layer is the last and 7th layer of the OSI model. This layer is the abstraction layer,
which handles the sharing protocols over the computer network with OSI and TCP/IP model. In
internet protocol suite, the application layer contains communication protocols and interface
methods which used for the process-to-process communication over the network. Application
layer contains several protocols namely Telnet, FTP, TFTP, SMTP, SNMP, DNS, and DHCP.

The Application Layer interface directly interacts with application and provides common web
application services.

Functions of Application Layer:


The Application Layer, as discussed above, being topmost layer in OSI model, performs several
kinds of functions which are requirement in any kind of application or communication process.
Following are list of functions which are performed by Application Layer of OSI Model –

Data from User <=> Application layer <=> Data from Presentation Layer
Application Layer provides a facility by which users can forward several emails and it also
provides a storage facility.

This layer allows users to access, retrieve and manage files in a remote computer.

It allows users to log on as a remote host.

This layer provides access to global information about various services.

This layer provides services which include: e-mail, transferring files, distributing results to the
user, directory services, network resources and so on.

It provides protocols that allow software to send and receive information and present
meaningful data to users.

This layer allows users to interact with other software applications.

Application Layer Protocols: The application layer provides several protocols which allow
any software to easily send and receive information and present meaningful data to its users.
The following are some of the protocols which are provided by the application layer.

TELNET: Telnet stands for Telecommunications Network. This protocol is used for managing
files over the Internet. It allows the Telnet clients to access the resources of Telnet server.
Telnet uses port number 23.

DNS: DNS stands for Domain Name System. The DNS service translates the domain name
(selected by user) into the corresponding IP address. For example- If you choose the domain
name as www.abcd.com, then DNS must translate it as 192.36.20.8 (random IP address written
just for understanding purposes). DNS protocol uses the port number 53.

DHCP: DHCP stands for Dynamic Host Configuration Protocol. It provides IP addresses to hosts.
Whenever a host tries to register for an IP address with the DHCP server, DHCP server provides
lots of information to the corresponding host. DHCP uses port numbers 67 and 68.

FTP: FTP stands for File Transfer Protocol. This protocol helps to transfer different files from one
device to another. FTP promotes sharing of files via remote computer devices with reliable,
efficient data transfer. FTP uses port number 20 for data access and port number 21 for data
control.

SMTP: SMTP stands for Simple Mail Transfer Protocol. It is used to transfer electronic mail from
one user to another user. SMTP is used by end users to send emails with ease. SMTP uses port
numbers 25 and 587.

HTTP: HTTP stands for Hyper Text Transfer Protocol. It is the foundation of the World Wide
Web (WWW). HTTP works on the client server model. This protocol is used for transmitting
hypermedia documents like HTML. This protocol was designed particularly for the
communications between the web browsers and web servers, but this protocol can also be
used for several other purposes. HTTP is a stateless protocol (network protocol in which a client
sends requests to server and server responses back as per the given state), which means the
server is not responsible for maintaining the previous client’s requests. HTTP uses port number
80.

NFS: NFS stands for Network File System. This protocol allows remote hosts to mount files over
a network and interact with those file systems as though they are mounted locally. NFS uses the
port number 2049.

SNMP: SNMP stands for Simple Network Management Protocol. This protocol gathers data by
polling the devices from the network to the management station at fixed or random intervals,
requiring them to disclose certain information. SNMP uses port numbers 161 (TCP) and 162
(UDP).

TCP/IP Reference Model

It is a four-layered suite of communication protocols. It was developed by the DoD (Department


of Defense) in the 1960s. It is named after the two main protocols that are used in the model,
namely, TCP and IP. TCP stands for Transmission Control Protocol and IP stands for Internet
Protocol.
The four layers in the TCP/IP protocol suite are −

Host-to- Network Layer −It is the lowest layer that is concerned with the physical transmission
of data. TCP/IP does not specifically define any protocol here but supports all the standard
protocols.

Internet Layer −It defines the protocols for logical transmission of data over the network. The
main protocol in this layer is Internet Protocol (IP) and it is supported by the protocols ICMP,
IGMP, RARP, and ARP.

Transport Layer − It is responsible for error-free end-to-end delivery of data. The protocols
defined here are Transmission Control Protocol (TCP) and User Datagram Protocol (UDP).

Application Layer − This is the topmost layer and defines the interface of host programs with
the transport layer services. This layer includes all high-level protocols like Telnet, DNS, HTTP,
FTP, SMTP, etc.

DATA LINK LAYER

Data Link Layer is generally representing protocol layer in program that is simply used to handle
and control the transmission of data between source and destination machines. It is simply
responsible for exchange of frames among nodes or machines over physical network media.
This layer is often closest and nearest to Physical Layer (Hardware). This layer usually provides
and gives data reliability and provides various tools to establish, maintain, and also release data
link connections between network nodes. It is responsible for receiving and getting data bits
usually from Physical Layer and also then converting these bits into groups, known as data link
frames so that it can be transmitted further. It is also responsible to handle errors that might
arise due to transmission of bits.

Service Of Data Link Layer

Framing and Link access: Data Link Layer protocols encapsulate each network frame within a
Link layer frame before the transmission across the link. A frame consists of a data field in
which network layer datagram is inserted and a number of data fields.
Reliable delivery: Data Link Layer provides a reliable delivery service, i.e., transmits the
network layer datagram without any error. A reliable delivery service is accomplished with
transmissions and acknowledgements.

Error detection: Data Link Layer protocol provides a mechanism to detect one or more errors.
This is achieved by adding error detection bits in the frame and then receiving node can
perform an error check.

Error correction: Error correction is similar to the Error detection, except that receiving node
not only detect the errors but also determine where the errors have occurred in the frame.

Half-Duplex & Full-Duplex: In a Full-Duplex mode, both the nodes can transmit the data at the
same time. In a Half-Duplex mode, only one node can transmit the data at the same time.

Error Detection

When data is transmitted from one device to another device, the system does not guarantee
whether the data received by the device is identical to the data transmitted by another device.
An Error is a situation when the message received at the receiver end is not identical to the
message transmitted.

Errors can be classified into two categories:

o Single-Bit Error

o Multiple-Bit Error

o Burst Error

Single-Bit Error:
The only one bit of a given data unit is changed from 1 to 0 or from 0 to 1.
In the above figure, the message which is sent is corrupted as single-bit, i.e., 0 bit is
changed to 1.
Multiple-Bit Error: Two or more non-consecutive bits in a data unit have changed
from 1 to 0 or 0 to 1.

Burst Error
Two or more consecutive bits in the data unit have changed from 1 to 0 and 0 to 1.

Error Detecting Techniques:

The most popular Error Detecting Techniques are:

o Single parity check

o Two-dimensional parity check

o Checksum

o Cyclic redundancy check


1. Simple Parity check
Blocks of data from the source are subjected to a check bit or parity bit generator form, where
a parity of:

 1 is added to the block if it contains odd number of 1’s, and


 0 is added if it contains even number of 1’s

This scheme makes the total number of 1’s even, that is why it is called even parity checking.

2. Two-dimensional Parity check


Parity check bits are calculated for each row, which is equivalent to a simple parity check bit.
Parity check bits are also calculated for all columns, then both are sent along with the data. At
the receiving end these are compared with the parity bits calculated on the received data.
3. Checksum

 In checksum error detection scheme, the data is divided into k segments each of m bits.
 In the sender’s end the segments are added using 1’s complement arithmetic to get the
sum. The sum is complemented to get the checksum.
 The checksum segment is sent along with the data segments.
 At the receiver’s end, all received segments are added using 1’s complement arithmetic
to get the sum. The sum is complemented.
 If the result is zero, the received data is accepted; otherwise discarded.
4. Cyclic redundancy check (CRC)

 Unlike checksum scheme, which is based on addition, CRC is based on binary division.
 In CRC, a sequence of redundant bits, called cyclic redundancy check bits, are appended
to the end of data unit so that the resulting data unit becomes exactly divisible by a
second, predetermined binary number.
 At the destination, the incoming data unit is divided by the same number. If at this step
there is no remainder, the data unit is assumed to be correct and is therefore accepted.
 A remainder indicates that the data unit has been damaged in transit and therefore
must be rejected.
Example :
Error Correction

Error Correction codes are used to detect and correct the errors when data is transmitted from
the sender to the receiver.

Error Correction can be handled in two ways:

o Backward error correction: Once the error is discovered, the receiver requests the
sender to retransmit the entire data unit.

o Forward error correction: In this case, the receiver uses the error-correcting code which
automatically corrects the errors.

Hamming Code in Computer Network for Error Detection and Error Correction:

The hamming code technique, which is an error-detection and error-correction technique, was
proposed by R.W. Hamming. Whenever a data packet is transmitted over a network, there are
possibilities that the data bits may get lost or damaged during transmission.

Let's understand the Hamming code concept with an example:

Let's say you have received a 7-bit Hamming code which is 1011011.

First, let us talk about the redundant bits.

The redundant bits are some extra binary bits that are not part of the original data, but they
are generated & added to the original data bit. All this is done to ensure that the data bits don't
get damaged and if they do, we can recover them.

Now the question arises, how do we determine the number of redundant bits to be added?

We use the formula, 2r >= m+r+1; where r = redundant bit & m = data bit.
From the formula we can make out that there are 4 data bits and 3 redundancy bits, referring
to the received 7-bit hamming code.

What is Parity Bit?


To proceed further we need to know about parity bit, which is a bit appended to the data bits
which ensures that the total number of 1's are even (even parity) or odd (odd parity).

While checking the parity, if the total number of 1's are odd then write the value of parity
bit P1(or P2 etc.) as 1 (which means the error is there ) and if it is even then the value of parity
bit is 0 (which means no error).

Hamming Code in Computer Network for Error Detection:

As we go through the example, the first step is to identify the bit position of the data & all the
bit positions which are powers of 2 are marked as parity bits (e.g., 1, 2, 4, 8, etc.). The following
image will help in visualizing the received hamming code of 7 bits.

First, we need to detect whether there are any errors in this received hamming code.

Step 1: For checking parity bit P1, use check one and skip one method, which means, starting
from P1 and then skip P2, take D3 then skip P4 then take D5, and then skip D6 and take D7, this
way we will have the following bits,
As we can observe the total number of bits are odd so we will write the value of parity bit as P1
= 1. This means error is there.

Step 2: Check for P2 but while checking for P2, we will use check two and skip two method,
which will give us the following data bits. But remember since we are checking for P2, so we
have to start our count from P2 (P1 should not be considered).

As we can observe that the number of 1's are even, then we will write the value of P2 = 0. This
means there is no error.

Step 3: Check for P4 but while checking for P4, we will use check four and skip four method,
which will give us the following data bits. But remember since we are checking for P4, so we
have started our count from P4(P1 & P2 should not be considered).

As we can observe that the number of 1's are odd, then we will write the value of P4 = 1. This
means the error is there.
So, from the above parity analysis, P1 & P4 are not equal to 0, so we can clearly say that the
received hamming code has errors.

Hamming Code in Computer Network For Error Correction

Since we found that received code has an error, so now we must correct them. To correct the
errors, use the following steps:

Now the error word E will be:

Now we have to determine the decimal value of this error word 101 which is 5 (22 *1 + 21 * 0 +
20 *1 = 5).

We get E = 5, which states that the error is in the fifth data bit. To correct it, just invert the fifth
data bit.

So the correct data will be:

Multiple Access Control

The data connection control layer is sufficient if there is a dedicated link present between the
sender and the receiver, but numerous stations can access the channel at once if there isn’t.
Therefore, it is necessary to use several access protocols to reduce collision and prevent
crosstalk.

When a teacher asks a question in a classroom full of students and all the students start
responding simultaneously (send data at the same time), a lot of chaos is created (data overlap
or data lost), so the teacher’s job is to manage the students and force them to respond one at a
time using multiple access protocols. Protocols are therefore necessary for data sharing over
non-dedicated channels.

Classification of Multiple Access Protocol

Multiple access protocols may also be classified into: Random Access Protocol, Controlled
Access and Channelization.

1. Random Access Protocol

All stations in the random-access protocol have equal superiority, which means that no station
has higher priority than any other station. Depending on the status of the medium, any station
may send data (idle or busy). It has two attributes:

 There is no set timing for data transmission.

 The order of the stations delivering data is not fixed.

The following are divisions of the random-access protocols:

(a) ALOHA

Although ALOHA was created for wireless LAN, it can also be used for shared mediums. This
allows for simultaneous data transmission from numerous stations, which might cause
collisions and jumbled data.

Aloha Rules

1. Any station can transmit data to a channel at any time.

2. It does not require any carrier sensing.


3. Collision and data frames may be lost during the transmission of data through multiple
stations.

4. Acknowledgment of the frames exists in Aloha. Hence, there is no collision detection.

5. It requires retransmission of data after some random amount of time.

Aloha is divided in two types:

Pure Aloha

Whenever data is available for sending over a channel at stations, we use Pure Aloha. In pure
Aloha, when each station transmits data to a channel without checking whether the channel is
idle or not, the chances of collision may occur, and the data frame can be lost. When any station
transmits the data frame to a channel, the pure Aloha waits for the receiver's acknowledgment. If
it does not acknowledge the receiver end within the specified time, the station waits for a random
amount of time, called the back off time (Tb). And the station may assume the frame has been
lost or destroyed. Therefore, it retransmits the frame until all the data are successfully transmitted
to the receiver.

1. The total vulnerable time of pure Aloha is 2 * Tfr.

2. Maximum throughput occurs when G = 1/ 2 that is 18.4%.

3. Successful transmission of data frame is S = G * e ^ - 2 G.

Slotted Aloha

The slotted Aloha is designed to overcome the pure Aloha's efficiency because pure Aloha has a
very high possibility of frame hitting. In slotted Aloha, the shared channel is divided into a fixed
time interval called slots. So that, if a station wants to send a frame to a shared channel, the
frame can only be sent at the beginning of the slot, and only one frame is allowed to be sent to
each slot. And if the stations are unable to send data to the beginning of the slot, the station will
have to wait until the beginning of the slot for the next time. However, the possibility of a
collision remains when trying to send a frame at the beginning of two or more station time slot.
1. Maximum throughput occurs in the slotted Aloha when G = 1 that is 37%.
2. The probability of successfully transmitting the data frame in the slotted Aloha is S = G * e ^
- 2 G.

3. The total vulnerable time required in slotted Aloha is Tfr.

(b) CSMA

Fewer collisions are guaranteed by carrier sensing multiple access (CSMA) since the station
must first determine whether the medium is busy or idle before delivering data. If it isn’t idle, it
waits for the channel to become idle before sending data. Due to propagation latency, there is
still a potential for collision in CSMA.

For instance, station A will sense the medium before sending any data. It will begin sending
data if it discovers that the channel is empty. However, if station B wishes to send data and
senses the medium, it will also find it idle and send data at the same time the first bits of
information are transferred from station A (delayed owing to propagation delay). As a result,
data from stations A and B will collide.

Here are the CSMA access modes:

 Non-persistent: The node senses the channel; if it is free, it sends the data; if not, it
checks the medium once or twice (not continuously) and sends the data when it is.

 1-persistent: The node senses the channel, sends the data if it is idle, or constantly
checks the medium for idleness before sending data unconditionally (with a probability
of 1) when the channel becomes idle.

 P-persistent: The node senses the media and sends data with p probability if it is idle. If
the data is not transferred ((1-p) probability), the system waits a while before checking
the media once more. If the medium is still empty, the system sends the data with a p
probability. This process will repeat until the frame is sent. It is used in packet radio and
Wi-Fi systems.
 O-persistent: Transmission takes place in the sequence determined by the superiority of
nodes. The node waits because of its time slot in order to send data if the medium is not
in use.

(c) CSMA/CD

It is a carrier senses multiple access/ collision detection network protocol to transmit data
frames. The CSMA/CD protocol works with a medium access control layer. Therefore, it first
senses the shared channel before broadcasting the frames, and if the channel is idle, it
transmits a frame to check whether the transmission was successful. If the frame is successfully
received, the station sends another frame. If any collision is detected in the CSMA/CD, the
station sends a jam/ stop signal to the shared channel to terminate data transmission. After

that, it waits for a random time before sending a frame to a channel.

(d) CSMA/CA

It is a carrier sense multiple access/collision avoidance network protocol for carrier


transmission of data frames. It is a protocol that works with a medium access control layer.
When a data frame is sent to a channel, it receives an acknowledgment to check whether the
channel is clear. If the station receives only a single (own) acknowledgment, that means the
data frame has been successfully transmitted to the receiver. But if it gets two signals (its own
and one more in which the collision of frames), a collision of the frame occurs in the shared
channel. Detects the collision of the frame when a sender receives an acknowledgment signal.
Following are the methods used in the CSMA/ CA to avoid the collision:

Interframe space: In this method, the station waits for the channel to become idle, and if it gets
the channel is idle, it does not immediately send the data. Instead of this, it waits for some
time, and this time period is called the Interframe space or IFS. However, the IFS time is often
used to define the priority of the station.
Contention window: In the Contention window, the total time is divided into different slots.
When the station/ sender are ready to transmit the data frame, it chooses a random slot
number of slots as wait time. If the channel is still busy, it does not restart the entire process,
except that it restarts the timer only to send data packets when the channel is inactive.

Acknowledgment: In the acknowledgment method, the sender station sends the data frame to
the shared channel if the acknowledgment is not received ahead of time.

2. Controlled Access Protocol

In this, the station sends the data once it has received approval from all other stations. The
stations under controlled access exchange information to determine which station has the
authority to send. In order to prevent message collisions over a shared medium, it only permits
one node to send at a time. These are the three controlled-access techniques:

 Token Passing

 Polling

 Reservation

3. Channelization

The channelization protocol allows numerous stations to access the same channel at the same
time by sharing the link’s available bandwidth according to time, frequency, and code. The
three types of channelization are: Frequency Division Multiple Access, Time Division Multiple
Access and Code Division Multiple Access.

(a) Frequency Division Multiple Access

In order to assign each station its own band, the available bandwidth is split into equal bands.
In order to prevent crosstalk and noise, guard bands are also included to ensure that no two
bands overlap.

(b) Time Division Multiple Access


The bandwidth is split across several stations in this. Time is separated into slots for stations to
broadcast data in order to prevent collisions. However, there is a synchronization overhead
because each station needs to be aware of its time slot. By including synchronization bits in
each slot, this problem can be fixed. Propagation delay is a problem with TDMA as well, but it
can be remedied by adding guard bands.

(c) Code Division Multiple Access

All signals are broadcast simultaneously on one channel in this process. The concepts of time
and bandwidth are not divided. For instance, even if only two individuals in the room speak the
same language, complete data reception is still achievable when many people are speaking at
once. Similar to this, data from several stations can be sent simultaneously in various code
languages.

You might also like