LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 01-14-2014, 01:38 AM   #1
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Rep: Reputation: Disabled
How to install NS


i am tried install ns 2.33 in 12.04 and had some prob.
which ns i can install for zrp(patch)?
because i am tried 2.33 for some linux
problem repository linux is outdated, i cant install ns 2.33
my objective is NS with zrp patch
please help me.
thanks
 
Old 01-14-2014, 04:06 AM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Please start reading all http://www.linuxquestions.org/questions/tags/zrp/

Get the examples, zrp-examples-2012.tar.bz2
https://docs.google.com/file/d/0B7S2...it?usp=sharing

And install the Ubuntu zrp package, zrp-ns-2.33-ubu1010_i386.deb
https://docs.google.com/file/d/0B7S2...it?usp=sharing
.. with $ sudo dpkg -i zrp-ns-2.33-ubu1010_i386.deb
.. or click the package, and use your 'Package Installer'.
.. Then you can run all the examples with : $ ns-zrp <file>.tcl


If you want to build your own zrp version, it's "ns-allinone-2.33" :
Install the compilers, ref. post # 18 here :
http://www.linuxquestions.org/questi...022/page2.html
*** Be aware that the compilers are for a 32bits (i686) Ubuntu 12.04 only.
*** ( A 64bits OS (x86_64) is not good with ns2 ).
ZRP : a) $ cd ns-allinone-2.33/ && export CC=gcc41 CXX=g++41 && ./install

b) #6 http://www.linuxquestions.org/questi...34-a-905025/#6
.. where line 37 in the Makefile must be edited to : CPP = g++41

-

Last edited by knudfl; 01-14-2014 at 05:53 AM.
 
1 members found this post helpful.
Old 01-14-2014, 10:00 AM   #3
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
sir knudfl, excuse me may you help me about how can i install ZRP package for ubuntu which you posted.
zrp-ns-2.33-ubu1010_i386.deb do i have to install ubuntu version 10.10 only?
how about ubuntu 12.04? its alright?
thanks sir.

Last edited by japfendy; 01-14-2014 at 11:19 AM.
 
Old 01-15-2014, 03:21 AM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 3 .

Ref. post #2 : You can install zrp-ns-2.33-ubu1010_i386.deb into Ubuntu 12.04.
If the OS shows `i686' with the command $ uname -m

The package works equally well, all Ubuntu 10.04 ... 13.**


-
 
Old 01-21-2014, 03:13 AM   #5
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post
# 3 .

Ref. post #2 : You can install zrp-ns-2.33-ubu1010_i386.deb into Ubuntu 12.04.
If the OS shows `i686' with the command $ uname -m

The package works equally well, all Ubuntu 10.04 ... 13.**


-
sir, im trying instal ns 2.33 for ubuntu 12.04 i got this error


* Build tcl8.4.18
============================================================
configure: WARNING: unrecognized options: --enable-gcc
checking whether to use symlinks for manpages... no
checking whether to compress the manpages... no
checking whether to add a package name suffix for the manpages... no
checking for gcc... gcc41
checking whether the C compiler works... no
configure: error: in `/home/jap/ns-allinone-2.33/tcl8.4.18/unix':
configure: error: C compiler cannot create executables
See `config.log' for more details
tcl8.4.18 configuration failed! Exiting ...
Tcl is not part of the ns project. Please see www.Scriptics.com
to see if they have a fix for your platform.


im already instal gcc 4.1.2 for zrp patch or i install zrp package but still wont work
please help me

Last edited by japfendy; 01-21-2014 at 05:14 AM.
 
Old 01-21-2014, 09:58 AM   #6
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Please put /home/jap/ns-allinone-2.33/bin:/home/jap/ns-allinone-2.33/tcl8.4.18/unix:/home/jap/ns-allinone-2.33/tk8.4.18/unix
into your PATH environment; so that you'll be able to run itm/tclsh/wish/xgraph.

IMPORTANT NOTICES:

(1) You MUST put /home/jap/ns-allinone-2.33/otcl-1.13, /home/jap/ns-allinone-2.33/lib,
into your LD_LIBRARY_PATH environment variable.
If it complains about X libraries, add path to your X libraries
into LD_LIBRARY_PATH.
If you are using csh, you can set it like:
setenv LD_LIBRARY_PATH <paths>
If you are using sh, you can set it like:
export LD_LIBRARY_PATH=<paths>

(2) You MUST put /home/jap/ns-allinone-2.33/tcl8.4.18/library into your TCL_LIBRARY environmental
variable. Otherwise ns/nam will complain during startup.


