LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 02-06-2012, 04:36 AM   #16
hassan329
LQ Newbie
 
Registered: Sep 2011
Posts: 18

Original Poster
Rep: Reputation: Disabled

Quote:
Originally Posted by numusz View Post
hey hassan329,,
need your help,
can you explain me , step by step to install zrp in ns-2.34 ??
I will help you.

First Step:
You have working ns-2.34.

Second Step:
Go to post No.6 to download ZRP patch.

Third Step:
Copy all file to ns folder

Fourth Step:
Do this
a) cd ns-allinone-2.34/ && patch -p1 < PatchZRP.patch
b) touch ns-2.34/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.34/ns-2.34 && make -k

If this not work then you have to do it manually which open the PatchZRP.patch in that file they have written which file u have modified and their line number.
After that make the ns again (this is command make -k)
 
Old 05-17-2012, 01:55 AM   #17
neha57
LQ Newbie
 
Registered: May 2012
Posts: 2

Rep: Reputation: Disabled
problem in zrp.tcl

hello sir,
your site is very helpful to new beginners. i have patched zrp successfully but when i execute it shows the following error:
invalid command name "Agent/ZRP"
while executing
"Agent/ZRP set radius_ 2 "(file "zrp1.tcl" line 68)

can u pls help me to sort out this problem...
thank u....
 
Old 05-17-2012, 04:26 AM   #18
neha57
LQ Newbie
 
Registered: May 2012
Posts: 2

Rep: Reputation: Disabled
problem in executing zrp

hello sir,
when i run zrp.tcl file in ns2.33 it shows the following error:
num_nodes is set 10
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_"


can u pls help me to sort out this problem...

Last edited by neha57; 05-17-2012 at 05:46 AM.
 
Old 08-17-2012, 05:22 AM   #19
ringqyl
LQ Newbie
 
Registered: Jul 2012
Posts: 2

Rep: Reputation: Disabled
Hi everyone!
I have problem when i run ZRP test tcl file.
Attached file is the tcl file.
Someone knows about it ?
Quote:
vmuser@~$ns test_zrp.tcl
num_nodes is set 25
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
INITIALIZE THE LIST xListHead
CO-ORD of Node 0=(20,20)
CO-ORD of Node 1=(160,20)
CO-ORD of Node 2=(300,20)
CO-ORD of Node 3=(440,20)
CO-ORD of Node 4=(580,20)
CO-ORD of Node 5=(20,160)
CO-ORD of Node 6=(160,160)
CO-ORD of Node 7=(300,160)
CO-ORD of Node 8=(440,160)
CO-ORD of Node 9=(580,160)
CO-ORD of Node 10=(20,300)
CO-ORD of Node 11=(160,300)
CO-ORD of Node 12=(300,300)
CO-ORD of Node 13=(440,300)
CO-ORD of Node 14=(580,300)
CO-ORD of Node 15=(20,440)
CO-ORD of Node 16=(160,440)
CO-ORD of Node 17=(300,440)
CO-ORD of Node 18=(440,440)
CO-ORD of Node 19=(580,440)
CO-ORD of Node 20=(20,580)
CO-ORD of Node 21=(160,580)
CO-ORD of Node 22=(300,580)
CO-ORD of Node 23=(440,580)
CO-ORD of Node 24=(580,580)
extra characters after close-quote
while executing
"$ns_ at $val(stop).0002 "puts /"NS EXITING.../";$ns_ halt"
puts $tracefd "M 0.0 nn $val(nn) x $val(x) y $val(y) rp $val(rp)"
puts $tracefd "M 0.0 prop..."
(file "test_zrp.tcl" line 65)
Thank you!
Attached Files
File Type: txt test_zrp.txt (2.3 KB, 115 views)

Last edited by ringqyl; 08-17-2012 at 05:39 AM.
 
Old 08-17-2012, 06:03 AM   #20
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Post #19, @ringqyl : Welcome to LQ.

Line 65
Quote:
"$ns_ at $val(stop).0002 "puts /"NS EXITING.../";$ns_ halt"
Edit to :
$ns_ at $val(stop).0002 "puts \"NS EXITING...\";$ns_ halt"

.
 
1 members found this post helpful.
Old 08-19-2012, 08:44 PM   #21
ringqyl
LQ Newbie
 
Registered: Jul 2012
Posts: 2

Rep: Reputation: Disabled
Yes,Thank you.
It can run now.
 
Old 09-05-2012, 02:45 AM   #22
helok
LQ Newbie
 
Registered: May 2012
Location: jakarta
Posts: 15

Rep: Reputation: Disabled
sir, I successfully instal the ZRP.
now where do i find example.tcl for ZRP?
thank you

