0% found this document useful (0 votes)
13 views70 pages

Unit 3 - Network Models & Addressing Mechanism

Uploaded by

shivrajlawand4
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views70 pages

Unit 3 - Network Models & Addressing Mechanism

Uploaded by

shivrajlawand4
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 70

SYMSc Sem 4

Computer Networks

Unit 3
Network Models &
Addressing
Mechanism
ISO OSI Reference Model
• The OSI model stands for Open Systems Interconnection model.
• The OSI model is also known as the ISO-OSI reference model as it was
developed by ISO (International Organization for Standardization) in 1984.
• It is a conceptual reference model that describes the entire flow of
information from one computer to the other computer.
• The OSI model is a 7-layered model, so it is also known as a 7-layered
architecture model.
• The basic idea behind layered architecture is to divide the design into
smaller pieces.
• There are numerous users around the world, and to ensure national and
worldwide communication, the ISO developed a conceptual model named
the OSI model.
Representation of the OSI model

• The layered
architecture
reduces the
complexity by
dividing the task in
a manageable way.
• The layered
architecture
provides
abstraction from
other layers.
• Due to the
abstraction, any
layer can be
changed
independently.
1. Physical Layer
• The physical layer is the lowest layer of the OSI model.
• The main work of the physical layer of the OSI model is to activate,
maintain, and deactivate the physical connection.
• The physical layer is also responsible for the transmission and reception of
the unstructured raw data over the network.
• The data in the physical layer consists of a stream of bits. The bits of data
must be encoded into the form of signals for transmission.
• Now, for the transmission, the physical layer sets the voltages, light
speed(in the case of fiber optics cable), and data rates (numbers of bits to be
transmitted per second).
Functions provided by the physical layer:
• The physical layer encodes the signals at the sender's end and decodes the
signals at the receiver's end. It also defines the type of encoding scheme to be
used (how 0's and 1's are to be changed into signals).
• It deals with the synchronization of the sender and the receiver so that the
receiver and the sender are at the same bit level. (Their clocks must be
synchronized).
• The physical layer deals with the line configuration i.e. how the devices are
connected through a dedicated link.
• It deals with the type of topology to be used for example ring, mesh, bus,
star, hybrid, etc. Network topology is the physical and logical arrangement of
nodes and connections in a computer network.
• The physical layer also deals with the direction and type of transmission
between two or more devices. The mode of transmission can be simplex,
half-duplex, and full duplex.

The various devices used in the physical layer are Network adapters, Hubs,
Cables, Repeaters, Modem, etc.
2. Data Link Layer
• The data link is the second layer of the OSI model, which is used to transmit
the error-free frames from one node to the other.
• If the two computer nodes are on the same networks, then the data link layer
provides a connection between the two nodes.
• The main work of the data link layer is to convert the data into the form of
frames.
Functions provided by the Data Link layer
• Framing :
Framing is the technique in which the data is divided into streams of bits
(called frames) received from the network layer. Along with the conversion
of data into frames, the data link layer adds a header and trailer to the frames.
The header (present at the starting of the frame) contains the hardware's
physical address of source and destination. The trailer (present at the end of
the frame) contains the error detection and correction bits.
• The data link layer also maintains the flow control of data during
transmission. Suppose that the rate of data transmission and data absorption
varies then there is data loss, so the data link layer maintains the flow control.
• The data link layer adds the error detection and correction bits at the end of
the frames in the form of trailers. These bits are used to detect the errors and
then retransmit the damaged or lost data to prevent any kind of duplication.
• It also maintains access control. In situations where two or more devices are
connected to the same communication medium then the data link layer
protocols determine the device that can transmit the data.
Note: The physical address is also known as the MAC (media access control)
address. The MAC address is a unique address of each computer present on
the NIC card.

The various devices used in this layer are :