After these steps, you can now run the ns validation suite with
cd ns-2.33; ./validate

For trouble shooting, please first read ns problems page
http://www.isi.edu/nsnam/ns/ns-problems.html. Also search the ns mailing list archive
for related posts.

im guess ns 2.33 already Installed,

error when sudo gedit ~/.bashrc


# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples


i am already install $ sudo dpkg -i zrp-ns-2.33-ubu1010_i386.deb
and im trying to run your example but

jap@jap-GA-MA770T-UD3P:~$ cd zrp-examples
jap@jap-GA-MA770T-UD3P:~/zrp-examples$ ns-zrp example.tcl
num_nodes is set 20
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
ns: Agent/ZRP set radius_: can't read "radius_": no such variable
(Object set line 1)
invoked from within
"Agent/ZRP set radius_"

please help me sir

Last edited by japfendy; 01-22-2014 at 04:32 PM.
 
Old 01-22-2014, 06:01 AM   #7
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 6 .
First : Please edit post #6 to use code tags for all the quoted (wrong) instructions.
And also use 'code tags' for your "error output". Edit, please.
Code tags : That's the " # " button in the 'Advanced Editor'.
http://www.linuxquestions.org/questi....php?do=bbcode
http://www.linuxquestions.org/questi...gs-4175464257/



Quote:
Please put /home/jap/ns-allinone-2.33/bin:/home/jap/ns-allinone-...
into your PATH environment
.
You MUST put /home/jap/ns-allinone-2.33/otcl-1.13, /home/jap/ns-allinone-2.33/lib,
into your LD_LIBRARY_PATH environment variable.
No PATH* settings are required. That's a "University thing".
Never add anything to .bashrc, when it is your own computer.
This will do : $ cd ns-allinone-2.33/ns-2.33/ && sudo make install
.. I.e. 'make install' will copy 'ns' to /usr/local/bin/



Quote:
jap@jap-GA-MA770T-UD3P:~/zrp-examples$ ns-zrp example.tcl
.
ns: Agent/ZRP set radius_: can't read "radius_": no such variable
You have chosen the only example that doesn't work.
! Use zrp-examples-2012.tar.bz2 : Please read post #2.!
! And all this http://www.linuxquestions.org/questions/tags/zrp/
I.e. example.tcl was edited to example-zrp.tcl


-

Last edited by knudfl; 01-22-2014 at 06:11 AM.
 
Old 01-22-2014, 04:54 PM   #8
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post
# 6 .
First : Please edit post #6 to use code tags for all the quoted (wrong) instructions.
And also use 'code tags' for your "error output". Edit, please.
Code tags : That's the " # " button in the 'Advanced Editor'.
http://www.linuxquestions.org/questi....php?do=bbcode
http://www.linuxquestions.org/questi...gs-4175464257/



No PATH* settings are required. That's a "University thing".
Never add anything to .bashrc, when it is your own computer.
This will do : $ cd ns-allinone-2.33/ns-2.33/ && sudo make install
.. I.e. 'make install' will copy 'ns' to /usr/local/bin/




You have chosen the only example that doesn't work.
! Use zrp-examples-2012.tar.bz2 : Please read post #2.!
! And all this http://www.linuxquestions.org/questions/tags/zrp/
I.e. example.tcl was edited to example-zrp.tcl


-
ok, sorry
sir, ns already in user local bin.

im run your example, but same following errors

jap@jap-GA-MA770T-UD3P:~$ cd zrp-examples
jap@jap-GA-MA770T-UD3P:~/zrp-examples$ dir
example.jpg example.traffic zrp_9.tcl
example.scen example-zrp.tcl zrp-Demo1-1.tcl
example.tcl test_zrp.tcl zrp-Demo2-1.tcl
jap@jap-GA-MA770T-UD3P:~/zrp-examples$ ns-zrp example.tcl
num_nodes is set 20
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
ns: Agent/ZRP set radius_: can't read "radius_": no such variable
(Object set line 1)
invoked from within
"Agent/ZRP set radius_

my steps installation

