Skip to main content

Posts

Showing posts from August, 2026

Simulate Stop-and-Wait ARQ over a point-to-point link with varying bit-error rates (0–20%) | NS3 Project 30

Network Congestion and Buffer Overflow Simulating DropTail vs. RED Queue Disciplines in NS-3 1. Introduction Network congestion occurs when the incoming traffic load exceeds the processing or transmission capacity of network resources such as routers or links. In packet-switched networks, routers temporarily store packets in buffers (queues) before forwarding them. When the arrival rate of packets is higher than the departure rate, the queue length increases progressively. Once the buffer reaches its maximum capacity, any additional incoming packets are dropped, resulting in buffer overflow. This leads to packet loss, increased queuing delay, reduced throughput, and overall degradation in network performance. Efficient queue management techniques are therefore essential to control congestion and maintain network stability. 2. Queue Management Techniques: DropTail vs. RED Queue disciplines define how packets are stored and discarded in a router buffer. The design and ...

Simulate and trace TCP Slow-Start, Congestion Avoidance, and Fast Recovery phases | NS3 Project 29

Analysis of TCP Congestion Control Phases Simulating TCP NewReno on a Dumbbell Topology in NS-3 1. Project Overview This project simulates a Dumbbell Topology to observe how TCP NewReno manages network congestion. By creating a bottleneck link with limited bandwidth (1 Mbps), we force the TCP protocol to transition through its three primary phases: Slow-Start, Congestion Avoidance, and Fast Recovery. 2. LLM Source Documentation To develop the source code ( 24bps1052.cc ), the following AI assistant was utilised: LLM Used: Gemini 3 Flash (Google) Prompt Provided: "Hey, can you help me write an ns-3.44 script for my networking lab? I need to save it as scratch/23bps1xxx.cc. I need a Dumbbell Topology with 4 nodes: Node 0 and 1 connect to Node 2 (the router), and Node 2 connects to Node 3. Set the link between 2 and 3 to 1Mbps so it becomes a bottleneck. Use TCP NewReno for the simulation. I need to generate a trace file called cwnd_...

Simulation of Link-State routing (Dijkstra) in a 12-router wired network | NS3 Project 28

Simulate Link-State Routing Using OLSR in NS-3 Performance and Convergence Analysis in a 12-Router Wired Network Requirements Topology: Create a network with 12 nodes connected in a grid/mesh topology. Link Costs: Assign different link costs by varying propagation delay or data rate across links. Traffic Generation: Generate UDP traffic between a source node (R0) and a destination node (R11). Failure & Recovery: Introduce a link failure at 40 seconds and restore the link at 44 seconds. Metrics: Measure and display the convergence time of the routing protocol. Tracing: Enable ASCII/PCAP tracing and generate NetAnim visualization. Diagram: Provide a Mermaid diagram representing the 12-node network topology. The prompt above represents the refined, final instruction formulated after iterative tuning with Gemini and ChatGPT alongside standard NS-3 OLSR examples. Network Topology The network topology used in this simulation c...

To study the impact of channel error rate on Stop-and-Wait vs. GBN efficiency in a point-to-point link | NS3 Project 27

Impact of Channel Error Rate on Stop-and-Wait vs. Go-Back-N Efficiency Performance Evaluation Over a Point-to-Point Link in NS-3 Theory Behind This Behaviour Stop-and-Wait and Go-Back-N are flow control protocols that differ fundamentally in how they utilize the communication channel. In Stop-and-Wait , the sender transmits a single packet and remains idle until an acknowledgement (ACK) is received before sending the next packet. This mechanism incurs significant propagation and idle overhead, particularly when channel propagation delay or packet error rates increase, resulting in low throughput and poor channel efficiency. In contrast, Go-Back-N (GBN) uses a sliding-window mechanism that enables multiple unacknowledged packets to be transmitted consecutively via pipelining. If an error or packet drop occurs, the receiver discards the corrupted packet along with all subsequent out-of-order packets, prompting the sender to retransmit the window starting from the lost se...

Study the effect of delayed ACKs on TCP throughput in a point-to-point link | NS3 Project 26

Study the Effect of Delayed ACKs on TCP Throughput Performance and Latency Evaluation in a Point-to-Point NS-3 Link Simulation Script (tcp-delayed-ack.cc) #include "ns3/core-module.h" #include "ns3/network-module.h" #include "ns3/internet-module.h" #include "ns3/point-to-point-module.h" #include "ns3/applications-module.h" #include "ns3/flow-monitor-module.h" using namespace ns3; NS_LOG_COMPONENT_DEFINE("TcpDelayedAckStudy"); int main(int argc, char *argv[]) { bool delayedAck = true; uint32_t delayedAckCount = 2; // ACK every N segments std::string tcpVariant = "TcpNewReno"; double simTime = 10.0; CommandLine cmd; cmd.AddValue("delayedAck", "Enable delayed ACKs", delayedAck); cmd.AddValue("delayedAckCount", "Segments before ACK", delayedAckCount); cmd.Parse(argc, argv); // --- TCP Configuration --- Config::S...

Simulate Multiple Concurrent FTP Sessions and Analyze Aggregate Throughput | NS3 Project 25

Simulate Multiple Concurrent FTP Sessions and Analyze Aggregate Throughput Simulation Environment: ns-3 | Tools Used: FlowMonitor, NetAnim, TraceMetrics 1. Objective The primary objective of this experiment is to simulate a network scenario in which multiple concurrent File Transfer Protocol (FTP)-like sessions operate simultaneously over a shared network infrastructure. Using the ns-3 discrete-event network simulator, the study models seven independent TCP bulk-send flows that traverse a common bottleneck link. The experiment aims to measure and analyze the individual throughput of each flow as well as the aggregate throughput delivered to the single receiver node. By configuring access links with high capacity and constraining the router-to-receiver link to a narrow bandwidth, the simulation deliberately induces congestion to study how TCP's congestion control mechanisms influence flow behavior, resource sharing, and overall network efficiency. Furthermore, the...

Study the effect of RED vs. DropTail queue management in a dumbbell topology | NS3 Project 24

TOPIC: Wired Networks & Point-to-Point TITLE: Study the effect of RED vs. DropTail queue management in a dumbbell topology   QUEUE MANAGEMENT TECHNIQUES AND ITS TYPES – INTRODUCTION Queue management plays a critical role in controlling congestion in computer networks. In packet-switched networks, routers maintain queues to temporarily store packets before forwarding them. When network traffic increases beyond capacity, congestion occurs, leading to packet loss, increased delay, and reduced throughput. Two widely used queue management techniques are DropTail Queue Management and Random Early Detection (RED) . DropTail is a simple First-In-First-Out (FIFO) mechanism where packets are dropped only when the queue becomes full. On the other hand, RED is an active queue management algorithm that proactively drops packets based on the average queue size before the queue becomes full. This helps in early congestion detection and improves overall network performan...