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

Two Techniques To Improve Quality of Service (Qos) : Traffic Shaping (E.G., Leaky Bucket, Token Bucket)

The document provides detailed answers to 20 questions related to computer networks, covering topics such as Quality of Service (QoS), congestion, network models, CRC calculation, firewalls, cryptography, and network protocols. It includes explanations of various techniques, algorithms, and protocols, along with comparisons between different technologies like IPv4 and IPv6. Additionally, it discusses the functionalities of network devices, flow control mechanisms, and routing protocols, providing a comprehensive overview of essential networking concepts.

Uploaded by

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

Two Techniques To Improve Quality of Service (Qos) : Traffic Shaping (E.G., Leaky Bucket, Token Bucket)

The document provides detailed answers to 20 questions related to computer networks, covering topics such as Quality of Service (QoS), congestion, network models, CRC calculation, firewalls, cryptography, and network protocols. It includes explanations of various techniques, algorithms, and protocols, along with comparisons between different technologies like IPv4 and IPv6. Additionally, it discusses the functionalities of network devices, flow control mechanisms, and routing protocols, providing a comprehensive overview of essential networking concepts.

Uploaded by

nade.system.out
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Here are the descriptive answers to each of your 20 questions in computer networks:

1. Two Techniques to Improve Quality of Service (QoS)

1. Traffic Shaping (e.g., Leaky Bucket, Token Bucket)


Controls the rate of data transmission by buffering and scheduling packets to prevent congestion and
ensure smooth data flow.
2. Priority Scheduling
Assigns priority levels to different types of network traffic. Real-time traffic like video and VoIP gets
higher priority over file downloads.

2. What is Congestion? Explain Token Bucket Algorithm

• Congestion occurs when the demand for network resources exceeds the available capacity, leading to
packet loss and delay.
• Token Bucket Algorithm:
o A bucket holds tokens generated at a fixed rate.
o To send a packet, a token must be removed from the bucket.
o If there are no tokens, the packet must wait.
o This allows for bursty traffic while controlling average rate.

3. Compare ISO-OSI Model and TCP/IP Model

Feature OSI Model TCP/IP Model


Layers 7 4
Developed by ISO DARPA/DoD
Layering Strict Flexible
Model Type Theoretical Practical
Protocol Support Not tied to protocols Protocol-specific

Let's complete Question 4 in detail:

Q4. CRC Calculation:

Generator Polynomial: G(x)=x5+x3+x+1G(x) = x^5 + x^3 + x + 1


Binary form of generator: 101011
Data to be sent: 11011010100

Step-by-step solution:

Step 1: Append zeros

Append 5 zeros to the data (since the degree of the generator polynomial is 5):
Data: 11011010100
Appended Zeros: 00000
-------------------------------
Dividend: 110110101000000
Step 2: Perform binary division

We'll divide this binary number by the generator (101011) using XOR.

Initial Dividend: 110110101000000


Divisor (Generator): 101011
We'll do XOR only when the first bit of the current segment is 1.

Step-by-step XOR:

1. First 6 bits: 110110


o XOR with 101011
o Result: 011101
o Bring down next bit → new segment: 111010
2. Next segment: 111010
o XOR with 101011
o Result: 010001
o Bring down next bit → new segment: 100010
3. Next segment: 100010
o XOR with 101011
o Result: 001001
o Bring down next bit → new segment: 010011
4. Next segment: 010011
o First bit is 0 → can't divide → shift right, bring down next bit
o New segment: 10011
o XOR with 101011
o Result: 00000
o Bring down remaining bits (all zeros) → result remains zeros

Step 3: Remainder

Final remainder (last 5 bits after division) = 00000

(Note: This means that the original data was already divisible by the generator, i.e., no error check bits were
needed beyond zeros.)

Step 4: Transmitted Bits

To form the final transmitted frame:

Original data: 11011010100


CRC (remainder): 00000
--------------------------------
Transmitted bits: 110110101000000

✅ Final Answer:
The bits actually transmitted are:
110110101000000

5. Proxy Firewall & Digital Signature