1.install gcc 4.1.2, gcc for zrp patch
2.export CC=gcc-4.1 CXX=g++-4.1 && ./install
3.tar -xvf ns-allinone-2.33.tar.gz
4.cd ns-allinone-2.33.
5.sudo ./install
(edited bashrc, error when sudo gedit ~/.bashrc

# ~/.bashrc: executed by bash(1) for non-login shells.

6.$ sudo dpkg -i zrp-ns-2.33-ubu1010_i386.deb (zrp patch)
7.$ cd ns-allinone-2.33/ns-2.33/ && sudo make install (your recent intruction)

whats wrong sir? please help
i need patch zrp
i am trying to performance comparison AODV and ZRP.

Last edited by japfendy; 01-22-2014 at 05:38 PM.
 
Old 01-22-2014, 06:42 PM   #9
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 8 .
Quote:
$ ns-zrp example.tcl
.
ns: Agent/ZRP set radius_: can't read "radius_": no such variable
Repeat Repeat : You have chosen the only example that doesn't work : Post #7.
"example.tcl" is included only for historical reason. Not usable as is.
Read the files example.tcl and example-zrp.tcl, to know the difference.
You can see the editing here http://www.linuxquestions.org/questions/tags/zrp/


Quote:
(edited bashrc, error when sudo gedit ~/.bashrc
Not required. See post #7.


Quote:
# ~/.bashrc: executed by bash(1) for non-login shells.
Also not required. And : No ns2 / zrp commands are to be done as root !


Quote:
5.sudo ./install
Wrong : Do not use 'sudo' for the build command.


Quote:
6.$ sudo dpkg -i zrp-ns-2.33-ubu1010_i386.deb (zrp patch)
That's not a patch. The .deb package is a complete build of ns2 / zrp :
I.e. you don't have to build anything ns-allinone / zrp,
when the package is installed → →
Using the package executable, example : $ ns-zrp example-zrp
.. Which you'd know after reading http://www.linuxquestions.org/questions/tags/zrp/

-
 
Old 01-27-2014, 07:05 AM   #10
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
oh i see.
sir knudfl, i follow your installation instruction


#5 : http://magnet.daiict.ac.in/magnet_me...n.html#Sec_1.2

http://magnet.daiict.ac.in/magnet_me....33_ZRP.tar.gz
http://magnet.daiict.ac.in/magnet_me...PatchZRP.patch
http://magnet.daiict.ac.in/magnet_me.../patchmyZRP.sh

It is assumed, that you have a working ns-allinone-2.33,
i.e. the './install' command was run with no errors.

""Section 3.2 Instructions :
1. First put following files into NS-2 home's parent directory:
* ns-allinone-2.33_ZRP.tar.gz (This contains my code)
* PatchZRP.patch
* patchmyZRP.sh (THIS SHELL-SCRIPT FILE -
This script file should be run from NS-2 home' parent directory)
2. Run patchZRP.sh from shell."" ( Like 'sh patchZRP.sh' ).
.....

But the script patchZRP.sh isn't working, easier to do manually :
a) cd ns-allinone-2.33/ && patch -p1 < PatchZRP.patch
b) touch ns-2.33/common/packet.h && touch ns-2.33/trace/cmu-trace.h
c) cd ../ && tar xvf ns-allinone-2.33_ZRP.tar.gz
d) cd ns-allinone-2.33/ns-2.33 && make -k

step D i got this

for i in indep-utils/cmu-scen-gen/setdest indep-utils/webtrace-conv/dec indep-utils/webtrace-conv/epa indep-utils/webtrace-conv/nlanr indep-utils/webtrace-conv/ucb; do ( cd $i; make all; ) done
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/jap/BLA/ns-allinone-2.33/ns-2.33/indep-utils/cmu-scen-gen/setdest'
make[1]: Entering directory `/home/jap/BLA/ns-allinone-2.33/ns-2.33/indep-utils/webtrace-conv/dec'

sir, whats wrong?

im trying to excute example but

invalid command name "Agent/ZRP"
while executing
"Agent/ZRP set radius_ 2 "
(file "example-zrpp.tcl" line 68)

its about compiler?

ty sir

Last edited by japfendy; 01-27-2014 at 07:57 AM.
 
Old 01-27-2014, 09:01 AM   #11
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 10 .
Quote:
Nothing to be done for `all'.
.
.. .. whats wrong?
What do you mean ?
Nothing to be done for `all' :
Is the normal reply from 'make', when you do 'make' the second time, etc.


Quote:
invalid command name "Agent/ZRP"
You are using an executable 'ns' with no ZRP !
a) May be you have more than one "ns" ?
Rename the zrp ns to 'ns-zrp' : $ ns-zrp example-zrp.tcl
b) Or you could have a failed build.

P.S. : ? Why are are quoting the text that has the comment : "Do not do this" ?
Quote:
Section 3.2 Instructions : (( Do not use this instruction ))
Code:
1. First put following files into NS-2 home's parent directory:
* ns-allinone-2.33_ZRP.tar.gz (This contains my code)
* PatchZRP.patch
* patchmyZRP.sh (THIS SHELL-SCRIPT FILE -
This script file should be run from NS-2 home' parent directory)
2. Run patchZRP.sh from shell.
(( Do not use this instruction ))
If you used this, you will have to start from scratch, I guess.


-

Last edited by knudfl; 01-27-2014 at 09:02 AM.
 
Old 01-28-2014, 05:33 AM   #12
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post
# 10 .

What do you mean ?
Nothing to be done for `all' :
Is the normal reply from 'make', when you do 'make' the second time, etc.