• Bridges,
• Switches,
• NIC cards (Network Interface Cards), etc.
3. Network Layer
• The network layer is the third layer of the OSI model which provides
communication between hosts of different networks.
• The network layer divides the data received from the transport layer in the
form of packets.
• The network layer provides two ways of communication namely -
connection-oriented and connectionless.
Functions provided by the Network layer:
• Logical Addressing :
The network layer adds the logical address i.e. IP address (Internet Protocol
address) if the packet crosses the network boundary. It helps in the proper
identification of devices on the network. Hence, the network layer adds the
source and destination address to the header of the frame.
• Routing :
Routing simply means determining the best (optimal) path out of multiple
paths from the source to the destination. So the network layer must choose
the best routing path for the data to travel.
• If many devices are connected to the same router then there is a chance of
packet drop because a router may not be able to handle all the requests. So,
the network layer controls the congestion on the network as well.
• The various protocols used in this layer are :
• IPv4 (Internet Protocol version 4),
• IPv6 (Internet Protocol version 6),
• ICMP (Internet Control Message Protocol),
• IPSEC ( IP Security),
• ARP (Address Resolution Protocol),
• MPLS (Multiprotocol Label Switching), etc.
• The various devices used in this layer are :Routers, Brouters, etc.
4. Transport Layer
• The transport layer is the fourth layer of the OSI model which is responsible
for the process to process delivery of data.
• The main aim of the transport layer is to maintain the order so that the data
must be received in the same sequence as it was sent by the sender.
• The transport layer provides two types of services namely - connection-
oriented and connectionless.
• Connectionless Transport Layer : Each segment is considered as an
independent packet and delivered to the transport layer at the destination
machine.
• Connection Oriented Transport Layer : Before delivering packets,
connection is made with transport layer at the destination machine.
Functions provided by the Transport layer
• The transport layer maintains the order of data.
• It receives the data from the upper layer and converts it into smaller parts
known as segments.
• A message is divided into segments; each segment contains sequence
number, which enables this layer in reassembling the message. Message is
reassembled correctly upon arrival at the destination and replaces packets
which were lost in transmission.
• One of the major tasks of the transport layer is to add the port addressing
(addition of a port number to the header of the data). The port number is
added so that the data can be sent at the respective process only.
• Error Control is performed end to end in this layer to ensure that the
complete message arrives at the receiving transport layer without any error.
Error Correction is done through retransmission.

The various protocols used in this layer are : TCP (Transmission Control
Protocol), UDP (User Datagram Protocol), etc.
The various devices used in this layer are Load Balancers/Firewalls, etc.
5. Session Layer
The session layer is the fifth layer of the OSI model whose main aim is to
establish, manage, and terminate the connection between applications.
Functions provided by the Session layer
• The session layer is responsible to create a dialog box which allows two
systems to enter into a dialog and transmit the data in either half-duplex or
full-duplex mode.
• The session layer is also responsible for adding synchronization bits or
checkpoints into the stream of data. These checkpoints help to detect any
kind of error that may have occurred during the data transmission. So, if an
error has occurred in between the transmission then the re-transmission will
take place from the last checkpoint only.
• Example: If a system is sending a file of 800 pages, adding checkpoints
after every 50 pages is recommended. This ensures that 50 page unit is
successfully received and acknowledged. This is beneficial at the time of
crash as if a crash happens at page number 110; there is no need to
retransmit 1 to100 pages.

The various protocols used in this layer are PAP (Password Authentication
Protocol), PPTP (Point-to-Point Tunnelling Protocol), RPC (Remote
Procedure Call Protocol), RTCP (Real-time Transport Control Protocol), etc.
The device used in this layer is Gateway.
6. Presentation Layer
• The presentation layer is the sixth layer of the OSI model which mainly
concentrates on the syntax and semantics of the information exchanged
between the systems.
• The main aim of the presentation layer is to convert the data from one
presentation format to the other format as different applications may use
different applications.
Functions provided by the Presentation layer
• Since different computer systems use different encoding systems so the
presentation layer must translate the data into a computer-dependent format.
• The presentation layer deals with the encryption and decryption of the data so
that the data can be transmitted securely.
• The presentation layer also deals with the compression and expansion of the
information.

