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

PRACTICAL

COMPUTER

NETWORKING

SUBMITTED TO: SUBMITTED BY:


Mr Mir Lateef Aamir Maqbool Yatoo
COURSE: SEMESTER:
BCA III Sem
PREFACE

This project is meant to describe about the basic

information in ‘Computer networking’. One may

notice a change in writing style.

Most of the topics are written in an easy style

engaging Constantly and included with more

informatics comments.

I assure you to go through this thoroughly to know

a bit more and facts about ‘CN’.


ACKNOWLEDGEMENT

Firstly, we would like to thanks the university for including

such activities in the syllabus of IT. Although it is difficult to

work with the life project because it being the first time for us

to do such work but it was a meaningful to include such

activities as it provided as the practical knowledge which we

studied in the book.

Secondly, we would like to thank our Assistant Professor Mr.

Mir Lateef for providing us with choices of topics and

allowing us do work with the topic of our choice. It was very

helpful for us as ma’am provided flexibility to work on any

topic of our interest which were feasible for us to work on.


INDEX

NAME OF THE PRACTICAL REMARKS


S.NO.

1 To study various networks


topologies

2 To study about different


network devices

To study about the various


3 layer of model

To study about IPv4, ipV6, Net


4 ID, hosted

5 To study about classful and


classless addressing

To study various window


6 protocols
STOP N WAIT, GO BACK N
ARQ, Sliding window

To study about network


7 applications.
(DNS, FTP, SMTP, POP, IMAP,
MIME)
PRACTICAL 1
Aim:- To study various network topologies

NETWORK TOPOLOGY
A network topology describes the configuration of a network and the physical
and logical arrangement of the nodes that form the network.

There are many types of network topology

STAR TOPOLOGY
In a star topology, a number of workstations (or nodes) are directly linked to a
control node. Any communication between stations must pass through the
central node. The central node controls all activities of the nodes. There is bi-
directional communication between various nodes.

BUS TOPOLOGY
In bus topology, all nodes are connected to a single communication line called
bus and there is no central node. All the data that travels over the network is
transmitted through a common transmission medium having two endpoints
known as the backbone of the network and that data can be received by all
workstations.
RING TOPOLOGY
In ring topology each station is attached nearby station on a point to point
basis so that the entire system is in the form of a ring. In this topology data is
transmitted along the ring in either clockwise or anti-clockwise direction but
only in one direction.

MESH TOPOLOGY
A mesh topology can be full mesh topology or a partially connected mesh
topology.

In a full mesh topology, each network node is connected to every other node
in the network. The number of connections in this network can be calculated
using the following formula n(n-1)/2 where n is the number of computers.

In a partially mesh topology, only some of the network nodes are connected to
more than one node. It is an inexpensive way to implement redundancy in a
network. In the event that one of connections in the network fails, the rest of
the network continues to operate normally.
TREE TOPOLOGY
It is also known as a hierarchical topology and has a central root node that is
connected to one or more nodes of a lower hierarchy.

In a hierarchy, each node in the network has a specific fixed numbers of nodes
connected to those at a lower level.
PRACTICAL 2
Aim:- To study about different network devices

NETWORK DEVICES
REPEATER
A repeater is an electronic device that receives a signal from the computers
and other devices on the LAN and retransmits it at a higher power in order for
the signal to maintain integrity while travelling along a longer media run, so
that the signal can cover longer distances without attenuation.

Repeaters do not have any capacity of directing network traffic or deciding


what particular route that certain data should take, they are simple devices
that sit on the network and boost the data signal that they receive.

Functions:-
Repeaters operate in the OSI model physical layer and are transparent to all
the protocols operating in the layers above the physical layer.

HUB
A hub is used in a wired network to connect Ethernet cables from a number of
devices together. Hubs are such simple devices – they require no
configuration, and have no manuals – that their function is now induced in
other devices such as routers and modems.

When a hub receives a packet (chunk) of the data (a frame) at one of its ports
from a PC on the network, it transmits (repeats) the packet to all of its ports
and thus, to all of the other PC’s on the network.
Functions:-
A hub works at the physical layer (layer 1) of the OSI model. A repeater hub
also participates in collision detection, forwarding a jam signal to all ports if it
detects a collision.

ROUTER
A router is a networking device that forwards data packets between computer
networks. Routers perform the traffic directing functions on the internet. A
data packet is typically forwarded from one router to another router through
the networks that constitute an internetwork until it reaches its destination
node.

