Skip to content

Latest commit

 

History

History
42 lines (27 loc) · 2.57 KB

README.md

File metadata and controls

42 lines (27 loc) · 2.57 KB

SDN-Simulation-with-OpenFlow

Use Mininet to create topologies with OpenFlow switches and install flows to simulate network operations

MiniNet creates scalable Software-Defined Networks (up to hundreds of nodes) using OpenFlow, on a single PC. It allows to quickly create, interact with and customize a software defined network prototype with complex topologies, and can be used to emulate real networks – all on your PC MiniNet can work with any kind of OpenFlow controller

Simple SDN Topology

Simulating a software defined network with 2 hosts and 5 switches using mininet and OpenFlow switches. Topology_1

Used Mininet to create the topology above, where A, B, C, D, and E are all Openflow switches. Enforced the following policies so that,

Traffic from H1 -> H2

  • HTTP traffic with d_port=80 follows path: A-B-D
  • other traffic follows path: A-C-E-D
  • Traffic from H2 -> H1

  • HTTP traffic with s_port=80, follow path: D-C-A
  • other traffic, follow path: D-B-E-C-A
  • Fat-Tree topology in Mininet

    Installed OpenFlow switches, hosts and links in the below fashion to create a N=4 Fat-Tree topology.

    Installed OpenFlow switches, hosts and links in the below fashion to create a N=6 Fat-Tree topology

    Installation

    The code for simple SDN topology is in "topology.py". First you need to create the topology with the python script. But the packets will not flow until you install the flows in the switches. The flows for this topology are in shell script "Flows.sh". You can run the shell script in a separate terminal to install the flows.

    Then run the ping command in mininet to test the network. If the packets are dropped, that means the flows are not installed in controller and hence the switches do not know how to handle the packets.

    After successfully installing the flows, you can run the wireshark and capture the packets flowing in the network to check the flows. The code for Fat Tree topologies are present in "FatTree_4.py" and "FatTree_6.py". There are no flows in FatTree networks. However you can easily install the flows using commands similar to previous topology.