• Proxy Firewall:
Acts as an intermediary between users and the internet, filters requests, hides user identity, inspects
traffic.
• Digital Signature:
Uses a private key to encrypt a hash of the message, ensuring authenticity and integrity. The recipient
uses the sender's public key to verify.

6. Cryptography & Types of Keys

• Cryptography: Secures data by converting it into unreadable formats to protect confidentiality,


integrity, and authenticity.
• Types of Keys:
o Symmetric Key: Same key for encryption/decryption.
o Asymmetric Key: Public and private key pair.
o Session Key: Temporary key for a session.
o Hash Key: Used for generating message digests.

7. Cable Modem Architecture & Operation

• Architecture:
Connects user via coaxial cable to the ISP. Contains tuner, demodulator, modulator, and interfaces.
• Operation:
Converts analog signals from cable line to digital for computer and vice versa. Works on DOCSIS
standard.

8. ISO/OSI & IP Address Analysis

• ISO/OSI: A 7-layer reference model for network communication.


• IP Address: [Link]
o Class: C (192-223)
o Net ID: 192.38.15
o Subnet Mask: [Link]

9. UDP Use Cases (Where Reliability is Not Key)

• Examples:
o VoIP (voice calls)
o Online Gaming
o Live Video Streaming
o DNS queries
o TFTP (Trivial File Transfer Protocol)
10. Functionality of Bridges

• Connect two LAN segments.


• Operate at Data Link Layer (Layer 2).
• Filter traffic, reduce collision domains.
• Forward data based on MAC addresses.

11. Ethernet Frame Format


| Preamble | Dest MAC | Source MAC | Type | Data | CRC |
| 7 bytes | 6 bytes | 6 bytes | 2 | 46-1500 bytes | 4 bytes |

• Preamble: Synchronization
• Type: Protocol type (e.g., IPv4)
• CRC: Error detection

12. A. Flow Control Mechanism

• Prevents sender from overwhelming receiver.


Example: Stop-and-Wait, Sliding Window.

B. Pure ALOHA vs Slotted ALOHA

Feature Pure ALOHA Slotted ALOHA


Time Division No Yes (slots)
Efficiency 18.4% 36.8%
Collision Chances High Lower

13. RSA Algorithm with Example

• Steps:
1. Choose two primes: p=3, q=11
2. n = pq = 33
3. φ(n) = (p-1)(q-1) = 20
4. Choose e = 3
5. Find d such that ed ≡ 1 mod 20 → d = 7
6. Public key = (3, 33); Private = (7, 33)
• Encrypt M=7 → C = M^e mod n = 7^3 mod 33 = 343 mod 33 = 13
• Decrypt: M = C^d mod n = 13^7 mod 33 = 7

14. Distance-Vector Routing Protocol

• Routers exchange distance (hop count) info.


• Each node shares its routing table with neighbors.
• Example: RIP (Routing Information Protocol)
15. Flaws in Distance-Vector & Solutions

• Flaws:
o Count-to-infinity problem
o Slow convergence
• Solutions:
o Split Horizon
o Poison Reverse
o Hold-down timers

16. Go-Back-N Flow Control Problems

• Wastes bandwidth due to retransmission of correct frames


• Buffer overflow at sender
• Delays in retransmission

17. Network Topology with Diagram

• Concept: Layout of network devices.

Types:

• Bus
• Star
• Ring
• Mesh
• Tree

(Diagram can be added on request)

18. Polar and Bipolar Encoding

• Polar: Uses positive and negative voltages (e.g., NRZ, RZ)


• Bipolar: Uses three levels: +, 0, − (e.g., AMI)

Example:

• Bit 1 = +V or -V (alternating)
• Bit 0 = 0V

19. Bit Sequence: 10110010 — Waveforms

• i) Unipolar RZ: 1 = High for half time, 0 = 0V


• ii) Polar RZ: 1 = +V, 0 = -V (half time pulse)
• iii) AMI: 1 = alternating +V/−V, 0 = 0V
• iv) Manchester: 1 = High to Low, 0 = Low to High
(Diagrams can be drawn if requested)