A router is connected to two or more data lines from different networks. When
a data packet comes in on one of the lines, the router reads the network
address information in the packet to determine the ultimate destination. Then,
using information in its routing table or routing policy, it directs the packet to
the next network on its journey.
Functions:-
Router use in data link layer or layer 2 of the seven layer OSI model. The data
link layer is concerned with local delivery of frames between devices on the
same LAN. Data link frames, as these protocol data units are called, do not
cross the boundaries of a local network.

SWITCH
A network switch is a computer networking device that connects devices
together on a computer network by using packet switching to receive, process,
and forward data to the destination device.

Functions:-
A network switch is a multiport network bridge that uses hardware addresses
to process and forward data at the data link layer (layer 2) of the OSI model.
Some switches can also process data at the network layer (layer 3) by
additionally incorporating routing functionally.

BRIDGE
A network bridge is a computer networking device that creates a single
aggregate network from multiple communication networks or network
segments. This function is called network bridging. Bridging is distinct from
routing.
Functions:-
Bridges operate at the data link layer of the OSI reference model. A bridge will
filter, forward or flood an incoming frame based on the MAC address of that
frame.
PRACTICAL 3
Aim:- To study about the various layer of OSI model

OPEN SYSTEM INTERCONNECTION (OSI)


The Open System Interconnection (OSI) model defines a networking
framework to implement protocols in seven layers. There is really nothing to
the OSI model. In fact, it's not even tangible. The OSI model doesn't perform
any functions in the networking process. It is a conceptual framework so we
can better understand complex interactions that are happening.

Who Developed the OSI Model?

The International Standards Organization (ISO) developed the Open Systems


Interconnection (OSI) model. It divides network communication into seven
layers. Layers 1-4 are considered the lower layers, and mostly concern
themselves with moving data around. Layers 5-7, the upper layers, contain
application-level data. Networks operate on one basic principle: "pass it on."
Each layer takes care of a very specific job, and then passes the data onto the
next layer.

The 7 Layers of the OSI


In the OSI model, control is passed from one layer to the next, starting at the
application layer (Layer 7) in one station, and proceeding to the bottom layer,
over the channel to the next station and back up the hierarchy. The OSI model
takes the task of inter-networking and divides that up into what is referred to
as a vertical stack that consists of the following 7 layers.

Most of the functionality in the OSI model exists in all communications


systems, although two or three OSI layers may be incorporated into one. OSI is
also referred to as the OSI Reference Model or just the OSI Model.

APPLICATION (Layer 7)
OSI Model, Layer 7, supports application and end-user processes.
Communication partners are identified, quality of service is identified, user
authentication and privacy are considered, and any constraints on data syntax
are identified. Everything at this layer is application-specific. This layer provides
application services for file transfers, e-mail, and other network software
services. Telnet and FTP are applications that exist entirely in the application
level. Tiered application architectures are part of this layer.
Layer 7 Application examples include WWW browsers, NFS, SNMP, Telnet,
HTTP, FTP

PRESENTATION (Layer 6)
This layer provides independence from differences in data representation (e.g.,
encryption) by translating from application to network format, and vice versa.
The presentation layer works to transform data into the form that the
application layer can accept. This layer formats and encrypts data to be sent
across a network, providing freedom from compatibility problems. It is
sometimes called the syntax layer.

Layer 6 Presentation examples include encryption, ASCII, EBCDIC, TIFF, GIF,


PICT, JPEG, MPEG, MIDI.

SESSION (Layer 5)
This layer establishes, manages and terminates connections between
applications. The session layer sets up, coordinates, and terminates
conversations, exchanges, and dialogues between the applications at each end.
It deals with session and connection coordination.

Layer 5 Session examples include NFS, NetBios names, RPC, SQL.

TRANSPORT (Layer 4)
OSI Model, Layer 4, provides transparent transfer of data between end
systems, or hosts, and is responsible for end-to-end error recovery and flow
control. It ensures complete data transfer.

Layer 4 Transport examples include SPX, TCP, UDP.

NETWORK (Layer 3)
Layer 3 provides switching and routing technologies, creating logical paths,
known as virtual circuits, for transmitting data from node to node. Routing and
forwarding are functions of this layer, as well as addressing, internetworking,
error handling, congestion control and packet sequencing.

Layer 3 Network examples include AppleTalk DDP, IP, IPX.

DATA LINK (Layer 2)


