Error on Installation ns-allinone-2.28 in Ubuntu

286 views
Skip to first unread message

Avatar

unread,
Feb 27, 2009, 5:29:10 AM2/27/09
to Network Simulator 2 (NS2)
I am having most of the error no matter in the windows and Ubuntu.
While I am installing I am getting the tcl8.3.2 configuration failed
and ask me to see www.scriptics.com.
I already spent more than 1 months to settle this tcl but still fail.
Can anyone tell me how to solve this?

Ashwini Patankar

unread,
Feb 27, 2009, 5:48:20 AM2/27/09
to ns-u...@googlegroups.com

hi there,

check this out


 
Aug 27, 2006
Howto install ns-2 allinone onto Ubuntu linux
This HOWTO covers installation on Ubuntu Linux.

Get the allinone source.

$ cd ~lucsp
$ wget http://www.isi.edu/nsnam/dist/ns-allinone-2.28.tar.gz

Modify build for GDB debugger.

$ tar xzf ns-allinone-2.28.tar.gz
$ cd ns-allinone-2.28
$ vim install

Add the --enable-synbols option on line 408 so, ./configure --enable-gcc --disable-shared --prefix=$CUR_PATH || die "tcl8.3.2 configuration failed! Exiting ..." becomes,
./configure –-enable-symbols --enable-gcc --disable-shared --prefix=$CUR_PATH || die "tcl8.3.2 configuration failed! Exiting ..."

Add the –enable-debug option to line 498 so,
./configure || die "tclcl-$TCLCLVER configuration failed! Exiting ..."
becomes,
./configure -–enable-debug || die "tclcl-$TCLCLVER configuration failed! Exiting ..."

$ cd ns-2.28
$ vim Makefile.in

Add the -g option to line 82 so,
CFLAGS = $(CCOPT) $(DEFINE)
becomes,
CFLAGS = -g $(CCOPT) $(DEFINE)

X11/Intrinsic.h is required by otcl1-9 but is not in libx11-dev but is in libxt-dev.

$ sudo apt-get install -f libxt-dev libxt6 libsm-dev libsm6 libice-dev libice6

/usr/X11R6/include/X11/Xmu/WinUtil.h is required by nam-1.1.

$ sudo apt-get install libxmu-dev

xgraph Makefile requires modification.

$ cd ../xgraph-12.1
$ ./configure
$ vim Makefile

Add -L/usr/X11R6/lib on line 85 so,

xgraph_LDADD = $(ADDITIONAL_LIBS) $(X_LIBS) $(X_PRE_LIBS) $(X_EXTRA_LIBS) -lX11 -lm becomes,
xgraph_LDADD = $(ADDITIONAL_LIBS) $(X_LIBS) $(X_PRE_LIBS) $(X_EXTRA_LIBS) -L/usr/X11R6/lib -lX11 -lm

gt-itm requires a bin dir to be created.

$ cd ../gt-itm
$ mkdir bin
$ cd src
$ make

gt-itm and sgb2ns require sgb.

$ sudo apt-get sgb

gt-itm and sgb2ns require libgb.a to be at /home/lucsp/ns-allinone-2.28/gt-itm/lib.

$ mkdir lib
$ sudo ln -s usr/lib/libgb.a /home/lucsp/ns-allinone-2.28/gt-itm/lib

Fix pedantic gcc 3.3.5

$ cd src
$ vim eval.c

On line 162, the printf function argument must be on a single line.
printf(" and %d (this ends a connected component of the graph)\n", idx(g, artic_pt));

Compile NS-2.28.

$ cd ..
$ ./install &> compile.out

Environmental variables.

$ vim NS2.sh

#!/bin/sh

# LD_LIBRARY_PATH
OTCL_LIB=/home/lucsp/ns-allinone-2.28/otcl-1.9
NS2_LIB=/home/lucsp/ns-allinone-2.28/lib
X11_LIB=/usr/X11R6/lib
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OTCL_LIB:$NS2_LIB:$X11_LIB:/usr/local/lib

# TCL_LIBRARY
export TCL_LIBRARY=/home/lucsp/ns-allinone-2.28/tcl8.4.5/library:/usr/lib

