CN Resources Final
CN Resources Final
Internet Overview
Definition: The Internet is a "network of networks," connecting millions of ISPs at various levels
(local, regional, and national) to enable global communication.
Internet Structure:
o Network Edge: Consists of clients and servers, often located in data centers.
o Access Networks: How end systems connect to edge routers, including various types
like cable-based, DSL, and wireless networks.
1. Access Networks
- Access networks connect end systems to an edge router and are crucial in providing internet services.
These networks can be wired or wireless, each suited for specific types of environments and data
requirements.
- Residential Access:
- DSL (Digital Subscriber Line): Uses existing telephone lines, offering speeds of 24–52 Mbps
downstream and 3.5–16 Mbps upstream. It connects via the central office’s DSLAM (Digital Subscriber
Line Access Multiplexer), separating data and voice traffic.
- Cable-based Access: Uses cable modems and Hybrid Fiber Coax (HFC) networks, achieving 40 Mbps
to 1.2 Gbps downstream and 30–100 Mbps upstream. Homes share the network connection to a central
cable headend.
- Home Networks:
- Often combine both wired and wireless devices to connect to the internet, with a modem or router
that manages the connection between different devices and the ISP.
- Enterprise Networks:
- Found in businesses and institutions. They combine wired Ethernet (100 Mbps, 1 Gbps, 10 Gbps) and
wireless WiFi access points (11 Mbps, 54 Mbps, up to 450 Mbps) to provide connectivity throughout a
location.
- Devices connect to an institutional router that links to the ISP, with Ethernet switches distributing
connectivity within the network.
- Data centers use high-bandwidth links (10 Gbps to 100 Gbps) to connect thousands of servers,
ensuring rapid data processing and access to large volumes of information.
1. Overview
- Wireless Access Networks connect devices to the internet through a shared wireless access point
(base station). This technology allows mobile devices to access the internet from a variety of locations.
2. Key Types:
- Used in homes, businesses, and public spaces, providing data rates from 11 Mbps (WiFi 1) to several
Gbps (WiFi 6).
- Cellular Networks:
- 4G and 5G Networks: Cellular networks provide mobile access, with speeds varying by technology
generation (4G provides around 100 Mbps, while 5G can reach several Gbps).
- Coverage: Cellular networks are organized into cells, each served by a base station, allowing users to
maintain connectivity over large areas by moving between cells.
- In a WiFi network:
2. The access point links the device to an edge router, which then forwards data to the wider internet.
Protocols: Rules governing data exchange; examples include HTTP, TCP, IP, and WiFi.
o Purpose: Provide structure for data communication by defining message formats and
exchange procedures.
Standards:
o RFC (Request for Comments): Documents describing internet protocols and services.
o IETF (Internet Engineering Task Force): Organization developing and promoting internet
standards.
1. Forwarding:
- Definition: The process of moving packets from a router’s incoming link to the appropriate outgoing
link based on the destination address.
- Purpose: Forwarding is a local, per-router action that ensures each packet moves closer to its
destination.
- Analogy: Like sorting letters at a post office to direct them to the correct local branch.
2. Routing:
- Definition: The process of determining the overall path packets take from the source to the
destination across a network.
- Purpose: Routing is a global action that involves building a routing table, specifying the best paths for
packets across the network.
- Analogy: Like planning the best overall delivery route for a package across cities and states.
These two functions work together to ensure efficient and accurate data delivery through complex
networks, making them fundamental to network core operations.
Throughput
1. Definition: Throughput is the rate at which bits are successfully transmitted from sender to
receiver, measured in bits per second (bps).
2. Types of Throughputs:
o Throughput is generally limited by the link with the lowest transmission rate
(bottleneck) between the sender and receiver.
The caravan analogy helps explain packet delay and propagation in networks:
Car = Bit, Caravan = Packet: Imagine cars (bits) traveling in a line (packet) from one toll booth to
another.
Transmission Time: Each car takes time to pass through a toll booth (transmission delay).
Propagation Time: After passing through, each car travels to the next booth, akin to a packet
traveling over a link.
Example:
If 10 cars (bits) take 12 seconds each to pass through a toll (transmission rate), it takes 120
seconds to move the entire caravan onto the road.
Propagation Delay: Time for the last car to travel 100 km at 100 km/h = 1 hour. Total time for all
cars to arrive: 1 hour + 120 seconds.
1. Network of Networks:
Tier-1 ISPs: Large, global networks (e.g., AT&T, Level 3) interconnect without
fees to cover national and international data routes.
Tier-2 ISPs: Smaller, regional networks pay Tier-1 ISPs for connectivity.
Access ISPs: Provide internet to end-users and connect to regional and Tier-2
ISPs.
2. Economic Agreements: ISPs make arrangements (peering or transit agreements) to ensure data
flows efficiently across networks.
Structure: A 32-bit address split into four sections (octets), each ranging from 0 to 255 (e.g.,
192.168.1.1).
Parts:
IPv6
Purpose: Solves IPv4 address exhaustion, supports more unique addresses, includes security
features, and allows easier configuration.
Example:
o Host ID: .5
4. Subnetting Basics
1. Definition:
- Subnetting is a method of dividing a large IP network into smaller, more manageable subnetworks
(subnets). It improves network performance, enhances security, and allows better organization of IP
addresses.
2. IP Address Structure:
- Subnet Mask: Used to determine which portion of the IP address refers to the network and which to
the host.
3. Subnet Mask:
- A 32-bit number written in decimal (e.g., 255.255.255.0).
- Class C Subnet Mask: Default is 255.255.255.0, indicating the first 24 bits (three octets) are for the
network, and the last 8 bits are for the hosts.
Example:
For 255.255.255.0, the first 24 bits are for the network, and the last 8 are for hosts.
CIDR Notation: A simplified format to denote subnet masks, using the number of network bits
after a /. For example, /24 means 24 bits are for the network, and the subnet mask is
255.255.255.0.
ARP maps an IP address to a MAC (Media Access Control) address. This is essential for devices on a local
network to communicate using IP addresses by translating them to physical (MAC) addresses.
ARP Process:
3. The requesting device uses this MAC address to send data directly to the correct physical
machine.
ICMP is used for diagnostics and error reporting in network communication, most commonly for ping
(testing connectivity) and traceroute (tracking packet routes).
1. Borrow 2 Bits:
o Subnet 1: 192.168.1.0/26
o Subnet 2: 192.168.1.64/26
o Subnet 3: 192.168.1.128/26
o Subnet 4: 192.168.1.192/26
- Run on different end systems: For example, a web server application on one system communicates
with a web browser on another.
- Use network communication protocols: Applications don’t directly interact with network devices;
instead, they communicate through defined protocols like HTTP, FTP, or DNS.
- Focus on end systems only: Application software is developed for end devices, without needing
changes to network core devices (e.g., routers).
Example: A web application allows a server to communicate with users through a browser using HTTP.
2. Client-Server Paradigm
- Client-Server Architecture: A model where clients (user devices) request services from a centralized
server.
- Server: Always on, has a fixed IP address, and typically hosts data or applications. Examples include
websites, email servers, and file servers.
- Client: Initiates communication, connecting to the server on request. Clients are often intermittently
connected with dynamically assigned Ips.
Example: In web browsing, the client (browser) requests data from the web server, which responds with
the requested content.
In P2P networks, there is no central server. Instead, devices, known as peers, communicate directly with
each other:
- Challenges: Difficult to manage, as peers may change IP addresses and be intermittently connected.
Example: File-sharing networks like BitTorrent use P2P to share files directly between users.
4. Processes Communicating
- Process: A program running on a device. Applications communicate by sending messages from one
process to another across the network.
- Inter-Process Communication:
- On the same device: Communication happens through the device’s operating system.
- Across different devices: Processes exchange messages using network protocols.
Example: An email client process on a laptop communicates with an email server process over the
internet.
5. Sockets
A socket is the interface between the application and the transport layer, enabling data exchange:
- Analogy: A socket is like a door through which messages are sent and received.
- Operation: Applications write data to the socket, which is then transmitted over the network.
Each process has a unique socket for communication, combining the IP address and a port number to
ensure messages reach the correct application.
6. Addressing Processes
- IP Address + Port Number: An application’s network address is a combination of its device’s IP address
and a port number (e.g., HTTP uses port 80).
Example: To connect to a website, the browser uses the server’s IP address with port 80 to initiate an
HTTP connection.
An application-layer protocol defines the rules for data exchange between applications. It specifies:
- Message Types: Request and response messages (e.g., HTTP GET and POST).
- Communication Rules: When and how applications should send and receive messages.
Different applications have varied requirements from the transport layer. Common needs include:
- Throughput: Some applications need a minimum data rate for optimal functionality (e.g., video
streaming).
- Suitable for applications tolerating some data loss, like video streaming.
- HTTP (Hypertext Transfer Protocol): The primary protocol for transferring web content. HTTP operates
on a client-server model and is stateless, meaning the server doesn’t retain information about past
requests.
- Non-Persistent HTTP:
- Persistent HTTP:
- Request Line: Specifies the method (GET, POST), the URL, and HTTP version.
- Header Lines: Provide additional information, like the browser type (`User-Agent`) and the acceptable
response format (`Accept`).
- Entity Body: Present in POST requests, containing data to send to the server (e.g., form submissions).
```
Host: www.example.com
User-Agent: Mozilla/5.0
Accept: text/html
```
- HEAD: Requests only the header information, used to check if the resource exists.
- Persistent HTTP: Keeps connections open for multiple requests, reducing delay.
- SMTP (Simple Mail Transfer Protocol): Transfers email over TCP, using ASCII format.
- DNS (Domain Name System): Resolves domain names to IP addresses using a hierarchy of root, TLD,
and authoritative servers.
- Data Integrity: Critical for error-free data applications, like file transfers.
- Latency Sensitivity: Low delay is needed for real-time applications like VoIP.
Q: how much time to distribute file (size F) from one server to N peers?
o Routers forward data between networks, selecting the optimal path to ensure data
reaches its destination efficiently.
2. Network Topologies
o Star: Central hub; scalable but fails if the hub goes down.
o Bus: Shared central cable; simple, but a break in the cable affects the whole network.
o Mesh: Every device connects to every other; very reliable but complex and costly.
o
3. Explain the transmission delay formula and its application.
- Application: Measures the time required to push a packet onto the network link. Larger packets or
slower transmission rates increase delay.
- Role: DNS translates domain names to IP addresses, enabling device connectivity through hierarchical
queries (root → TLD → authoritative servers).
- HTTP: Allows clients to pull data from the server without maintaining state.
- SMTP: Enables clients to push data to the server using a persistent connection, typically for email.
Important questions
Q1: Why does an identifier include both an IP address and port number rather than just relying on an
IP address?
An IP address identifies a device on the network, but each device can run multiple applications or
services at once (like a web server, email server, or FTP server). To direct data to the correct application
on the device, we need a port number along with the IP address:
- The port number specifies which application on that device should receive the data.
Example: If you connect to a web server, the IP address gets you to the right server, but the port (usually
80 or 443 for HTTP or HTTPS) tells the server to send the data to the web service specifically.
Tier-1 networks are large networks that form the backbone of the internet, handling major data routes
globally without paying any other network for traffic exchange (they "peer" freely with each other).
Google runs its own network to deliver its services reliably and efficiently to millions of users worldwide.
Connecting directly to Tier-1 networks allows Google to:
- Provide faster service by reaching users more directly, bypassing intermediary networks.
Q3: Suppose a link has a capacity of 1000 Mbps, and each user can connect to this link at a rate of 100
Mbps using packet switching, remaining active only 10% of the time. How many users can be
connected to the channel?
The total link capacity is 1000 Mbps, and each user uses 100 Mbps when active. Because each user is
active only 10% of the time, the effective bandwidth each user requires on average is:
Answer: Up to 100 users can be connected to this link, assuming each user is active only 10% of the
time.
Section B Paper
Routers are networking devices that forward data packets between computer networks. They route
data from one network to another by selecting the optimal path for data to travel, ensuring that data
reaches its intended destination efficiently.
-Packet Switching: Data is broken into packets, which are routed individually through the network and
reassembled at the destination. It is efficient for handling varying types of traffic.
-Circuit Switching: A dedicated communication path is established between two endpoints for the entire
duration of the communication. It’s commonly used in voice networks but less efficient for data
networks.
3. Identify and explain the role of key network protocols used in communication.
TCP (Transmission Control Protocol): Ensures reliable data transmission with error-checking, sequencing,
and acknowledgment.
IP (Internet Protocol): Handles addressing and routing of packets, so they reach the correct destination.
HTTP (Hypertext Transfer Protocol): Used for transferring web pages over the internet.
FTP (File Transfer Protocol): Used for transferring files between devices on a network.
4. Discuss the differences between packet switching and circuit switching in terms of data handling.
Packet Switching: Data is divided into packets that take independent routes to the destination, which
increases flexibility and efficiency but may lead to packet loss or delay.
Circuit Switching: Establishes a dedicated path for data transfer, which ensures consistent quality but is
less efficient as it requires a constant connection even during idle times.
Queuing Delay: Time a packet spends waiting in queue before it can be transmitted.
Transmission Delay: Time taken to push all the packet’s bits onto the link.
Propagation Delay: Time taken for the packet to travel through the physical medium from sender to
receiver.
Caravan Example:
Q2. Describe the different types of network topologies, including star, bus, ring, and mesh. Summarize
the advantages and disadvantages of each topology in terms of scalability, fault tolerance, and data
transmission efficiency. Provide examples of scenarios where each topology is most effectively used.
Star Topology:
Advantages: Easy to install and manage; a failure in one link doesn’t affect others.
Bus Topology:
Disadvantages: Limited scalability; a failure in the central cable brings down the network.
Ring Topology:
Advantages: Each device has an equal chance to send data; predictable performance.
Mesh Topology:
Advantages: High fault tolerance as each device is connected to every other device.
Use Case: Used in mission-critical applications where reliability is essential, such as military
communications.
Q3. A packet of size 10,000 bits is sent over a link with a transmission rate of 100 Mbps. Calculate the
transmission delay for the packet. Additionally, if the propagation speed of the link is 2 x 10^8 m/s
and the length of the link is 500 km, calculate the propagation delay. Determine the total delay
experienced by the packet.
Q4. Analyze the differences between the Client-Server and Peer-to-Peer (P2P) architectures. Examine
how each architecture manages file distribution, scalability, and network traffic.
Client-Server Architecture:
File Distribution: Centralized; files are stored and managed by a central server.
Scalability: Limited by the server’s capacity; adding more clients may require a more powerful server.
Network Traffic: Higher on the server side; data must pass through the server, creating potential
bottlenecks.
Use Case: Used in web services, email, and applications requiring centralized control.
Scalability: More scalable as new peers add resources and distribution capacity.
Quiz questions
Q1: Explain the following terms with suitable examples from the given Network IP Address:
205.192.168.0.
1. Network-ID: 205.192.168.0
The Network-ID (or Network Address) identifies the specific network to which all devices
belong. In this case, 205.192.168.0 represents the network itself. It cannot be assigned to any
individual device within the network, as it is used to route traffic to the entire network.
Example: In a company with the IP address 205.192.168.0, all devices within this network (e.g.,
computers, printers) will communicate within this address space.
2. Broadcast-ID: 205.192.168.255
The Broadcast-ID (or Broadcast Address) is used to send data packets to all devices on the
network. This address is the highest address in the subnet and cannot be assigned to a specific
device.
Example: If a device sends a packet to 205.192.168.255, all devices on the network
205.192.168.0 will receive the packet.
3. Gateway: 205.192.168.1
The Gateway (or Default Gateway) is the device (typically a router) that serves as the access
point for devices on the local network to communicate with external networks (like the internet).
The gateway allows devices to send data outside their local network.
Example: A router with the IP address 205.192.168.1 would be responsible for directing traffic
between the 205.192.168.0 network and other networks.
The First Usable IP is the first IP address available for assignment to devices within the network.
It is the first address after the Network-ID.
Example: The first computer on the network could be assigned the IP address 205.192.168.2,
allowing it to communicate with other devices within the same network.
The Last Usable IP is the last IP address that can be assigned to a device in the network. It is the
address just before the Broadcast-ID.
Example: The last device, such as a printer, might be assigned the IP address 205.192.168.254 to
ensure it can communicate with all other devices on the network without conflicting with the
broadcast address.
Q2: Infer the Class of each given Subnet Mask.
255.255.255.0 – Class C
255.0.0.0 – Class A
255.255.0.0 – Class B
255.255.0.0 – Class B
205.192.168.0 – Network-ID
205.192.168.255 – Broadcast-ID
205.192.168.256 – Exceeds valid range
Reduce Network Diameter: Minimize the number of hops a packet must traverse to reach its
destination.
Choose Efficient Routing Protocols: Use routing protocols that quickly converge and avoid
routing loops.
Optimize Link Capacities: Ensure that links have sufficient bandwidth to handle the traffic load.
Traffic Shaping and Policing: Control the rate at which traffic enters the network to avoid
congestion.
Quality of Service (QoS): Prioritize certain types of traffic, such as real-time traffic, to ensure low
latency.
Congestion Control: Implement mechanisms to detect and alleviate congestion, such as TCP
congestion control.
High-Performance Routers and Switches: Use high-performance network devices with efficient
hardware and software.
Reduce Processing Delay: Optimize router and switch software to minimize processing time.