20. Throughput of Stop-and-Wait

• Frame Size = 4800 bits


• Bit Rate = 9600 bps
• Distance = 200 km
• Propagation Speed = 200,000 km/s
• Transmission Time = 4800 / 9600 = 0.5 sec
• Propagation Delay = 200 / 200000 = 0.001 sec
• Round Trip Time = 2 × 0.001 = 0.002 sec
• Total Cycle Time = 0.5 + 0.002 = 0.502 sec
• Throughput = 4800 / 0.502 = 9561.75 bps

Sure! Here is the complete and descriptive solution for Q1 (a), (b), and (c):

Q1(a) – Subnetting Design

Given:

• ISP Block: [Link]/16 (i.e., 65,536 IP addresses total)


• Divide for three groups:

✅ Group I: 64 customers, each needs 256 IPs

• 256 IPs = 2⁸ → requires /24 subnet


• 64 subnets × 256 IPs = 16,384 IPs used
• Subnets:
o Start: [Link]/24
o End: [Link]/24

✅ Group II: 128 customers, each needs 128 IPs

• 128 IPs = 2⁷ → requires /25 subnet


• 128 subnets × 128 IPs = 16,384 IPs used
• Subnets:
o Start: [Link]/25
o End: [Link]/25

✅ Group III: 128 customers, each needs 64 IPs

• 64 IPs = 2⁶ → requires /26 subnet


• 128 subnets × 64 IPs = 8,192 IPs used
• Subnets:
o Start: [Link]/26
o End: [Link]/26

Summary Table

Group Customers IPs Needed Each Subnet Slash Total IPs

Group I 64 256 /24 /24 16,384

Group II 128 128 /25 /25 16,384

Group III 128 64 /26 /26 8,192

Total Used 40,960

Remaining IPs = 65,536 - 40,960 = 24,576 IPs

Q1(b) – Comparison Between IPv4 and IPv6


Feature IPv4 IPv6

Address Length 32 bits 128 bits

Address Format Decimal, e.g., [Link] Hexadecimal, e.g., [Link]

Address Space ~4.3 billion 3.4 × 10³⁸ addresses

Header Size 20 bytes 40 bytes

Security Optional via IPSec Mandatory support for IPSec

Configuration Manual or DHCP Auto-configuration via SLAAC

Broadcast Supported Not supported (uses multicast)

Checksum Yes No (simplifies processing)

Q1(c) – Limitations of IPv4

1. Limited Address Space:


o Only ~4.3 billion addresses are possible, which are insufficient due to the growth of the Internet
and IoT.
2. Lack of Built-in Security:
o IPv4 does not mandate encryption or authentication.
3. Address Exhaustion:
o Due to inefficient address allocation and fixed classes (A/B/C), many addresses were wasted.
4. NAT Dependency:
o Widespread use of Network Address Translation (NAT) to overcome shortage, which
complicates protocols.
5. No Mobility Support:
o IPv4 does not natively support mobile IP communication efficiently.
6. Configuration Overhead:
o Often requires manual configuration or external servers like DHCP.

Here are complete answers for the questions from Q2 to Q5(c):

2(a) – Functionalities of Bridges in Computer Networks

Bridge is a Layer 2 device that connects and filters traffic between two or more network segments.

Functions of a Bridge:

1. Traffic Filtering:
Bridges use MAC addresses to filter traffic and forward only necessary frames.
2. Collision Domain Separation:
It divides a network into separate collision domains to reduce collisions.
3. Learning MAC Addresses:
Bridges learn the MAC addresses of connected devices and store them in a MAC address table.
4. Forwarding and Flooding:
If the destination MAC is unknown, the bridge floods the frame to all ports except the source.
5. Protocol Transparency:
Bridges operate independently of higher-layer protocols (e.g., TCP/IP).

2(b) – TCP Header Structure (20–60 Bytes)


Field Size Description

Source Port 16 bit Identifies sender port

Destination Port 16 bit Identifies receiver port

Sequence Number 32 bit Byte number of the first byte of data in this segment

Acknowledgment Number 32 bit Next expected byte from receiver

