To install NS-2 in FEDORA 10 i have followed the instructions from this url:

Step 1:
Make sure your computer is connected to the internet and Please log in as a superuser so that you have permission to do as follow.
At the terminal please type the following to install the packages dependencies:
yum install autoconf
yum install automake
yum install gcc-c++
yum install libX11-devel
yum install xorg-x11-proto-devel
yum install libXt-devel
yum install libXmu-devel

Step 2:
Download NS-allinone-2.33 package from and do as follow at directory of your choice.
At home directory extract the ns file:
# tar -xzf ns-allinone-2.33.tar.gz
Proceed by entering to the ns directory:
# cd ns-allinone-2.33
# ./install

Step 3:
After Step 2, still at the terminal type:
# vi /root/.bashrc
To insert text please press the “i” key then add the following lines to the ./bashrc




Remark: Press the “Esc” key follow by the “:”(shift+;) key then type the letters “wq” to write and quite from the terminal.

Let the environment variable that you set take effect immediately by typing the following at the terminal:
# source ~/.bashrc
you can choose to restart your computer

Step 4:
The NS should be working by now by typing:
$ ns
the symbol “%” should appear, press ctrl+c to exit from it.

Step 5:
The following error occur when i type “nam” at the terminal:


: no event type or button # or keysym
while executing
"bind Listbox {
%W yview scroll [expr {- (%D / 120) * 4}] units
invoked from within
"if {[tk windowingsystem] eq "classic" [tk windowingsystem] eq "aqua"} {
bind Listbox {
%W yview scroll [expr {- (%D)}] units
bind Li..."

I found the solution at the following url:

1. Download tk-8.4.18-tkBind.patch from
2. Put the patch file in the ns-allinone-2.33 directory and patch it:
patch -p0 < tk-8.4.18-tkBind.patch
3. after this step please type ./install again at the NS directory

After this when you type "nam" at the terminal you shall see the nam GUI.

Step 6
Validate the NS by typing:
# ./validate

Step 7
Start by looking at the example provided by NS in the ex folder:
# cd /home/username/ns-allinone-2.33/ns-2.33/tcl/ex
# ns wireless-flodding.tcl

Feel free to explore your newly install NS-2.