At OSI Model, Layer 2, data packets are encoded and decoded into bits. It
furnishes transmission protocol knowledge and management and handles
errors in the physical layer, flow control and frame synchronization. The data
link layer is divided into two sub layers: The Media Access Control (MAC) layer
and the Logical Link Control (LLC) layer. The MAC sub layer controls how a
computer on the network gains access to the data and permission to transmit
it. The LLC layer controls frame synchronization, flow control and error
checking.

Layer 2 Data Link examples include PPP, FDDI, ATM, IEEE 802.5/ 802.2, IEEE
802.3/802.2, HDLC, Frame Relay.

PHYSICAL (Layer 1)
OSI Model, Layer 1 conveys the bit stream - electrical impulse, light or radio
signal — through the network at the electrical and mechanical level. It provides
the hardware means of sending and receiving data on a carrier, including
defining cables, cards and physical aspects. Fast Ethernet, RS232, and ATM are
protocols with physical layer components.

Layer 1 Physical examples include Ethernet, FDDI, B8ZS, V.35, V.24, RJ45.
PRACTICAL 4
Aim:- To study about IPv4, IPv6, Net ID, Host ID

IPv4
Internet Protocol version 4 (IPv4) is the fourth version of the Internet Protocol
(IP). It is one of the core protocols of standards-based internetworking
methods in the Internet, and was the first version deployed for production in
the ARPANET in 1983. It still routes most Internet traffic today,[1] despite the
ongoing deployment of a successor protocol, IPv6. IPv4 is described in IETF
publication RFC 791 (September 1981), replacing an earlier definition (RFC 760,
January 1980).

IPv4 is a connectionless protocol for use on packet-switched networks. It


operates on a best effort delivery model, in that it does not guarantee delivery,
nor does it assure proper sequencing or avoidance of duplicate delivery. These
aspects, including data integrity, are addressed by an upper layer transport
protocol, such as the Transmission Control Protocol (TCP).

IPv6
Internet Protocol version 6 (IPv6) is the most recent version of the Internet
Protocol (IP), the communications protocol that provides an identification and
location system for computers on networks and routes traffic across the
Internet. IPv6 was developed by the Internet Engineering Task Force (IETF) to
deal with the long-anticipated problem of IPv4 address exhaustion. IPv6 is
intended to replace IPv4.[1] IPv6 became a Draft Standard in December 1998,
and became an Internet Standard on 14 July 2017.[2]

Every device on the Internet is assigned a unique IP address for identification


and location definition. With the rapid growth of the Internet after
commercialization in the 1990s, it became evident that far more addresses
would be needed to connect devices than the IPv4 address space had
available. By 1998, the Internet Engineering Task Force (IETF) had formalized
the successor protocol. IPv6 uses a 128-bit address, theoretically allowing
2128, or approximately 3.4×1038 addresses. The actual number is slightly
smaller, as multiple ranges are reserved for special use or completely excluded
from use. The total number of possible IPv6 addresses is more than 7.9×1028
times as many as IPv4, which uses 32-bit addresses and provides
approximately 4.3 billion addresses. The two protocols are not designed to be
interoperable, complicating the transition to IPv6. However, several IPv6
transition mechanisms have been devised to permit communication between
IPv4 and IPv6 hosts.

IPv6 provides other technical benefits in addition to a larger addressing space.


In particular, it permits hierarchical address allocation methods that facilitate
route aggregation across the Internet, and thus limit the expansion of routing
tables. The use of multicast addressing is expanded and simplified, and
provides additional optimization for the delivery of services. Device mobility,
security, and configuration aspects have been considered in the design of the
protocol.

IPv6 addresses are represented as eight groups of four hexadecimal digits with
the groups being separated by colons, for example
2001:0db8:0000:0042:0000:8a2e:0370:7334, but methods to abbreviate this
full notation exist.

NET ID & HOST ID


In classful adressing, an IP address in class A,B, or C is divided into netid and
hostid.

In class A one byte defines the netid and three bytes defines the hostid.

In class B, two bytes define the netid and two bytes define the hostid.

In class C, three bytes define the netid and one byte define the hostid.
PRACTICAL 5
Aim:- To study about classful and classless addressing
CLASSFUL ADDRESSING
In classful addressing, the address space is divided into five classes A,B,C,D and
E. Each class occupied some part of the address space. We can find the class of
address when given the address in binary or dotted – decimal notation. If the
address is given in binary, the first few bits can immediately tell us the class of
the address. If it is in decimal – dotted, the first byte defines the class.

In classful addressing a large part of the available were wasted.

 BINARY NOTATION