Data Offset 4 bit Header length

Reserved 3 bit Reserved for future use

Flags (Control Bits) 9 bit URG, ACK, PSH, RST, SYN, FIN etc.

Window Size 16 bit Number of bytes sender can receive

Checksum 16 bit Error-checking for header and data

Urgent Pointer 16 bit Indicates urgent data

Options (optional) Varied Additional features like timestamp, window scaling

Padding Varied Used to ensure 32-bit alignment


2(c) – Comparison Between TCP and UDP
Feature TCP UDP

Type Connection-oriented Connectionless

Reliability Reliable (acknowledgment, retransmission) Unreliable (no acknowledgment)

Order Guarantee Ensures data is received in order No guarantee

Speed Slower due to overhead Faster, lightweight

Header Size 20–60 bytes 8 bytes

Flow Control Supported Not supported

Use Cases HTTP, FTP, Email DNS, VoIP, Streaming

3(a) – ARP (Address Resolution Protocol) Format

ARP maps an IP address to a MAC address.

ARP Packet Format:

Field Size (bits) Description

Hardware Type 16 E.g., 1 for Ethernet

Protocol Type 16 E.g., 0x0800 for IPv4

Hardware Address Len 8 MAC length (6 bytes for Ethernet)

Protocol Address Len 8 IP length (4 bytes for IPv4)

Operation 16 1: request, 2: reply

Sender MAC Address 48 Sender’s MAC address

Sender IP Address 32 Sender’s IP address

Target MAC Address 48 Receiver’s MAC address (0 for request)

Target IP Address 32 Receiver’s IP address

3(b) – Purpose of BGP (Border Gateway Protocol)

• BGP is a path-vector routing protocol used to exchange routing information between autonomous
systems (AS) on the internet.
• It determines best paths based on policies, not just shortest path.
• Ensures loop-free interdomain routing.
• Important for internet backbone connectivity.
3(c) – TCP Three-Way Handshake

Used to establish a reliable connection in TCP.

Steps:

1. SYN – Client sends a SYN packet to the server indicating it wants to establish a connection.
2. SYN-ACK – Server responds with SYN-ACK indicating it is ready.
3. ACK – Client replies with ACK. Connection established.

Illustration:
Client → Server : SYN (seq=x)
Server → Client : SYN-ACK (seq=y, ack=x+1)
Client → Server : ACK (ack=y+1)

4(a) – Why Flow Control Mechanisms Are Needed

Flow control prevents sender from overwhelming receiver with data.

Reasons:

• Ensures receiver can process data at its own speed.


• Avoids buffer overflow.
• Helps manage network congestion.
• Ensures reliable and efficient communication.

4(b) – Go-Back-N Flow Control: Problems & Solutions

Problems:

1. Wastage of Bandwidth: If a single frame is lost, all subsequent frames are discarded.
2. Inefficiency: Retransmits multiple frames even if they were received correctly.

Solutions:

• Use Selective Repeat ARQ instead of Go-Back-N.


• Increase window size and timeout interval for efficiency.
• Use ACK with sequence number to confirm individual frame delivery.

4(c) – Sliding Window Protocol

Sliding window is used for flow control and reliable transmission.

Concept:

• Maintains a window of sequence numbers that can be sent/received.


• Sender’s Window: Slides forward as ACKs are received.
• Receiver’s Window: Slides forward as packets are correctly received.

Types:
• Go-Back-N ARQ
• Selective Repeat ARQ

It ensures continuous data transmission without waiting for an acknowledgment for every single packet.

5(a) – Why OSPF Messages Propagate Faster than RIP


Factor OSPF RIP

Convergence Time Fast (event-driven updates) Slow (updates every 30 seconds)

Metric Used Cost (based on bandwidth) Hop count

Triggered Updates Yes No

Scalability High Low

OSPF reacts to topology changes immediately, while RIP waits for the periodic timer.

5(b) – Twisted Pair vs Optical Fibre (Justification)


Twisted Pair Optical Fibre

Short-distance communication Long-distance communication

Signal degrades quickly over distance Maintains signal strength over km

