Queuing Models in NS2

M/M/1 is a system with poisson arrival time, servicing exponentially and a queue of unlimited capacity and type of FIFO Queue. This is the simplest queuing system.  NS2 supports various distributions like pareto, exponential, constant, unifrom, etc to handle the network dynamics and metrics. So it is very easy to test the given network link to monitor a given queue using any of these queuing models. The listing 3 and 4 are monitoring the link when DropTail queue is used with a capacity of finite and infinite. Listing 13.3 uses infinite capacity and Listing 13.4 uses Finite capacity The output screen shot is shown below the scripts for further understanding
Listing 3 – M/M/1 Queuing Model #new Simulator creation set ns [new Simulator] #trace file creation for capturing the UDP data set tf [open out.tr w] $ns trace-all $tf
#setting the exponential distribution param set lambda 30.0 set mu     33.0
#creation of nodes set n1 [$ns node] set n2 [$ns node] #The queue limit is 1Lakh as the capacity is infin…

Installing ns-2.35 in Fedora 21

This post will tell you how to install ns-2.35 in Fedora 21 64 bit OS.....

Step 1: Install all the necessary packages
$] sudo yum update
$] sudo yum install tcl tk gcc-c++ libX11-devel libXt-devel libXmu-devel

Step 2: unzip the software ns-xx.tar.gz
$] tar zxvf ns-allinone-2.35.tar.gz
$] cd ns-allinone-2.35/

Open the file
$] gedit ns-2.35/linkstate/ls.hin line number 137 change erase to this->erase as shown above.....
Save the file and give this command
$] ./install This will install all the packages as you see in the video. This process may be take upto 5 minutes.
Once installation is over now....

Setting the PATH
The following line is pasted in the PATH variable as shown in the video
$] gedit /home/pradeepkumar/.bash_profile

:/home/pradeepkumar/ns-allinone-2.35/bin:/home/pradeepkumar/ns-allinone-2.35/tcl8.5.10/unix:/home/pradeepkumar/ns-allinone-2.35/tk8.5.10/unixOnce the PATH is set, source the .bash_profile file as the new PATH will be reflected within the current terminal.
the command is
$] source /home/pradeepkumar/.bash_profile
now try
$ ns
$ nam
$ xgraph
to see whether the software is working or not.

 T S Pradeep Kumar

Popular posts from this blog

AWK Scripts for NS2 to process data from Trace Files


LEACH protocol installation in ns2 (ns-2.35)