• The various protocols used in this layer are


• SSL,
• HTTP/ HTML (agent),
• FTP (server),
• AppleTalk Filing Protocol,
• Telnet etc.
7. Application Layer
• The application layer is the seventh and the last layer of the OSI model,
which mainly concentrates on providing services to the users.
• The application layer contains numerous protocols that are used by users
for different purposes.
• Application layers allow users to access and share files, access and send
emails, access webpages (via the world wide web), etc.
Functions provided by the Application layer:
• Ensures that the receiving device is identified, reachable and ready to
accept data;
• When appropriate, enables authentication between devices for an extra
layer of network security;
• Makes sure necessary communication interfaces exist, such as whether
there is an Ethernet or Wi-Fi interface in the sender's computer;
• Ensures agreement at both ends on error recovery procedures, data
integrity and privacy;
• Determines protocol and data syntax rules at the application level

The various protocols used in this layer are:


• DNS (Domain Name System), SMTP (Simple Mail Transfer Protocol),
• FTP (File Transfer Protocol), POP (Post Office Protocol),
• HTTP (HyperText Transfer Protocol), etc.
The various devices used in this layer are:
• PC's (Personal Computer),
• Phones,
• Servers,
• Firewalls, etc.
Advantages of OSI Model
• Using the OSI model, various other layered models are developed (for
example - TCP/IP).
• Using the OSI model, we can see the big picture of the communication of
data over the network.
• Each layer of the OSI model handles a specific job; hence can be handled and
tested separately.
• The OSI model depicts how hardware and software work together.
• The OSI model can be used to compare the basic functional relationship on a
different network.
• The OSI model provides abstraction so we can change any layer without
thinking about other layers; hence, it can be easily used to incorporate new
technologies.

Disadvantages of OSI Model


• There are some duplicate services provided by the various layers, for
example - flow control, error control, etc.
• The OSI model is quite complex and costly to implement and use.
• The OSI model is theoretical, so it is not perfectly adequate for practical data
transmission and communication.
Basic Overview of the Various Layers
What is the TCP/IP Model?
• TCP/IP stands for Transmission Control Protocol/ Internet Protocol.
• TCP/IP Model helps you to determine how a specific computer should be
connected to the internet and how data should be transmitted between
them.
• It helps you to create a virtual network when multiple computer networks
are connected together.
• The purpose of TCP/IP model is to allow communication over large
distances.
• TCP/IP Stack is specifically designed as a model to offer highly reliable and
end-to-end byte stream over an unreliable network.
TCP/IP Characteristics
• Support for a flexible TCP/IP architecture.
• Adding more system to a network is easy.
• The TCP/IP model was developed prior to the OSI model.
• In TCP IP protocols suite, the network remains intact until the source, and
destination machines were functioning properly.
• TCP is a connection-oriented protocol.
• TCP offers reliability and ensures that data which arrives out of sequence
should put back into order.
• TCP allows you to implement flow control, so sender never overpowers a
receiver with data.
• TCP/IP is a layered server architecture system in which each layer is
defined according to a specific function to perform.
• All these four TCP IP layers work collaboratively to transmit the data
from one layer to another.
a. Application Layer
b. Transport Layer
c. Internet Layer
d. Network Interface
The Network Interface Layer
• Network Interface Layer is the lowest layer of the TCP/IP model.
• This layer is also called a network access layer. It helps you to defines
details of how data should be sent using the network.
• It also includes how bits should optically be signaled by hardware devices
which directly interfaces with a network medium, like coaxial, optical,
coaxial, fiber, or twisted-pair cables.
• This layer defines how the data should be sent physically through the
network. This layer is responsible for the transmission of the data
between two devices on the same network.
• The protocols used by this layer are ethernet, token ring,
FDDI, frame relay.
• Fiber Distributed Data Interface (FDDI) is a set of ANSI and
ISO standards for transmission of data in local area network
(LAN) over fiber optic cables. It is applicable in large LANs
that can extend up to 200 kilometers in diameter.
• Frame relay is a protocol that defines how frames are routed
through a fast-packet network based on the address field in
the frame.
Token Ring: A token ring is a data link for a local area network (LAN) in which
all devices are connected in a ring or star topology and pass one or more
tokens from host to host. A token is a frame of data transmitted between
network points. Only a host that holds a token can send data, and tokens are
released when receipt of the data is confirmed.