Last edited by helok; 09-05-2012 at 03:35 AM.
 
Old 09-05-2012, 03:59 AM   #23
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Post # 22, @helok : Welcome to LQ.
Quote:
.. where do i find example.tcl for ZRP ?
Please click the attachment in post # 13 to download example-zrp.tcl
? May work ?

Another example here https://sites.google.com/site/securezrp/tclcode
( Google .. tcl script zrp .. )


Good luck.

.

Last edited by knudfl; 09-05-2012 at 04:04 AM.
 
Old 09-05-2012, 05:14 AM   #24
helok
LQ Newbie
 
Registered: May 2012
Location: jakarta
Posts: 15

Rep: Reputation: Disabled
Quote:
Originally Posted by neha57 View Post
hello sir,
your site is very helpful to new beginners. i have patched zrp successfully but when i execute it shows the following error:
invalid command name "Agent/ZRP"
while executing
"Agent/ZRP set radius_ 2 "(file "zrp1.tcl" line 68)

can u pls help me to sort out this problem...
thank u....
i got the same problem like this one, Sir.
i type the command ns example-zrp.tcl.txt
is that right sir?

thank you
 
Old 09-05-2012, 07:31 AM   #25
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 24
Quote:
I got the same problem like this one
? invalid command name "Agent/ZRP" ?
If you have no ZRP, then you didn't build zrp.
Like post #6 : It is assumed, that you have a working ns-allinone-2.33,
i.e. the './install' command was run with no errors.

Add d) : cd ns-allinone-2.33/ns-2.33 && mv ns ns233 && make clean && make -k
Reason for "ns233": Then you have a backup for "non zrp" tcl files.

You can download an Ubuntu 10.04 'ns' (ns233-zrp) that works, here ..
https://docs.google.com/open?id=0B7S...mVEai1OVk1PS1U
> zrp-bin-ns233-ubu1004_i386.tar.bz2 ( 1.9 MB ).
EDIT : Please look into post #28 for an Ubuntu .deb package.


About examples : Please use those from the old zrp package : zrp.tar.gz
http://sites.google.com/site/nsnamzrp/
> https://3b137281-a-62cb3a1a-s-sites....zrp/zrp.tar.gz
example.tcl is to be used together with the two included files example.scen, example.traffic

EDIT : example.tcl isn't working, please use example-zrp.tcl,
together with example.scen, example.traffic from zrp.tar.gz

.

Last edited by knudfl; 09-05-2012 at 05:12 PM.
 
Old 09-05-2012, 08:01 AM   #26
helok
LQ Newbie
 
Registered: May 2012
Location: jakarta
Posts: 15

Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post
# 24

? invalid command name "Agent/ZRP" ?
If you have no ZRP, then you didn't build zrp.
Like post #6 : It is assumed, that you have a working ns-allinone-2.33,
i.e. the './install' command was run with no errors.

Add d) : cd ns-allinone-2.33/ns-2.33 && mv ns ns233 && make clean && make -k
Reason for "ns233": Then you have a backup for "non zrp" tcl files.

You can download an Ubuntu 10.04 'ns' (ns233-zrp) that works, here ..
https://docs.google.com/open?id=0B7S...mVEai1OVk1PS1U
> zrp-bin-ns233-ubu1004_i386.tar.bz2 ( 1.9 MB ).


About examples : Please use those from the old zrp package : zrp.tar.gz
http://sites.google.com/site/nsnamzrp/
> https://3b137281-a-62cb3a1a-s-sites....zrp/zrp.tar.gz
example.tcl is to be used together with the two included files example.scen, example.traffic

EDIT : example.tcl isn't working, please use example-zrp.tcl

.
what should I do sir? I want to use ZRP as routing protocol
sir, please help me.
I don't know how to do, this is my first time using ubuntu.

i've already install ns 2.33 in ubuntu 10.04
and already download these

and already did this :
Quote:
Add d) : cd ns-allinone-2.33/ns-2.33 && mv ns ns233 && make clean && make -k

Last edited by helok; 09-05-2012 at 08:55 AM.
 
Old 09-05-2012, 11:40 AM   #27
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 26

The most common mistake is to add the patch in the wrong location.
( Ref. a) cd ns-allinone-2.33/ && patch -p1 < PatchZRP.patch )
And did you untar ns-allinone-2.33_ZRP.tar.gz in the folder with ns-allinone-2.33?
( Ref. c) in post # 6.)


.

Last edited by knudfl; 09-05-2012 at 11:56 AM.
 