First byte Second byte Third byte Fourth byte


Class A 0
Class B 10
Class C 110
Class D 1110
Class E 1111

 DECIMAL NOTATION

First byte Second byte Third byte Fourth byte


Class A 0-127
Class B 1128-19111
Class C 1192-22311
Class D 1224-23911
Class E 1240-25511

Adress Depletion

The no. of devices on the internet is much less than the 2^32 address space.
We have run out of class A and B addresses and a class C block is too small for
most midsize organizations. One solution that has alleviated the problem is the
idea of classless addressing.
CLASSLESS ADDRESSING
To overcome address depletion and give more organizations access to the
internet, classless addressing was designed and implemented. In this scheme,
there are no classes but the addresses are still granted in blocks.

In this addressing, when an entity, small or large, need to be connected to the


internet, it is granted a block ( range of addresses). The size of block ( the no.
of addresses) varies based on the nature and size of the entity.

Restriction

To simplify the handling of addresses, the internet authorities impose 3


restrictions on classless address blocks:-

1. The addresses in a block must be contiguous, one after another.


2. The no. of addresses in a block must be a power of 2(1,2,4,8,…..).
3. The first address must be evenly divisible by the no. of addresses.
PRACTICAL 6
Aim:- To study various window protocols
STOP AND WAIT PROTOCOL
• In this method of flow control, the sender sends a single frame to receiver &
waits for an acknowledgment.

• The next frame is sent by sender only when acknowledgment of previous


frame is received. This process of sending a frame & waiting for an
acknowledgment continues as long as the sender has data to send.

• To end up the transmission sender transmits end of transmission (EOT)


frame.

• The main advantage of stop & wait protocols is its accuracy. Next frame is
transmitted only when the first frame is acknowledged. So there is no chance
of frame being lost.

• The main disadvantage of this method is that it is inefficient. It makes the


transmission process slow. In this method single frame travels from source to
destination and single acknowledgment travels from destination to source. As
a result each frame sent and received uses the entire time needed to traverse
the link. Moreover, if two devices are distance apart, a lot of time is wasted
waiting for ACKs that leads to increase in total transmission time.

GO-BACK-N ARQ PROTOCOL


Go-Back-N Automatic Repeat Request (ARQ) Protocol

To improve the efficiency of transmission (filling the pipe), multiple frames


must be in transition while waiting for acknowledgment. In Go-Back-N
Automatic Repeat Request, we can send several frames before receiving
acknowledgments; we keep a copy of these frames until the acknowledgments
arrive.

SLIDING WINDOW
In this protocol (and the next), the sliding window is an abstract concept that
defines the range of sequence numbers that is the concern of the sender and
receiver. In other words, the sender and receiver need to deal with only part of
the possible sequence numbers. The range which is the concern of the sender
is called the send sliding window; the range that is the concern of the receiver
is called the receiver sliding window.

PRACTIAL 7
Aim:- To study about network applications( DNS, FTP, SMTP, POP, IMAP,
MIME).

SMTP
SMTP is part of the application layer of the TCP/IP protocol. Using a process
called "store and forward," SMTP moves your email on and across networks. It
works closely with something called the Mail Transfer Agent (MTA) to send
your communication to the right computer and email inbox.

SMTP spells out and directs how your email moves from your computer's MTA
to an MTA on another computer, and even several computers. Using that
"store and forward" feature mentioned before, the message can move in steps
from your computer to its destination.

SMTP provides a set of codes that simplify the communication of email


messages between email servers (the network computer that handles email
coming to you and going out). It's a kind of shorthand that allows a server to
break up different parts of a message into categories the other server can
understand. When you send a message out, it's turned into strings of text that
are separated by the code words (or numbers) that identify the purpose of
each section.

SMTP provides those codes, and email server software is designed to


understand what they mean. As each message travels towards its destination,
it sometimes passes through a number of computers as well as their individual
MTAs. As it does, it's briefly stored before it moves on to the next computer in
the path. Think of it as a letter going through different hands as it winds its way
to the right mailbox.

DNS
The Domain Name System is a 'hierarchically distributed database', which is a
fancy way of saying that its layers are arranged in a definite order and that its
data is distributed across a wide range of machines (just like the roots of a tree
branch out from the main root).
The DNS protocol works when your computer sends out a DNS query to a
name server to resolve a domain. For example, you type "www.firewall.cx" in
your web browser, this triggers a DNS request, which your computer sends to a
DNS server in order to get the website's IP Address ! There is a detailed
example on the pages to follow so I won't get into too much detail for the
moment.

