0% found this document useful (0 votes)
67 views3 pages

Installing ns2.34 On Ubuntu 9.10 (32 Bit) : 2.34.tar - Gz/download or From Any Where Else

The document provides instructions for installing ns2 network simulator on Ubuntu 9.10 (32-bit). It involves downloading the ns2 files, extracting and copying them to the desired location, installing dependencies through apt-get, configuring environment variables in .bashrc to reference ns2 paths, running the installer and validator scripts, creating a symlink to call ns2 from any location, and rebooting. Upon reboot, running the 'ns' command should start the ns2 shell if installed successfully.

Uploaded by

gzeekhan
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
67 views3 pages

Installing ns2.34 On Ubuntu 9.10 (32 Bit) : 2.34.tar - Gz/download or From Any Where Else

The document provides instructions for installing ns2 network simulator on Ubuntu 9.10 (32-bit). It involves downloading the ns2 files, extracting and copying them to the desired location, installing dependencies through apt-get, configuring environment variables in .bashrc to reference ns2 paths, running the installer and validator scripts, creating a symlink to call ns2 from any location, and rebooting. Upon reboot, running the 'ns' command should start the ns2 shell if installed successfully.

Uploaded by

gzeekhan
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Installing ns2.34 on Ubuntu 9.

10 (32 bit)
(1) Download ns2.34 http://sourceforge.net/projects/nsnam/files/allinone/ns-allinone-2.34/ns-allinone2.34.tar.gz/download or from any where else. (2) Unzip the ns-allinone-2.34.tar.gz to any place where you want to install your ns. In my case I want to unzip it in /home/gz/ (note that my zipped folder of ns2 was in /home/gz) $ cd /home/gz $ tar -xzvf ns-allinone-2.34.tar.gz (3) $cd ns-allinone-2.34 (4) $sudo apt-get install build-essential autoconf automake libxmudev (5) $./install Errors: It will take some time. After this step you may encounter some errors like the following snapshot gcc-4.3: command not found make: *** [libotcl.so] Error 1 otcl-1.13 make failed! Exiting ...

If you get the errors as above, follow the steps from 5.1 to 5.6, otherwise go to step (6) 5.1 $gedit otcl-1.13/Makefile.in 5.2 edit the file as follows: old file snapshot

new file

5.3 $sudo apt-get install g++-4.3 5.4 $cd ns-allinone-2.34 5.5 ns-allinone-2.34$CC=gcc-4.3 CXX=g++-4.3 ./install 5.6 You are done if you get the following screen

(6) $ gedit ~/.bashrc It will open the file shown below. Edit the lines that are highlighted according to your path of ns2. I installed my ns2 in /home/gz/ns-allinone-2.34 # LD_LIBRARY_PATH OTCL_LIB=/home/gz/ns-allinone-2.34/otcl-1.13 NS2_LIB=/home/gz/ns-allinone-2.34/lib X11_LIB=/usr/X11R6/lib USR_LOCAL_LIB=/usr/local/lib export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OTCL_LIB:$NS2_LIB: $X11_LIB:$USR_LOCAL_LIB # TCL_LIBRARY TCL_LIB=/home/gz/ns-allinone-2.34/tcl8.4.18/library USR_LIB=/usr/lib export TCL_LIBRARY=$TCL_LIB:$USR_LIB # PATH XGRAPH=/home/gz/ns-allinone-2.34/bin:/home/gz/Downloads/ns-allinone-

2.34/tcl8.4.18/unix:/home/gz/ns-allinone-2.34/tk8.4.18/unix NS=/home/gz/ns-allinone-2.34/ns-2.34/ NAM=/home/gz/ns-allinone-2.34/nam-1.14/ PATH=$PATH:$XGRAPH:$NS:$NAM (7) $ source ~/.bashrc (8) $cd ns2.34 (9) $./validate It will take long time to finish(longer than the install) If you get this screen shot, you are successful.

(10) Create a symlink, so that ns can be called from everywhere $ sudo ln -s /home/gz/ns-allinone-2.33/ns-2.33/ns /usr/bin/ns (11) $reboot To restart the system. (12) To check whether ns is installed successfully or not, test it by entering $ns. If you are prompted with %, it means your installation is successful otherwise check your environment variables, specifically compare the versions of otcl, nam etc in ./bashrc with those in your ns-allinone-2.34. press exit to go back from %.

You might also like