How to Simulate Dual Ring Topology Projects Using OMNeT++

To simulate a Dual Ring Topology using OMNeT++ that includes making two interconnecting rings, frequently utilized in high-reliability networks like Fiber Distributed Data Interface (FDDI) or Resilient Packet Ring (RPR) networks. This topology is advantageous for fault tolerance because data can travel in both directions, offering redundancy.

In a dual ring topology, two rings (primary and secondary) deliver communication among the nodes, with the secondary ring used as a backup in case of a failure in the primary ring. We will provide a comprehensive guide for conducting simulations in Dual Ring Topology Projects using the OMNeT++ tool to achieve optimal results. If needed, we will also share additional information and simulation results specific to your area of interest.

Here’s a step-by-step instruction to replicating a Dual Ring Topology project in OMNeT++ using the INET framework:

Steps to Simulate Dual Ring Topology in OMNeT++

  1. Install OMNeT++ and INET Framework:

Make certain that OMNeT++ and the INET framework are installed and appropriately configured. INET offers the tools and modules for replicating network components like nodes, switches, and links.

  • We can download and install OMNeT++.
  • Download and install the INET Framework.
  1. Understand Dual Ring Topology:

In a dual ring topology:

  • Each node is connected to two neighbouring nodes: one connection is portion of the primary ring, and the other connection is part of the secondary ring.
  • Data can flow in both directions (clockwise and counterclockwise) around the rings.
  • In case of a link failure, the network can be used the secondary ring to conserve communication.
  1. Define Dual Ring Topology in NED File:

Describe the dual ring topology in the NED file, in which each node is connected to its neighbors in two distinct rings: the primary and secondary.

Here’s an instance NED file to describe a dual ring topology with five nodes:

network DualRingNetwork

{

parameters:

int numNodes = default(5);  // Number of nodes in the dual ring

submodules:

// Define the network nodes

node[numNodes]: <NodeType> {

@display(“p=100+300*i,200”);

}

connections allowunconnected:

// Connect nodes in the primary ring (clockwise direction)

for i=0..numNodes-2 {

node[i].ethg++ <–> Eth100M <–> node[i+1].ethg++;

}

node[numNodes-1].ethg++ <–> Eth100M <–> node[0].ethg++;  // Close the primary ring

// Connect nodes in the secondary ring (counterclockwise direction)

for i=0..numNodes-2 {

node[i+1].ethg++ <–> Eth100M <–> node[i].ethg++;

}

node[0].ethg++ <–> Eth100M <–> node[numNodes-1].ethg++;  // Close the secondary ring

}

In this example:

  • numNodes represents the number of nodes in the dual ring topology.
  • The first loop makes a connections in the primary ring (clockwise).
  • The second loop makes connections in the secondary ring (counterclockwise), successfully closing the second ring for redundancy.
  • Eth100M is the Ethernet link among the nodes with a bandwidth of 100 Mbps.
  1. Define Node Types in NED:

We can utilize the INET framework’s StandardHost for the nodes, or we can make own node types to replicate the behaviour of nodes in the dual ring topology.

Here’s an instance of describing a node type for the NodeType:

import inet.node.inet.StandardHost;

 

module NodeType extends StandardHost

{

parameters:

@display(“i=device/laptop”);  // Icon for each node

}

Each node is denoted as a StandardHost, with simple networking capabilities, containing Ethernet communication.

  1. Configure the INI File:

In the omnetpp.ini file, describe the configuration for replicating traffic among the nodes, handling ring behaviours, and allowing fault tolerance.

Here’s an instance of how to set up the simulation for traffic generation and fault tolerance:

[General]

network = DualRingNetwork

sim-time-limit = 60s   # Set the simulation time limit

# Configure IP addresses for each node in the network

*.node[*].networkLayer.ipv4.address = “10.0.0.x”  # Assign IP addresses to all nodes

# Configuring TCP traffic between two nodes in the dual ring

*.node[0].numApps = 1

*.node[4].numApps = 1

# Define a TCP client on Node 0 and a TCP server on Node 4

*.node[0].app[0].typename = “TcpBasicClientApp”

*.node[0].app[0].connectAddress = “10.0.0.5”  # IP address of Node 4

*.node[0].app[0].startTime = 2s

*.node[0].app[0].stopTime = 58s

*.node[4].app[0].typename = “TcpBasicServerApp”  # TCP server on Node 4

In this configuration:

  • Node[0] is set up as a TCP client, and Node[4] is configured as a TCP server.
  • IP addresses are allocated to each node in the network.
  • Traffic flows from Node[0] to Node[4], and the dual ring make sure fault-tolerant delivery of data.
  1. Simulate Traffic Using TCP or UDP:

We can generate traffic among the nodes using either TCP or UDP. Here’s an instance for replicating UDP traffic:

# Configuring UDP traffic from Node 0 to Node 4

*.node[0].app[0].typename = “UdpBasicApp”

*.node[0].app[0].destAddresses = “10.0.0.5”  # IP address of Node 4

*.node[0].app[0].destPort = 5000

*.node[0].app[0].packetLength = 1024B

*.node[0].app[0].sendInterval = uniform(1s, 2s)

*.node[0].app[0].startTime = 2s

*.node[0].app[0].stopTime = 58s

# Configure Node 4 as a UDP sink to receive packets

*.node[4].app[0].typename = “UdpSink”

*.node[4].app[0].localPort = 5000

This configuration makes UDP traffic from Node 0 to Node 4, in which Node 4 is a UDP sink.

  1. Run the Simulation:
  • We can open OMNeT++ IDE, import the project, compile, and run the simulation.
  • Utilize Qtenv to envision the dual ring topology and observe packet transmission over both the primary and secondary rings.

In the course of the simulation, we can monitor how data flows in both directions on the rings. If a link failure happens in one ring then data can still attain the destination through the secondary ring, conserving fault tolerance.

  1. Introduce Link Failure for Fault Tolerance Testing:

To replicate fault tolerance, we can launch a link failure during the simulation. This experiments how the secondary ring manages traffic when the primary ring fails.

Here’s how we can launch link failure during the simulation in the omnetpp.ini file:

# Disable the primary link between Node 1 and Node 2 at time 20s

**.node[1].ethg++ <–> Eth100M <–> node[2].ethg++**.disableAt = 20s

This configuration disables the link among Node 1 and Node 2 at 20 seconds into the simulation, pushing the network to reroute traffic through the secondary ring.

  1. Analyze the Results:

OMNeT++ offers detailed logs and statistical informations to examine the performance of the dual ring topology. Key parameters consists pf:

  • Throughput: Calculate the data transmission rate among the nodes.
  • Latency: Estimate the delay in data attaining its destination.
  • Fault Tolerance: Investigate how the system performs when a link in the primary ring fails, and how the secondary ring compensates.

Utilize Plove or Scave to visualize simulation outcomes like throughput, latency, and packet loss.

  1. Advanced Features (Optional):
  1. Dynamic Routing: Execute routing protocols, which dynamically route traffic via the dual ring when a failure happens.
  2. Traffic Prioritization: Utilize Quality of Service (QoS) mechanisms to prioritize traffic on the primary and secondary rings.
  3. Wireless Dual Ring: Substitute Ethernet with wireless connections (e.g., Wi-Fi) to replicate a wireless dual ring network.
  4. Mobility Models: Insert mobility to nodes if the dual ring topology is portion of a mobile network.

Example for Implementing Dynamic Routing:

We can mimic dynamic routing on the dual ring by using a routing protocol such as OSPF:

# Enable OSPF routing for the nodes in the dual ring

*.node[*].ipv4.routingProtocol = “Ospf”

*.node[*].ospf.interfaceTableModule = “^.interfaceTable”

*.node[*].ospf.routingTableModule = “^.routingTable”

This permits nodes to dynamically route traffic according to the network conditions, like link failures.

Summary:

  • Topology Definition: Utilize NED to describe the dual ring topology with primary and secondary rings.
  • Node Configuration: Use INET’s StandardHost for each node, or make a custom node types.
  • Traffic Simulation: Replicate traffic using TCP or UDP and experiment fault tolerance by disabling links in the primary ring.
  • Run and Analyze: Use OMNeT++ simulation tools to observe throughput, latency, and packet loss, and experiment the redundancy of the dual ring.

We exhibited an example-driven basic method to Dual Ring Topology projects, simulated and analysed using OMNeT++ analysis tool. More detailed information will be presented in upcoming manual.

Opening Time

9:00am

Lunch Time

12:30pm

Break Time

4:00pm

Closing Time

6:30pm

  • award1
  • award2