MAU: Media Access Unit


Internet Layer
• An internet layer is a second layer of TCP/IP layers of the TCP/IP model. It
is also known as a network layer. The main work of this layer is to send
the packets from any network, and any computer still they reach the
destination irrespective of the route they take.
• The Internet layer offers the functional and procedural method for
transferring variable length data sequences from one node to another
with the help of various networks.
• Message delivery at the network layer does not give any guaranteed to
be reliable network layer protocol.
Layer-management protocols that belong to the network layer are:
1. Routing protocols
2. Multicast group management
3. Network-layer address assignment.

• Protocols used in this layer are IP, ARP, ICMP.


Internet Protocol
It is the most significant part of the entire TCP/IP suite.
Responsibilities of this protocol are –
• IP Addressing: This protocol implements logical host addresses known as IP
addresses. The IP addresses are used by the internet and higher layers to identify
the device and to provide internetwork routing.
• Host-to-host communication: It determines the path through which the data is to
be transmitted.
• Data Encapsulation and Formatting: An IP protocol accepts the data from the
transport layer protocol. An IP protocol ensures that the data is sent and received
securely, it encapsulates the data into message known as IP datagram.
• Fragmentation and Reassembly: The limit imposed on the size of the IP datagram by
data link layer protocol is known as Maximum Transmission unit (MTU). If the size of
IP datagram is greater than the MTU unit, then the IP protocol splits the datagram
into smaller units so that they can travel over the local network. Fragmentation can
be done by the sender or intermediate router. At the receiver side, all the fragments
are reassembled to form an original message.
• Routing: When IP datagram is sent over the same local network such as LAN, MAN,
WAN, it is known as direct delivery. When source and destination are on the distant
network, then the IP datagram is sent indirectly. This can be accomplished by routing
the IP datagram through various devices such as routers.
Address Resolution Protocol
• ARP is a network layer protocol which is used to find the physical address
from the IP address.
• The two terms are mainly associated with the ARP Protocol:
• ARP request: When a sender wants to know the physical address of the
device, it broadcasts the ARP request to the network.
• ARP reply: Every device attached to the network will accept the ARP
request and process the request, but only recipient recognize the IP
address and sends back its physical address in the form of ARP reply. The
recipient adds the physical address both to its cache memory and to the
datagram header.
Internet Control Message Protocol

• It is a mechanism used by the hosts or routers to send