Low bandwidth Very high bandwidth

More susceptible to EMI Immune to EMI

Cheaper and easy to install Costlier, but supports higher speeds

Conclusion: Optical fiber is ideal for long-distance due to its high capacity and signal integrity.

5(c) – HDLC Frame Format

HDLC (High-Level Data Link Control) is a bit-oriented protocol.

Frame Structure:
| Flag | Address | Control | Data | FCS | Flag |
| 8b | 8b | 8/16b | var | 16/32b | 8b |

• Flag: 01111110 marks start and end.


• Address: Destination address.
• Control: Type (I, S, U frame).
• Data: User information (optional).
• FCS (Frame Check Sequence): Error checking using CRC.

Here are the detailed answers for the questions from 6a to 8b:
6 a. Subnet Design for Given Requirements

Given block: [Link]/16 → Total addresses = 2¹⁶ = 65536

1. First Group: 200 customers × 16 addresses = 200 subnets of 16 addresses each

• Each requires 2⁴ = 16 addresses → /28 subnet mask


• Total addresses used = 200 × 16 = 3200

2. Second Group: 400 customers × 8 addresses = 400 subnets of 8 addresses each

• Each requires 2³ = 8 addresses → /29 subnet mask


• Total addresses used = 400 × 8 = 3200

3. Third Group: 2000 customers × 8 addresses = 2000 subnets of 8 addresses each

• Each requires 2³ = 8 addresses → /29 subnet mask


• Total addresses used = 2000 × 8 = 16000

Total addresses used = 3200 + 3200 + 16000 = 22400


Remaining addresses = 65536 - 22400 = 43136

6 b. MAC Address Use & Protocol to Map MAC to IP

• MAC Address Use:


o It uniquely identifies a device on a local network (Layer 2).
o Ensures correct delivery of data frames within the same LAN.
• Protocol used: Address Resolution Protocol (ARP)
o ARP maps an IP address to a MAC address.
o When a device wants to communicate, it sends a broadcast ARP request.
o The device with the matching IP responds with its MAC.

7 a. Difference Between Integrated Services and Differentiated Services

Feature Integrated Services (IntServ) Differentiated Services (DiffServ)

QoS Guarantee Per-flow QoS guarantee Aggregate traffic-based QoS

Scalability Less scalable (state maintained) Highly scalable

Resource Reservation Uses RSVP to reserve resources No explicit reservation

Complexity High complexity Less complex

7 b. Data Communication System Diagram & Operation

Block Diagram:

Sender → Encoder → Transmission Medium → Decoder → Receiver


Explanation:

• Sender: Originates data.


• Encoder: Converts data to signals.
• Transmission Medium: Carries signals (wired/wireless).
• Decoder: Converts signals back to data.
• Receiver: Receives and processes the data.

7 c. Distinguish Between LAN, MAN, and WAN

Feature LAN MAN WAN

Full Form Local Area Network Metropolitan Area Network Wide Area Network

Coverage Within a building Within a city Country or globally

Speed High Moderate Low to moderate

Ownership Private Public/Private Usually public or leased lines

8 a. Operation of FTP (File Transfer Protocol)

• FTP operates on client-server model using TCP (ports 20 and 21).


• Two channels:
o Control Channel (Port 21): For commands and responses.
o Data Channel (Port 20): For transferring actual files.
• Steps:
1. Client connects to server via control connection.
2. Authenticates with username and password.
3. Commands sent to upload/download files.
4. Data transferred over data connection.

8 b. Hash Function Uniqueness in Cryptography

• Hash Function: Maps input data of any size to fixed-size hash.


• Uniqueness ensures:
o No two different inputs produce same hash → known as collision resistance.
• Importance:
o Used in digital signatures, password verification, integrity checks.
o Secure hash (like SHA-256) ensures tampering detection.

Here are the answers to the remaining questions from 8c to 12a:

8 c. Threats to E-mail

Several threats affect the security and reliability of email communication:


1. Phishing:
Fake emails trick users into revealing sensitive information like passwords or credit card numbers.
2. Spam:
Unsolicited bulk emails that clog inboxes and may carry malicious content.
3. Malware:
Emails with malicious attachments or links that infect the system when opened.
4. Spoofing:
Sending emails with forged sender addresses to impersonate legitimate sources.
5. Man-in-the-Middle Attacks (MITM):
Intercepting and altering email content during transmission if not encrypted.

9 a. Packet Switching vs. Circuit Switching

Feature Packet Switching Circuit Switching

Connection Type No fixed path; packets take any route Dedicated path is established

Efficiency More efficient for data burst traffic Inefficient if the line is idle

Cost Generally cheaper More expensive

Delay Variable delay (due to routing) Constant delay

Examples Internet Traditional telephone networks

9 b. Hamming Code (Error Detection and Correction)

Hamming Code adds parity bits at positions that are powers of 2 (1, 2, 4, etc.) to detect and correct single-bit
errors.

Example: Encode 4-bit data 1011 using Hamming (7,4)

• Data bits: d1=1, d2=0, d3=1, d4=1


• Positions: p1 p2 d1 p4 d2 d3 d4
→__1_011

Calculate parity bits:

• p1 = parity of bits 1,3,5,7 → p1 = parity(1,0,1) = 0


• p2 = parity of bits 2,3,6,7 → p2 = parity(1,1,1) = 1
• p4 = parity of bits 4,5,6,7 → p4 = parity(0,1,1) = 0

Final encoded = 0 1 1 0 0 1 1

9 c. Working Principle of Bluetooth

• Bluetooth is a short-range wireless communication standard (up to ~10 meters).


• Operates in 2.4 GHz ISM band using frequency hopping spread spectrum (FHSS).
• Devices form a piconet (1 master, up to 7 slaves).
• Master manages communication and timing.
• It enables wireless data exchange in devices like phones, headsets, printers, etc.

10. Short Notes

a. FTP (File Transfer Protocol)

• Allows users to upload/download files between computers over a TCP/IP network.


• Uses two channels: control (port 21) and data (port 20).
• Requires login authentication; can be secured via FTPS or SFTP.

b. Socket

• A software endpoint that allows programs to communicate over a network.


• Combines IP address and port number.
• Used in both TCP (connection-oriented) and UDP (connectionless) communication.

c. DNS (Domain Name System)

• Translates domain names (e.g., [Link]) into IP addresses.


• Uses a hierarchical structure of servers (root, TLD, authoritative).
• Supports caching to improve efficiency.

11 a. Stop and Wait with Packet Loss

• Out of every 4 packets, 1 is lost → success rate = 3/4


• To successfully send 10 packets, expected sends = 10 / (3/4) = 13.33 ≈ 14 packets
• So, 14 packets are sent (approx).

11 b. Unicasting, Anycasting, Multicasting, Broadcasting

Mode Description

Unicasting One-to-one communication (one sender to one receiver)

Anycasting One-to-one-of-many: sent to nearest receiver in a group

Multicasting One-to-many (select group of hosts)

Broadcasting One-to-all: sent to all devices on the network

11 c. Key Requirements in Asymmetric-Key Cryptography

• Each person has a public key and a private key.


• For 10 people, each person keeps their key pair:
o Total keys = 10 × 2 = 20 keys
• If symmetric key was used instead, key pairs needed would be = n(n-1)/2 = 45.
• But in asymmetric cryptography, only 20 keys are needed.
12 a. Wireless LAN (WLAN)

• WLAN connects devices wirelessly within a local area.


• Uses IEEE 802.11 (Wi-Fi) standards.
• Components: Access Point (AP), wireless clients (laptops, phones, etc.)
• Operates in 2.4 GHz and 5 GHz bands.
• Supports mobility and flexibility in homes, offices, cafes.

Here are the detailed answers for the remaining questions from your screenshot (Questions 12b to 15b):

12 b. Explain CSMA/CD Mechanism for Access Control

CSMA/CD (Carrier Sense Multiple Access with Collision Detection) is used in Ethernet networks to avoid
and manage collisions.

Steps:

1. Carrier Sense: Node checks the channel before sending data.