# PATH
XGRAPH=/home/lucsp/ns-allinone-2.28/bin:/home/lucsp/ns-allinone-2.28/tcl8.4.5/unix:/home/lucsp/ns-allinone-2.28/tk8.4.5/unix
PATH=$PATH:$XGRAPH:/home/lucsp/ns-allinone-2.28/ns-2.28/
**source

tags : install ns-2 network simulator onto ubuntu linux

at 1:35 AM

Labels: install, linux, ubuntu

1 comments:

Anonymous said...
I was having similar problems with the ns 2.31 build too. 
But after installing the xlibs-dev , things worked like magic and it successfully compiled.
=======================================================

link : http://ns-2.blogspot.com/2006/08/howto-install-ns-2-allinone-onto.html

============================================

Thanks & Regards,

Er. Ashwini Shankar Patankar
www.wirelesscafe.co.nr

Avatar

unread,
Feb 27, 2009, 7:39:54 AM2/27/09
to Network Simulator 2 (NS2)
Add the --enable-synbols option on line 408 so, ./configure --enable-
gcc
--disable-shared --prefix=$CUR_PATH || die "tcl8.3.2 configuration
failed!
Exiting ..." becomes,
./configure –-enable-symbols --enable-gcc --disable-shared
--prefix=$CUR_PATH || die "tcl8.3.2 configuration failed!
Exiting ..."

Actually I don't really understand with the top.
Is it I need to type : ./configure --enable-gcc
--disable-shared --prefix=$CUR_PATH || die "tcl8.3.2 configuration
failed!
or open some file on line 408??

Ashwini Patankar

unread,
Feb 27, 2009, 8:13:31 AM2/27/09
to ns-u...@googlegroups.com

i usually work on fedora, but as far as your problem is concerned try this blog or steps

==========================================

blog link : http://yewail.blogspot.com/2008/12/installing-ns2-in-ubuntu-804.html

===============================================

System: IBM R61 laptop
OS: Ubuntu 8.04
Install version: 2.29.3
Purpose: Setup a networking analysis development environment

Process:
Install the essential packages for NS2. Use the command below:
# sudo apt-get install build-essential
# sudo apt-get install tcl8.4 tcl8.4-dev tk8.4 tk8.4-dev
# sduo apt-get install libxmu-dev libxmu-headers
Download the NS2 software in SourceForge, then tar -xzf this file.
Change to the folder, then type "./install" (It may costs few minutes.)
If success, the terminal will show a long message. It means that you have to add the path in ./bashrc.
Edit ./bashrc in home folder. Add the commands below: (This code may different with the version of software you installed, and the user name.)
# added line below for NS2 (Dec.14 2008)
export PATH="$PATH:/home/yewail/ns-allinone-2.29/bin:/home/yewail/ns-allinone-2.29/tcl8.4.11/unix:/home/yewail/ns-allinone-2.29/tk8.4.11/unix"
export TCL_LIBRARY="$TCL_LIBRARY:/home/yewail/ns-allinone-2.29/tcl8.4.11/library"
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/home/yewail/ns-allinone-2.29/otcl-1.11:/home/yewail/ns-allinone-2.29/lib"
Now, type "source ~/.bashrc" to reload the bash path.
In the official solution, you should type "./validate"(in the folder of ns-X.xx) to confirm the install is correct or not. (It will take a long long time to run, I did it about 30 mins.) My conclusion is below:

All test output agrees with reference output.
Sun Dec 14 23:18:14 CST 2008
These messages are NOT errors and can be ignored:
warning: using backward compatibility mode
This test is not implemented in backward compatibility mode


validate overall report: some tests failed:
./test-all-red
to re-run a specific test, cd tcl/test; ./test-all-TEST-NAME
Notice that some tests in webcache will fail on freebsd when -O is turned on.
This is due to some event reordering, which will disappear when -g is turned on.

Even though it said it have a failed in ./test-all-red, but it also said I can ignore that. So I left this error unsolved.
Now, you can start to use NS2.

Thanks & Regards,


Er. Ashwini Shankar Patankar
www.wirelesscafe.co.nr


Avatar

unread,
Feb 27, 2009, 8:21:15 AM2/27/09
to Network Simulator 2 (NS2)
I am getting some error on the
sudo apt-get sgb
it shows me invalid operation sgb
Reply all
Reply to author
Forward
0 new messages