notifications regarding datagram problems back to the
sender.
• A datagram travels from router-to-router until it reaches its
destination. If a router is unable to route the data because of
some unusual conditions such as disabled links, a device is
on fire or network congestion, then the ICMP protocol is used
to inform the sender that the datagram is undeliverable.
• An ICMP protocol mainly uses two terms:
• ICMP Test: ICMP Test is used to test whether the
destination is reachable or not.
• ICMP Reply: ICMP Reply is used to check whether the
destination device is responding or not.
• The core responsibility of the ICMP protocol is to report the
problems, not correct them. The responsibility of the
correction lies with the sender.
• ICMP can send the messages only to the source, but not to
the intermediate routers because the IP datagram carries the
addresses of the source and destination but not of the router
Transport Layer
• Transport layer builds on the network layer in order to provide data
transport from a process on a source system machine to a process on a
destination system. It is hosted using single or multiple networks, and also
maintains the quality of service functions.
• It determines how much data should be sent where and at what rate. This
layer builds on the message which are received from the application layer. It
helps ensure that data units are delivered error-free and in sequence.
• Transport layer helps you to control the reliability of a link through flow
control, error control, and segmentation or de-segmentation.
• The transport layer also offers an acknowledgment of the successful data
transmission and sends the next data in case no errors occurred. TCP is the
best-known example of the transport layer.
Important functions of Transport Layers:
• It divides the message received from the Application layer into segments
and numbers them to make a sequence.
• Transport layer makes sure that the message is delivered to the correct
process on the destination machine.
• It also makes sure that the entire message arrives without any error else it
should be retransmitted.
The two protocols used in the transport layer are User
Datagram protocol and Transmission control protocol.

User Datagram Protocol (UDP)


• It provides connectionless service and end-to-end delivery of
transmission.
• It is an unreliable protocol as it discovers the errors but not
specify the error.
• User Datagram Protocol discovers the error, and ICMP
protocol reports the error to the sender that user datagram
has been damaged.
• UDP consists of the following fields:
• Source port address: The source port address is the address
of the application program that has created the message.
• Destination port address: The destination port address is the
address of the application program that receives the
message.
• Total length: It defines the total number of bytes of the user
datagram in bytes.
• Checksum: The checksum is a 16-bit field used in error
detection.
Transmission Control Protocol (TCP)
• It provides a full transport layer services to applications.
• It creates a virtual circuit between the sender and receiver, and it
is active for the duration of the transmission.
• TCP is a reliable protocol as it detects the error and retransmits
the damaged frames. Therefore, it ensures all the segments must
be received and acknowledged before the transmission is
considered to be completed and a virtual circuit is discarded.
• At the sending end, TCP divides the whole message into smaller
units known as segment, and each segment contains a sequence
number which is required for reordering the frames to form an
original message.
• At the receiving end, TCP collects all the segments and reorders
them based on sequence numbers.
https://www.gatevidyalay.com/transmission-control-protocol-tcp-header/
Application Layer
• Application layer interacts with an application program, which is the highest
level of OSI model.
• The application layer is the OSI layer, which is closest to the end-user.
• It means the OSI application layer allows users to interact with other
software application.
• Application layer interacts with software applications to implement a
communicating component.
• The interpretation of data by the application program is always outside the
scope of the OSI model.
• Example of the application layer is an application such as file transfer, email,
remote login, etc.

The function of the Application Layers are:


• Application-layer helps you to identify communication partners, determining
resource availability, and synchronizing communication.
• It allows users to log on to a remote host
• This layer provides various e-mail services
• This application offers distributed database sources and access for global
information about various objects and services.
Following are the main protocols used in the application layer:
• HTTP: HTTP stands for Hypertext transfer protocol. This protocol
allows us to access the data over the world wide web. It transfers
the data in the form of plain text, audio, video. It is known as a
Hypertext transfer protocol as it has the efficiency to use in a
hypertext environment where there are rapid jumps from one
document to another.
• SNMP: SNMP stands for Simple Network Management Protocol. It
is a framework used for managing the devices on the internet by
using the TCP/IP protocol suite.
• SMTP: SMTP stands for Simple mail transfer protocol. The TCP/IP
protocol that supports the e-mail is known as a Simple mail
transfer protocol. This protocol is used to send the data to
another e-mail address.
• DNS: DNS stands for Domain Name System. An IP address is
used to identify the connection of a host to the internet uniquely.
But, people prefer to use the names instead of addresses.
Therefore, the system that maps the name to the address is
known as Domain Name System.
• TELNET: It is an abbreviation for Terminal Network. It establishes
the connection between the local computer and remote computer
in such a way that the local terminal appears to be a terminal at
Advantages of the TCP/IP model
• It helps you to establish/set up a connection between different types
of computers.
• It operates independently of the operating system.
• It supports many routing-protocols.
• It enables the internetworking between the organizations.
• TCP/IP model has a highly scalable client-server architecture.
• It can be operated independently.

Disadvantages of the TCP/IP model


• TCP/IP is a complicated model to set up and manage.
• The overhead of TCP/IP is higher.
• In this, model the transport layer does not guarantee delivery of
packets.
• Replacing protocol in TCP/IP is not easy.
• It has no clear separation from its services, interfaces, and protocols.
OSI Model TCP/IP model
It is developed by ISO (International It is developed by ARPANET (Advanced
Standard Organization) Research Project Agency Network).
TCP/IP doesn’t have any clear distinguishing
OSI model provides a clear distinction
points between services, interfaces, and
between interfaces, services, and protocols.
protocols.
OSI refers to Open Systems Interconnection. TCP refers to Transmission Control Protocol.
OSI uses the network layer to define routing
TCP/IP uses only the Internet layer.
standards and protocols.
OSI model use two separate layers physical
TCP/IP uses only one layer (link) i.e. network
and data link to define the functionality of
interface layer or host to network layer.
the bottom layers.
OSI layers have seven layers. TCP/IP has four layers.
OSI model, the transport layer is only A layer of the TCP/IP model is both
connection-oriented. connection-oriented and connectionless.
Session and presentation layers are a part There is no session and presentation layer
of the OSI model. in TCP model.
It is defined before the advent of the
It is defined after the advent of the Internet.
internet.
The minimum size of the OSI header is 5
Minimum header size is 20 bytes.
bytes.
ADDRESSING
• Four levels of addresses are used in an internet employing the TCP/IP
protocols: physical address, logical address, port address, and application-
specific address.
• Each address is related to a one layer in the TCP/IP architecture, as shown
in the following Figure.
Physical Addresses
• The physical address, also known as the link address, is the address of a
node as defined by its LAN or WAN.
• It is included in the frame used by the data link layer.
• It is the lowest-level address.
• The size and format of these addresses vary depending on the network.
• For example, Ethernet uses a 6-byte (48-bit) physical address that is
imprinted on the network interface card (NIC).
• Most local area networks use a 48-bit (6-byte) physical address written as
12 hexadecimal digits; every byte (2 hexadecimal digits) is separated by a
colon, as shown below.
• Physical addresses can be either unicast, multicast, or broadcast.
• A source address is always a unicast address.
• The least significant bit of the first byte defines the type of address.
Define the type of the following destination addresses:
1. 4A:30:10:21:10:1A
2. 47:20:1B:2E:08:EE
3. FF:FF:FF:FF:FF:FF
Logical Addresses
• Logical addresses are necessary for universal communications
that are independent of underlying physical networks.
• Physical addresses are not adequate in an internetwork
environment where different networks can have different
address formats.
• A universal addressing system is needed in which each host can
be identified uniquely, regardless of the underlying physical
network.
• The logical addresses are designed for this purpose.
• A logical address in the Internet is currently a 32- bit address
that can uniquely define a host connected to the Internet.
• No two publicly addressed and visible hosts on the Internet can
have the same IP address.
• The logical addresses can be either unicast, multicast, or
broadcast.
Port Addresses
• The IP address and the physical address are necessary for a quantity of
data to travel from a source to the destination host.
• However, arrival at the destination host is not the final objective of data
communications on the Internet.
• Computers are devices that can run multiple processes at the same time.
• The end objective of Internet communication is a process communicating
with another process.
• For example, computer A can communicate with computer C by using
TELNET. At the same time, computer A communicates with computer B by
using the File Transfer Protocol (FTP).
• For these processes to receive data simultaneously, we need a method to
label the different processes. In other words, they need addresses.
• In the TCP/IP architecture, the label assigned to a process is called a port
address.
• A port address in TCP/IP is 16 bits in length. A port address is a 16-bit
address represented by one decimal number.
• In the TCP/IP protocol suite, the port numbers are integers between 0 and
65,535.
• The client program defines itself with a port number, called the ephemeral
port number (chosen randomly). The word ephemeral means short lived
Application-Specific Addresses
• Some applications have user-friendly addresses that are designed for
that specific application.
• Examples include the e-mail address (for example, [email protected])
and the Universal Resource Locator (URL) (for example,
www.mhhe.com).
• The first defines the recipient of an e-mail; the second is used to find a
document on the World Wide Web.
• These addresses, however, get changed to the corresponding port and
logical addresses by the sending computer.
IP Addressing
• It is also called as network addressing.
• A Network Address is a logical or physical address that
uniquely identifies a host or a machine in a
telecommunication network.
• Internet protocol (IP) address, media access control (MAC)
address and telephone numbers are some basic examples of
network addresses. It can be of numeric type or symbolic or
both in some cases.
• It is the responsibility of the network layer to assign unique
addresses to different nodes in a network.
• The most widely used network address is an IP address.
• It uniquely identifies a node in an IP network.
• An IP address is a 32-bit long numeric address represented in
a form of dot-decimal notation where each byte is written in a
decimal form separated by a period.
• For example 196.32.216.9 is an IP address where 196
represents first 8 bits, 32 next 8 bits and so on.
An IP address is further divided into sub classes :
• Class A : An IP address is assigned to those networks that include large
number of hosts.
• Class B : An IP address is assigned to networks range from small sized to large
sized.
• Class C : An IP address is assigned to networks that are small sized.
• Class D : IP address are reserved for multicast address and does not possess
subnetting.
• Class E : An IP address is used for the future use and for the research and
development purposes and does not possess any subnetting.

