Wednesday 28 August 2013

hi dear friends today am going to show how to install ns2.34  in cent os
on before that you need to install the following packages 
                            yum install autoconf 
                            yum install automake
                            yum install gcc-c++
                            yum install libX11-devel
                            yum install libX-devel
                            yum install libXt-devel
                            yum install libXmu-devel
                       yum install xorg-x11-proto-deve
                                    finally 
                             yum update audit  

step 1:
       first download ns2.34 in
       http://sourceforge.net/projects/nsnam/files/allinone/ns-allinone-2.34/
step2:
      go to the downloaded location just click ns2.34 and right click extract here 
                                                  or else  
      go to the terminal just type the following command 
       
                    tar -zxvf ns-allinone-2.34.tar.gz
step3:
         go to the folder location where you extract the ns2.34 allinone package 
in my side i extract in desktop 
       just  type in the terminal cd ns-allinone-2.34
in this folder you see the one install file 




 now type in ./install in the terminal



now it will take 5 to 10 minutes to install  depends upon the your cpu speed
after a long time you see the important notice in terminal window 



 step 5:
now open a new terminal and type gedit .bashrc a new window will open. under the # .bashrc

 export PATH=/root/Desktop/ns-allinone-2.34/bin:/root/Desktop/ns-allinone-2.34/tcl8.4.18/unix:/root/Desktop/ns-allinone-2.34/tk8.4.18/unix:$PATH
export LD_LIBRARY_PATH=/root/Desktop/ns-allinone-2.34/otcl-1.13:/root/Desktop

/ns-allinone-2.34/lib
export TCL_LIBRARY=/root/Desktop/ns-allinone-2.34/tcl8.4.18/library
export TK_LIBRARY=/root/Desktop/ns-allinone-2.34/tcl8.4.18/library 


just copy and paste  

 with out any space and save then close the window
now type the source ~/.bashrc

You can check what is written in your path by writing

 echo $PATH 
echo $TCL_LIBRARY 
echo $LD_LIBRARY_PATH
echo $TK_LIBRARY



Now, the installation has been completed



type the nam command in terminal  the nam window will open



 there is lot example program in cd  ns-allinone-2.34/ns-2.34/tcl/ex

here i excute a simple program