The DNS protocol normally uses the UDP protocol as a means of transport
because of its small overhead in comparison to TCP; the less overhead a
protocol has, the faster it is.

In the case where there are constant errors and the computer trying to request
a DNS resolution can't get an error free answer, or any answer at all, it will
switch to TCP to ensure the data arrives without errors.

This process, though, depends on the operating system you're using. Some
operating systems might not allow DNS to use the TCP protocol, thus limiting it
to UDP only. It is rare that you will get so many errors that you can't resolve
any hostname or domain name to an IP Address.

The DNS protocol utilises Port 53 for its service. This means that a DNS server
listens on Port 53 and expects any client wishing to use the service to use the
same port. There are, however, cases where you might need to use a different
port, something possible depending on the operating system and DNS server
you are running.

POP
Post Office Protocol (POP) is a type of computer networking and Internet
standard protocol that extracts and retrieves email from a remote mail server
for access by the host machine.

POP is an application layer protocol in the OSI model that provides end users
the ability to fetch and receive email.

Post Office Protocol is the primary protocol behind email communication. POP
works through a supporting email software client that integrates POP for
connecting to the remote email server and downloading email messages to the
recipient’s computer machine.

POP uses the TCP/IP protocol stack for network connection and works with
Simple Mail Transfer Protocol (SMTP) for end-to-end email communication,
where POP pulls messages and SMTP pushes them to the server. As of 2012,
Post Office Protocol is in its third version known as POP 3 and is commonly
used in most email client/server communication architecture.
IMAP
IMAP (Internet Message Access Protocol) – Is a standard protocol for accessing
e-mail from your local server. IMAP is a client/server protocol in which e-mail
is received and held for you by your Internet server. As this requires only a
small data transfer this works well even over a slow connection such as a
modem. Only if you request to read a specific email message will it be
downloaded from the server. You can also create and manipulate folders or
mailboxes on the server, delete messages etc.

IMAP (Internet Message Access Protocol) is a standard email protocol that


stores email messages on a mail server, but allows the end user to view and
manipulate the messages as though they were stored locally on the end user's
computing device(s). This allows users to organize messages into folders, have
multiple client applications know which messages have been read, flag
messages for urgency or follow-up and save draft messages on the server.

IMAP can be contrasted with another client/server email protocol, Post Office
Protocol 3 (POP3). With POP3, mail is saved for the end user in a single mailbox
on the server and moved to the end user's device when the mail client opens.
While POP3 can be thought of as a "store-and-forward" service, IMAP can be
thought of as a remote file server.

Most implementations of IMAP support multiple logins; this allows the end
user to simultaneously connect to the email server with different devices. For
example, the end user could connect to the mail server with his Outlook
iPhone app and his Outlook desktop client at the same time. The details for
how to handle multiple connections are not specified by the protocol but are
instead left to the developers of the mail client.

Even though IMAP has an authentication mechanism, the authentication


process can easily be circumvented by anyone who knows how to steal a
password by using a protocol analyzer because the client’s username and
password are transmitted as clear text. In an Exchange Server environment,
administrators can work around this security flaw by using Secure Sockets
Layer (SSL) encryption for IMAP.

MIME
MIME (Multi-Purpose Internet Mail Extensions) is an extension of the original
Internet e-mail protocol that lets people use the protocol to exchange different
kinds of data files on the Internet: audio, video, images, application programs,
and other kinds, as well as the ASCII text handled in the original protocol, the
Simple Mail Transport Protocol (SMTP). In 1991, Nathan Borenstein of Bellcore
proposed to the IETF that SMTP be extended so that Internet (but mainly Web)
clients and servers could recognize and handle other kinds of data than ASCII
text. As a result, new file types were added to "mail" as a supported Internet
Protocol file type.

Servers insert the MIME header at the beginning of any Web transmission.
Clients use this header to select an appropriate "player" application for the
type of data the header indicates. Some of these players are built into the Web
client or browser (for example, all browsers come with GIF and JPEG image
players as well as the ability to handle HTML files); other players may need to
be downloaded.

New MIME data types are registered with the Internet Assigned Numbers
Authority (IANA).

MIME is specified in detail in Internet Request for Comments 1521 and 1522,
which amend the original mail protocol specification, RFC 821 (the Simple Mail
Transport Protocol) and the ASCII messaging header, RFC 822.

You might also like