LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-30-2015, 03:54 AM   #976
amita_s12
LQ Newbie
 
Registered: Feb 2015
Posts: 29

Rep: Reputation: Disabled
error in Leach simulation


hi,
haitm

i have successfully simulated Leach on Mannasim integrated with NS-2.35. now i m trying to do some variations in leach. i have selected NO. of nodes =100, scenario size= 1000X1000 , Simulation time =500s
but it is giving error

Error!!
str2addr:Address 1634300513 outside range of address field length 1073741824
can u pl. let me know if there is any problems with the mannasim.
'rca' is even not reflecting in my .tr file
 
Old 07-31-2015, 06:44 AM   #977
deepa_2111
Member
 
Registered: Apr 2011
Distribution: -
Posts: 185

Rep: Reputation: 268Reputation: 268Reputation: 268
Hi,

I think there is some kind of an internal limitation. Debugged the back end and found that there was a limitation on both the size and the number of nodes.
Not sure if it was a limitation with my set up.
I don't remember a lot of the details since it was 3-4 years ago, but I remember not being to increase the network size as well as number of nodes beyond a point.
 
Old 08-03-2015, 01:24 AM   #978
Abdul_dos
LQ Newbie
 
Registered: Jul 2015
Posts: 9

Rep: Reputation: Disabled
Hello guys,
I have successfully implemented LEACH in ns-2.35 ,but I am not sure about the output how good is it so I kindly want your help to look at it and let me know where the errors are.It seems that no ADVs has been sent and the total energy is not accurate.
Best Regards,
Attached Files
File Type: pdf Leach.out1.pdf (106.0 KB, 33 views)
 
Old 08-03-2015, 09:23 AM   #979
amita_s12
LQ Newbie
 
Registered: Feb 2015
Posts: 29

Rep: Reputation: Disabled
i don't get such output. my simulation work perfectly well for small no. of nodes. but giving errors for large no. of nodes.
i think u r not getting the correct output. have u worked on mannasim for generating leach.tcl?
 
Old 08-06-2015, 07:56 PM   #980
Abdul_dos
LQ Newbie
 
Registered: Jul 2015
Posts: 9

Rep: Reputation: Disabled
Hello guys,
I followed the instructions that are mentioned in https://groups.google.com/forum/?fro...c/OlR1n0gAK_4J to run leach on ns-2.34, but I got error in leach.err. Then, I looked at all of the posts in this thread and I did what have been recommended, but I still have the same issue also I did what is recommended to change in uamps.tcl. Your help guys is urgent please.
I use ubuntu 14.04 64 bit.
Attached Files
File Type: pdf leach.err.pdf (35.7 KB, 28 views)
File Type: pdf uamps.tcl.pdf (32.0 KB, 26 views)
 
Old 08-07-2015, 06:34 AM   #981
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
Re #980, @Abdul_dos.
Quote:
couldn't read file "../../rca/ns-*‐ranode.tcl":
Solution : Somewhere in this very thread ...
But here it is again : In /home/name/ : $ tar xvf leach-test__Ubuntu12.tar.gz
https://drive.google.com/file/d/0B7S...ew?usp=sharing
$ cd 9tmp/ns-allinone-2.34/ns-2.34/
Code:
$ export RCA_LIBRARY=/home/<name>/9tmp/ns-allinone-2.34/ns-2.34/mit/rca && export uAMPS_LIBRARY=/home/<name>/9tmp/ns-allinone-2.34/ns-2.34/mit/uAMPS && ./test
 
Old 08-07-2015, 06:48 PM   #982
Abdul_dos
LQ Newbie
 
Registered: Jul 2015
Posts: 9

Rep: Reputation: Disabled
Thank you so much knudfl, I really appreciate your support that you have been providing and being kind and patient with all, i did what you mentioned in the last post and it worked but the leach.out shows "Warning!!! No Cluster Head ADVs were heard!-*‐ns-*‐leach.tcl" also Total Energy seems to be inaccurate.Could you please look at the attached document and guide me please.
Attached Files
File Type: pdf #leach.out.pdf (197.4 KB, 20 views)
 
Old 08-10-2015, 08:42 PM   #983
Abdul_dos
LQ Newbie
 
Registered: Jul 2015
Posts: 9

Rep: Reputation: Disabled
guys please help
 
Old 08-17-2015, 04:58 PM   #984
Abdul_dos
LQ Newbie
 
Registered: Jul 2015
Posts: 9

Rep: Reputation: Disabled
Hello guys,
kindally I need your help I am still strugling with leach.out, and I read what is mentioned in http://www.linuxquestions.org/questi...68/page40.html but I got confused with it , could please guide me to approach a good output, the attaced file is my leach.out.
Please help please help
Attached Files
File Type: pdf leach.out???.pdf (199.9 KB, 16 views)
 
Old 10-06-2015, 04:59 AM   #985
NAYEFALDAUIS
LQ Newbie
 
Registered: Oct 2014
Posts: 4

Rep: Reputation: Disabled
Question Pkt Delay !