An IP address is divided into two parts:


1.Network ID : represents the number of networks.
2.Host ID : represents the number of hosts.
Classful Addressing
Class A
• In Class A, an IP address is assigned to those networks that
contain a large number of hosts.
• The network ID is 8 bits long.
• The host ID is 24 bits long.

• In Class A, the first bit in higher order bits of the first octet is
always set to 0 and the remaining 7 bits determine the
network ID. The 24 bits determine the host ID in any
network.
• The total number of networks in Class A = 27 = 128 network
address
• The total number of hosts in Class A = 224 - 2 = 16,777,214
host address.
• 2 IP addresses are decreased because they cannot be
assigned to hosts, i.e. the first IP of a network is network
number and the last IP is reserved for Broadcast IP.
Class B
• In Class B, an IP address is assigned to those networks that range from small-
sized to large-sized networks.

• The Network ID is 16 bits long.


• The Host ID is 16 bits long.
• In Class B, the higher order bits of the first octet is always set to 10, and the
remaining14 bits determine the network ID. The other 16 bits determine the
Host ID.

• The total number of networks in Class B = 214 = 16384 network address

• The total number of hosts in Class B = 216 – 2 = 65534 host address


Class C
• In Class C, an IP address is assigned to only small-sized networks.

• The Network ID is 24 bits long.


• The host ID is 8 bits long.
• In Class C, the higher order bits of the first octet is always set to 110, and
the remaining 21 bits determine the network ID. The 8 bits of the host ID
determine the host in a network.

• The total number of networks = 221 = 2097152 network address

• The total number of hosts = 28 – 2 = 254 host address


Class D
In Class D, an IP address is reserved for multicast addresses. It does not possess
subnetting. The higher order bits of the first octet is always set to 1110, and the
remaining bits determines the host ID in any network.

Class E
In Class E, an IP address is used for the future use or for the research and
development purposes. It does not possess any subnetting. The higher order
bits of the first octet is always set to 1111, and the remaining bits determines
the host ID in any network.
Rules for assigning Host ID:
• The Host ID must be unique within any network.
• The Host ID in which all the bits are set to 0 cannot be assigned as it is used
to represent the network ID of the IP address.
• The Host ID in which all the bits are set to 1 cannot be assigned as it is
reserved for the multicast address.