Old 09-05-2012, 05:02 PM   #28
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
An Ubuntu ZRP package : zrp-ns-2.33-ubu1004_i386.deb ( 7.1 MB.)
EDIT : Replaced by zrp-ns-2.33-ubu1004-1_i386.deb
... can be downloaded here ..
https://docs.google.com/open?id=0B7S...TFyVEh3UXA0aFE

Please install with : sudo dpkg -i zrp-ns-2.33-ubu1004-1_i386.deb
Then you have : /usr/local/bin/ ns ns-zrp nam
( ns and ns-zrp are identical.)
The few required libraries etc. are in /usr/local/ns2/ns-allinone-2.33/.

With that package installed, you can type 'ns-zrp <file>' in any location,
to run zrp examples.

.

Last edited by knudfl; 09-06-2012 at 04:14 AM.
 
Old 09-05-2012, 08:26 PM   #29
helok
LQ Newbie
 
Registered: May 2012
Location: jakarta
Posts: 15

Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post
# 26

The most common mistake is to add the patch in the wrong location.
( Ref. a) cd ns-allinone-2.33/ && patch -p1 < PatchZRP.patch )
And did you untar ns-allinone-2.33_ZRP.tar.gz in the folder with ns-allinone-2.33?
( Ref. c) in post # 6.)
ref a) i did that patch like you said:
Quote:
jeffrey@jeffrey-laptop:~/ns-allinone-2.33$ patch -p1 < patchZRP.patch.txt
(Stripping trailing CRs from patch.)
patching file ns-2.33/common/packet.h
(Stripping trailing CRs from patch.)
patching file ns-2.33/Makefile
(Stripping trailing CRs from patch.)
patching file ns-2.33/tcl/lib/ns-agent.tcl
(Stripping trailing CRs from patch.)
patching file ns-2.33/tcl/lib/ns-default.tcl
(Stripping trailing CRs from patch.)
patching file ns-2.33/tcl/lib/ns-lib.tcl
(Stripping trailing CRs from patch.)
patching file ns-2.33/tcl/lib/ns-packet.tcl
(Stripping trailing CRs from patch.)
patching file ns-2.33/trace/cmu-trace.cc
(Stripping trailing CRs from patch.)
patching file ns-2.33/trace/cmu-trace.h

and
ref c) i untar the ns-allinone-2.33_ZRP.tar.gz inside ns-allinone-2.33 folder.


_________________________________________________________________________________

Quote:
Originally Posted by knudfl View Post
Please install with : sudo dpkg -i zrp-ns-2.33-ubu1004_i386.deb
Then you have : /usr/local/bin/ ns ns-zrp nam
( ns and ns-zrp are identical.)
The few required libraries etc. are in /usr/local/ns2/ns-allinone-2.33/.

With that package installed, you can type 'ns-zrp <file>' in any location,
to run zrp examples.
already did this. and i type 'ns-zrp example-zrp.tcl.txt' in terminal
this message show up:
Quote:
jeffrey@jeffrey-laptop:~/ns-allinone-2.33/ns-2.33/tcl/ex$ ns-zrp example-zrp.tcl.txt
application-specific initialization failed: Can't find a usable init.tcl in the following directories:
/usr/local/ns2/ns-allinone-2.33/lib/tcl8.4 /usr/local/lib/tcl8.4 /usr/lib/tcl8.4 /usr/local/library /usr/library /usr/tcl8.4.18/library /tcl8.4.18/library /usr/local/ns2/ns-allinone-2.33/lib/tcl8.4



This probably means that Tcl wasn't installed properly.

invalid command name "Agent/ZRP"
while executing
"Agent/ZRP set radius_ 2 "
(file "example-zrp.tcl.txt" line 68)
maybe i should reinstall ns-allinone-2.33 Sir? and also reinstall the zrp patch ?
 
Old 09-06-2012, 04:12 AM   #30
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 29
Quote:
Can't find a usable init.tcl in ... /usr/local/ns2 ..
Well, when I installed the package for the third time,
( on the third tested Ubuntu OS ) the error appeared.

A quick fix : 1) cd /usr/local/
2) sudo chmod -R 0755 ns2/


A new package with the right permissions : zrp-ns-2.33-ubu1004-1_i386.deb
> https://docs.google.com/open?id=0B7S...TFyVEh3UXA0aFE

.
 
  


Reply

Tags
ns2, setdest, zrp, zrp#2


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
How to patch GPSR routing protocol to ns-2.34 nimacasino Linux - Software 287 06-10-2014 12:27 PM
LXer: Tutorial: Border Gateway Protocol, The Routing Protocol of the Internet LXer Syndicated Linux News 0 11-13-2008 05:11 AM
Time Zone patch diskoe Slackware 41 03-13-2007 12:52 PM

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

All times are GMT -5. The time now is 07:00 AM.

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