UNIT_3_sem answers
UNIT_3_sem answers
Leaky Bucket
• The leaky bucket algorithm discovers its use in the context of network
traffic shaping or rate limiting. The algorithm allows controlling the rate at
which a record is injected into a network and managing burstiness in the
data rate.
• In this algorithm, a bucket with a volume of ‘b’ bytes and a hole in the
bottom is considered. If the bucket is null, it means b bytes are available as
storage. A packet with a size smaller than b bytes arrives at the bucket and
will forward it. If the packet's size increases by more than b bytes, it will
either be discarded or queued. It is also considered that the bucket leaks
through the hole in its bottom at a constant rate of r bytes per second.
• The outflow is considered constant when there is any packet in the bucket
and zero when it is empty. This defines that if data flows into the bucket
faster than data flows out through the hole, the bucket overflows.
• The disadvantages compared with the leaky-bucket algorithm are the
inefficient use of available network resources. The leak rate is a fixed
parameter. In the case of the traffic, volume is deficient, the large area of
network resources such as bandwidth is not being used effectively. The
leaky-bucket algorithm does not allow individual flows to burst up to port
speed to effectively MKK consume network resources when there would
not be resource contention in the network.
➢ CLASSFUL ADDRESSING
• An IPv4 address is 32-bit long (4 bytes).
• An IPv4 address is divided into sub-classes:
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
Class B
• In Class B, an IP address is assigned to those networks that range from
small- sized to large-sized networks.
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.
• The Flow label field provides a way for a source and destination to
mark groups of packets that have the same requirements and should
be treated in the same way by the network
• The Payload length field tells how many bytes follow the byte header
• The Next header field tells which transport protocol handler (e.g.,
TCP, UDP) to pass the packet to. MKK
• The Hop limit field is same as the Time to live field in IPv4.
7.Briefly explain about importance of Internet protocol.
• A. The Internet Protocol (IP) is the method or protocol by which
data is sent from one computer to another on the Internet.
• Each computer (known as a host) on the Internet has at least one
IP address that uniquely identifies it from all other computers on
the Internet.
• When you send or receive data (for example, an email note or a
Web page), the message gets divided into little chunks called
packets.
• Each of these packets contains both the sender's Internet address
and the receiver's address.
• Any packet is sent first to a gateway computer that understands a
small part of the Internet.
• he gateway computer reads the destination address and forwards
the packet to an adjacent gateway that in turn reads the
destination address and so forth across the Internet until one
gateway recognizes the packet as belonging to a computer within
its immediate neighbourhood or domain.
• That gateway then forwards the packet directly to the computer
whose address is specified.
• Each subnet has its unique network address known as its Subnet ID.
• The subnet ID is created by borrowing some bits from the Host ID part
of the IP Address.
• The number of bits borrowed depends on the number of subnets
created.
Advantages-
The two main advantages of subnetting a network are-
• It improves the security.
• The maintenance and administration of subnets is easy.
Disadvantages:
Subnetting leads to loss of IP Addresses.
Subnetting leads to complicated communication process.
Types of Subnetting-
Tunnelling
• If they are two geographically separate networks, which want to
communicate with each other, they may deploy a dedicated line between or
they have to pass their data through intermediate networks.
• Tunnelling is a mechanism by which two or more same networks
communicate with each other, by passing intermediate networking
complexities. Tunnelling is configured at both ends.
Tunnelling is used for several reasons, especially in networking and
computing:
1. Security: Tunnelling allows data to be sent securely over public
networks by encapsulating it in a secure protocol (like VPNs).
2. Bypassing Restrictions: It helps bypass firewalls or geographic
restrictions by routing traffic through servers in different locations.
3. Protocol Compatibility: Tunnelling can enable the use of different
protocols over networks that may not support them natively, allowing
for communication between incompatible systems.
4. Privacy: It can enhance user privacy by masking IP addresses and
encrypting data, making it harder for third parties to intercept
information.
5. Data Integrity: Tunnelling can help ensure that data remains intact
during transmission, adding an extra layer of error-checking.
Each of these reasons contributes to the effectiveness and necessity of
tunnelling in modern network communications.
• Each subnet has its unique network address known as its Subnet ID.
• The subnet ID is created by borrowing some bits from the Host ID
part of the IP Address.
The number of bits borrowed depends on the number of subnets created
Example:
Consider-
• We have a big single network having IP Address 200.1.2.0.
• We want to do subnetting and divide this network into 2 subnets.
For creating two subnets and to represent their subnet IDs, we require 1
bit.
So,
• We borrow one bit from the Host ID part.
• After borrowing one bit, Host ID part remains with only 7 bits.
•