Hello,
Cloud pleas any one told me or give me the function to calculate the pkt delay in "NS2" for LEACH or PEGASIS protocol!

thanks in advance.
 
Old 11-24-2015, 11:37 PM   #986
doanhapro
LQ Newbie
 
Registered: Nov 2015
Posts: 8

Rep: Reputation: Disabled
I have installed leach and leach-c protocol but how to plot graph from leach.alive, leach.energy and leach.data file......
And how to calculate network lifetime and remaining energy for both leach and leach-c protocol.





Quote:
Originally Posted by nmmn134 View Post
I install exidus-pegasis_ns-234-leach.tar of exidus. The result seems reasonable. Leach-c was better than Leach because Leach-c was develop from leach.
the plot.
http://www.linuxquestions.org/questi...1&d=1363277097
 
Old 12-08-2015, 12:52 AM   #987
esmaeil
LQ Newbie
 
Registered: Dec 2015
Posts: 2

Rep: Reputation: Disabled
i have in error in leach-ns2.35 in ubuntu 14.4 LTS
INITIALIZE THE LIST xListHead
Error!!
str2addr:Address 2147483647 outside range of address field length 1073741824
 
Old 12-08-2015, 09:05 AM   #988
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
Re post #987, @esmaeil : Welcome to LQ.

Requirements for the "ns235 LEACH" : A 64bits OS, like Ubuntu 14.04 - amd64.

The patch : leach_ns235-Jun2015.patch
https://drive.google.com/file/d/0B7S...ew?usp=sharing

INFO : http://www.linuxquestions.org/questi...4175556129/#11
... and post #9, for the awk script, leach__nodes-alive.awk .

And post #75 here for the leach_energy*.awk scripts :
http://www.linuxquestions.org/questi...250/page5.html

-
 
Old 01-14-2016, 05:34 AM   #989
elemenohpi
LQ Newbie
 
Registered: Jan 2016
Posts: 2

Rep: Reputation: Disabled
LEACH Code problem

Hello LQ community. I've been reading the posts in this thread for a while now and didn't find anything useful to help me out.

I have successfully installed LEACH in NS-2.34 (also did the same in NS-2.35) on UBUNTU 14.04. The code is working and all but I got the following results:

Code:
.
.
.
Node 92 is DEAD!!!!
Node 93 is DEAD!!!!
Node 94 is DEAD!!!!
Node 95 is DEAD!!!!

At 1.0999999999999999:
		Total Energy = 30007.100986809415
		Total Data = 0
		Total Alive = 4

Simulation complete.

num_nodes is set 101
channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 222.8
Note that I just posted the last part of my leach.out file. As you can see, no data is sent to the Base Station and also Nodes die so fast (At 1.09...). I made a custom trace file and noticed that checkAlive function in ns-leach.tcl considers a node dead, even if it has remaining energy. So I changed the code so it checks remaining energy and hopefully nodes stay alive now. But still no data was sent to the base station.

I continued to trace the functions and found out that findBestCluster function in ns-leach.tcl is called before the packets arrive to each node. therefore clusterChoices_ variable is always empty and no JOIN_REQ packet is sent. (Or is sent in the next call of decideClusterHead, 10 seconds later which gets considered as invalid I guess) So I added some more time to opt(ra_adv_total) in leach.tcl. The trace shows that everything seems to be working just fine but, after a short while, everything stops! and end of my leach.out file and custom trace file are:

leach.out:
Code:
Data was sent to the base station
num_nodes is set 51
channel.cc:sendUplol - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 213.2
customtrace.tr:
Code:
-T 0.0048719999999999996 findBestCluster
-T 0.0048719999999999996 findBestCluster
-T 0.0048719999999999996 findBestCluster
-T 0.0048719999999999996 findBestCl
as you can see it even fails to finish findBestCluster word. It looks like a segmentation fault to me, but I get a printf at the end of leach.out.
 
Old 01-15-2016, 11:52 AM   #990
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 #989, @elemenohpi : Welcome to LQ.

* ns-2.34, ns-2.35 : The OS better be 64bits, i.e. Ubuntu 14.04 - amd64.
( The output from $ uname -m : x86_64 ):

You will get poor results with a 32 bits OS.


-
 
1 members found this post helpful.
  


Reply

Tags
leach, leach-warning50, ns2, ns2 ns234, pegasis



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
ns:"error when calling class OldSim"&tclsh:"invalid command+child process exits abn." shojaru Linux - Newbie 0 03-05-2009 04:23 AM
labview stopped at "init tmp resource files" on FC4 baosheng Linux - Software 2 09-28-2007 11:02 AM
ORiNOCO WLAN card not working - "failed to allocate resource" hauneboo Linux - Laptop and Netbook 1 11-29-2005 09:08 AM
What "kernel opts" allow PC to power down with "turning energy off"? kornerr Linux - General 1 03-10-2005 12:07 PM
nvidia insmod: "Device or resource busy" w/GeForce 4 MX KeithSpook Linux - Hardware 4 03-03-2004 12:21 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:32 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