You are using an executable 'ns' with no ZRP !
a) May be you have more than one "ns" ?
Rename the zrp ns to 'ns-zrp' : $ ns-zrp example-zrp.tcl
b) Or you could have a failed build.

P.S. : ? Why are are quoting the text that has the comment : "Do not do this" ?

If you used this, you will have to start from scratch, I guess.


-
sir knudfl, i delete all my ns 2.

i am trying to repeat the installation
1.First put following files into NS-2 home's parent directory:
* ns-allinone-2.33_ZRP.tar.gz (This contains my code)
* PatchZRP.patch
* patchmyZRP.sh (THIS SHELL-SCRIPT FILE )

2. do
a) cd ns-allinone-2.33/ && patch -p1 < PatchZRP.patch
b) touch ns-2.33/common/packet.h && touch ns-2.33/trace/cmu-trace.h
c) cd ../ && tar xvf ns-allinone-2.33_ZRP.tar.gz
d) cd ns-allinone-2.33/ns-2.33 && make -k


3. run examples
but still

jap@jap-GA-MA770T-UD3P:~/zrp-examples$ ns example-zrp.tcl
invalid command name "Agent/ZRP"
while executing
"Agent/ZRP set radius_ 2 "
(file "example-zrp.tcl" line 68)


ap@jap-GA-MA770T-UD3P:~/zrp-examples$ ns zrp-Demo1-1.tcl
invalid command name "Agent/ZRP"
while executing
"Agent/ZRP set radius_ 2 "
(file "zrp-Demo1-1.tcl" line 17)

jap@jap-GA-MA770T-UD3P:~/zrp-examples$ ns zrp-Demo2-1.tcl
invalid command name "Agent/ZRP"
while executing
"Agent/ZRP set radius_ 2 "
(file "zrp-Demo2-1.tcl" line 17)

please help me to solve this
ty
 
Old 01-28-2014, 05:47 AM   #13
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 12 .

Ubuntu 12.04 : Is it 32bits (i686) ?
Please show the output from the command $ uname -m <Enter>


Are you sure that the right compiler is used ?
Ref. post #2 :
" .. line 37 in the Makefile must be edited to : CPP = g++41 "
I.e. a `g++ version 4.1.2' must be used.

-
 
Old 01-28-2014, 06:13 AM   #14
japfendy
LQ Newbie
 
Registered: Jan 2014
Posts: 16

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post
# 12 .

Ubuntu 12.04 : Is it 32bits (i686) ?
Please show the output from the command $ uname -m <Enter>


Are you sure that the right compiler is used ?
Ref. post #2 :
" .. line 37 in the Makefile must be edited to : CPP = g++41 "
I.e. a `g++ version 4.1.2' must be used.

-
sir knudfl, here is

jap@jap-GA-MA770T-UD3P:~$ uname -m
i686

$ sudo dpkg -i zrp-ns-2.33-ubu1010_i386.deb

already did

what make file?
 
Old 01-28-2014, 06:44 AM   #15
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 14 .
Quote:
what make file ?
There is one Makefile only in the directory, where you so $ make -k
... that's ns-allinone-2.33/ns-2.33/Makefile


Compilers :
Please install "gcc41-compat-4.1.2.ubu1204_i386.deb g++41-compat-4.1.2_i386.deb",
ref. post #18 here ..
http://www.linuxquestions.org/questi...022/page2.html

-
 
  


Reply

Tags
ns2, zrp



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] [RHL 6.2] Fresh install. XWindows Server didn't install. Can I install it manually? Patriot2135 Red Hat 9 11-19-2013 12:37 AM
Install packages from Fedora LiveCD usb key without internet access (from install) MissMetal Linux - Newbie 1 02-05-2013 07:59 AM
yum install lib getting fails yum install lib* leads to install 1050 dependency pkg LittleMaster Linux - Server 3 10-29-2012 01:14 AM
Open Office will not install on factory install of Ubuntu 8.04 LTS on Dell Mini 10 trekgirl Linux - Laptop and Netbook 6 08-01-2009 11:37 PM
Ubuntu as frugal install, iso install, img install? impossible? nooby Ubuntu 15 08-22-2008 05:49 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 07:30 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration