Skip to main content


Showing posts from November, 2017

MANET Routing Protocols using ns3


Download the Code here:

Check the Video for Detailed instruction and how to use the plots, graphs and source code.

Comparison of MANET routing Protocols 1. AODV
3. DSR
using NS3 (Network Simulator 3)
B.Tech, M.Tech, PhD...
1. Reactive Vs Proactive routing
2. PErformance comparison of MANET protocols
3. AODV Vs DSDV Comparison and also at my channel.

What Version: ns-3.29
My Ubunut OS is: Ubuntu 18.04

This file we are going to use for our simulation:

Once you under stand the code, now lets run this example

Step 1: Copy the above file in to ~ns-3.29/scratch/ folder

Step 2: Understand this code.
Step 3: Run this code
Open the terminal, Go to ns-3.29 and run the following command

$] ./waf --run scratch/manet-routing-compare

enable the following header file

#include "ns3/flo…

Error: Meta size 4064 too large (max = 1000)

Error: Meta size 4064 too large (max = 1000)

When using Mannasim Simulator for ns2, you may encounter this error when you are trying to run a tcl file with LEACH protocol. Here is a small workaround for the solution.

To install mannasim, please go here.

To overcome the above error, open the file
and change the following line

struct hdr_rca {
       int msg_type_;
       char meta_[1000];


struct hdr_rca {
       int msg_type_;
       char meta_[5000];

Since I get 4064 as meta size, i changed it to 5000, if you get more than 4064, then accordingly you can increase the meta size and compile it. 
Here is the important step to compile
~ns-2.35 $] ./configure --with-tcl-ver=8.5
~ns-2.35 $] make

Sometimes simply typing make will compile, but the .object files would not be created. So use the above two steps.

Here is the screenshot.

T S Pradeep Kumar