Rules for assigning Network ID:


• The Network ID in which all the bits are set to 0 cannot be
assigned as it is used to specify a particular host on the local
network.
• The Network ID in which all the bits are set to 1 cannot be
assigned as it is reserved for the multicast address.
Subnet Mask
• Subnetting is the practice of dividing a network into two or more smaller
networks.
• A subnet mask is a 32 bits address used to distinguish between a network
address and a host address in IP address.
• A subnet mask identifies which part of an IP address is the network address
and the host address.
• The subnet mask is used by the router to cover up the network address. It
shows which bits are used to identify the subnet.
• Every network has its own unique address, Like here, class B network has
network address 172.20.0.0, which has all zeroes in the host portion of the
address.
• Example IP address: 11000001. Here 1st and 2nd bits are 1, and the 3rd bit is
0; hence, it is class C.
IP address 192.168.10.0/24.
The “/24” here indicates that the first 24 bits are part
of the network address (192.168.10) leaving only the
remaining 8 bits able to be changed for specific host
Network Address Translation (NAT)
Network Address Translation is the network process that is the task of
translating and assigning the private network model, to the global IP address to
access internet services.
The same step is repeated, to convert a public IP address into a private IP
address, to provide the received data and information from the internet. The
NAT process helps with the conservation of IP addresses and provides better
security.
Addresses of NAT
NAT addresses can be differentiated as inside and outside addresses, where
inside address refers to the private addresses to be translated. The outside
addresses refer to as the ones used to access the internet.

Inside local address: This IP address represents the host of the private network.
This address cannot be used by a private network to access the internet directly.

Inside global address: This IP address represents the whole private network, by
using a globally recognized public IP address. It is used to access the internet
services for the private network
Outside global address: This IP address represents the outside network address
for the host before the NAT translation process.

Outside local address: This IP address represents the actual address representing
the host on the internet, after the NAT translation process.
Types of NAT
Static NAT: Static NAT maps an internal IP address to an external one
on a one-to-one basis.
Dynamic NAT - For this NAT translation process, the private network
address is converted to a public IP address by choosing it from a pool
of public IP addresses available to the network model.
Port Address Translation - This translation process is configured to convert all the
private IP addresses available to a single public IP address, but with a different
port number assigned to each of the public addresses.
Advantages of NAT

• NAT helps in preserving the IPv4 address space. When any


organization uses NAT with their private IP address, they
don’t need to buy a new IP address for all the computers
they have in their organization. They can use the same IP
address for multiple computers out there. This will help to
reduce the cost of the organization.
• NAT enhances the reliability and flexibility of
interconnections to the global network by deploying multiple
source pools, load balancing pool, and backup pools.
• NAT provides privacy and security measures to the private address as our
original network is translated to a public IP address.
• In-Network Address Translation all your original source and
destination sources will be hidden by them completely.
Without the user’s permission, so that the hosts inside them
will not be reached by other hosts in the network. This
proves that they have got additional security.
Disadvantages of NAT

• Sometimes hosts inside the network might be unreachable.


Because of this, some applications in the NAT will have
compatibility issues.
• The values inside the headers can be changed in NAT, some
of the tunneling protocols such as IPsec will be very
complicated to use. When you modify the values inside the
headers, then integrity checks will occur, which will interfere
and fail them.
• NAT will examine the data packets of the incoming and
outgoing services. They will convert the data packets into
local and global IP addresses as well. Inside the memory, the
translation details will get stored. This in turn will consume
lots of memory as well as processor.
• When you use NAT, the end-to-end traceability will be
reduced. Also, the IP address will be constantly changed
multiple times. This in turn will make troubleshooting more
difficult.

You might also like