2. Multiple Access: All nodes have access to the same channel.
3. Collision Detection: If two devices transmit simultaneously, a collision is detected.
4. Jam Signal: The sender transmits a jam signal to inform others.
5. Backoff Algorithm: Devices wait for a random time before retrying.

Limitation: Not effective in wireless (used only in wired Ethernet like 10Base-T).

12 c. Datagram Identification Number

If a host is sending 100 datagrams and the first has ID 1024, then:

• The last datagram will have ID = 1024 + 99 = 1123

13 a. IPv4 Datagram Payload and Efficiency

Given:

• Total Length = 0x00A0 = 160 bytes


• Header Length (HLEN) = 0x5 = 5 × 4 = 20 bytes

Payload = 160 - 20 = 140 bytes


Efficiency = Payload / Total = 140 / 160 = 0.875 or 87.5%

13 b. Inter-Domain vs Intra-Domain Routing Protocols

Feature Intra-Domain Inter-Domain


Area Covered Single AS (Autonomous System) Between multiple ASes
Feature Intra-Domain Inter-Domain
Protocols RIP, OSPF, EIGRP BGP (Border Gateway Protocol)
Admin Control Managed by single organization Managed by multiple organizations
Convergence Speed Faster Slower

13 c. Hop Count in RIP

RIP uses hop count as a metric:

• Maximum hop count = 15


• Helps avoid routing loops and infinite routing
• If hop count exceeds 15 → destination is unreachable

This simple limit ensures that faulty routes do not propagate indefinitely.

14 a. 0, 1, and p Persistence CSMA

Strategy Description
0-persistent Wait a random time if channel is busy, then sense again
1-persistent Sense channel, if idle → transmit immediately; causes collisions
p-persistent Transmit with probability p, else wait and re-sense; reduces collision

14 b. Leaky Bucket Technique

Used for traffic shaping and congestion control:

• Fixed-size bucket leaks data at a constant rate.


• Incoming packets are added to the bucket.
• If bucket overflows → packets are discarded.
• Ensures constant output rate, avoids bursty traffic.

14 c. Application Layer Protocols

Common protocols include:

• HTTP – Web browsing


• FTP – File transfer
• SMTP – Sending emails
• POP3/IMAP – Receiving emails
• DNS – Domain name resolution
• SNMP – Network management

These protocols define how software applications communicate over the network.

15 a. What is NAT? Why is it needed?


NAT (Network Address Translation) maps private IP addresses to public IPs.

Why needed?

• IPv4 addresses are limited.


• NAT allows multiple devices in a LAN to share a single public IP.
• Adds a layer of security by hiding internal IPs.

15 b. Address Depletion Problem and Classless Addressing

Problem:

• IPv4 address exhaustion due to rigid class-based allocation.

Solution (CIDR):

• Classless Inter-Domain Routing allows flexible subnetting.


• Uses prefix notation (e.g., /22) to allocate only needed addresses.
• Reduces wastage and extends IPv4 lifespan.

Token Bucket Algorithm – Brief Overview

The Token Bucket Algorithm is a network traffic shaping and rate-limiting mechanism used to control how
data packets are transmitted.

✅ Key Concepts:

• A bucket holds tokens, each representing permission to send a fixed amount of data (usually 1 byte or 1
packet).
• Tokens are added to the bucket at a constant rate (e.g., 100 tokens/second).
• If the bucket is full, new tokens are discarded.
• To send data, the system must remove tokens from the bucket.
o If enough tokens are available, data is sent.
o If not, the data must wait until enough tokens accumulate.

Main Characteristics:

Feature Description
Token Rate Controls average transmission rate
Bucket Size Controls burst tolerance
Allows Bursts? ✅ Yes, up to bucket capacity
Purpose Traffic shaping and rate control

How It Works:

1. Tokens are continuously added to the bucket.


2. Each outgoing packet removes a token.
3. If enough tokens are available → send immediately.
4. If not → delay or drop packets depending on configuration.

✅ Advantages:

• Allows burst traffic (better than Leaky Bucket).


• Smoothens long-term data flow while permitting flexibility.

You might also like