LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-25-2016, 06:19 AM   #16
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 #14, #15.

Your file ( Rach_k-gpsr_K.tcl ) is not very useful with no 'cbr-15-5.tcl' and 'scenario.ns_movements'.
Please upload the files to dropbox https://www.dropbox.com/ or 'Google Drive'.
And : Please tell which line(s) you edited, i.e. the line number(s).


One thing I can suggest is to set up GPSR-hls, it may be more robust with changes.
( If usable for your project.)
Remember ... you can have as many ns-allinone-2.xx as you want, at the same time.
GPSR-hls → → → /usr/local/bin/ns-hls ( Or whatever name you like for 'ns'.


-
 
Old 06-25-2016, 07:06 AM   #17
Rach k
LQ Newbie
 
Registered: Apr 2016
Posts: 15

Rep: Reputation: Disabled
hello knudfl,

I have tried gpsr-hls too, but it wasn't working. so switched to k-gpsr.
so here are the links for all the files i used. Scenario.ns_movements was generated by VanetMobiSim.
https://www.dropbox.com/s/xgqfn5qo1wn0l3o/u.xml?dl=0

https://www.dropbox.com/s/vm9olci5pa...-15-5.tcl?dl=0
https://www.dropbox.com/s/0wk5d6y8hki8801/g1.tcl?dl=0
https://www.dropbox.com/s/nhbdcjgagb...movements?dl=0
What actual code is
Code:
set opt(x)		670		;# X dimension of the topography
set opt(y)		670		;# Y dimension of the topography
set opt(cp)		"./cbr100.tcl"
set opt(sc)		"./grid-deploy10x10.tcl"

set opt(ifqlen)		50		;# max packet in ifq
set opt(nn)		100		;# number of nodes
set opt(seed)		0.0
set opt(stop)		250.0		;# simulation time
In tcl file what i have changed is
Code:
set opt(x)		1001		;# X dimension of the topography
set opt(y)		1001		;# Y dimension of the topography
set opt(cp)		"cbr-15-5.tcl"
set opt(sc)		"scenario.ns_movements"

set opt(ifqlen)		50		;# max packet in ifq
set opt(nn)		15		;# number of nodes
set opt(seed)		5.0
set opt(stop)		1000.0		;# simulation time

Last edited by Rach k; 06-25-2016 at 07:13 AM.
 
Old 06-25-2016, 10:26 AM   #18
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 #17.
Code:
$ ns235-gpsr-K-64 g1.tcl
Seeding Random number generator with 5.0

num_nodes is set 15
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
GPSR configuration file
INITIALIZE THE LIST xListHead
Loading connection pattern...                                    
Loading scenario file...                                         
Load complete...                                                 
Starting Simulation...                                           
SORTING LISTS ...DONE!                                           
NS EXITING...
... That's with a 64bits OS ... PCLinuxOS 2016 - 64.
* trace.tr = 14.4MB .
... And Ubuntu 10.10 - 32bits : Same OK result, and again trace.tr 14.4MB .

? Which OS are you using for gpsr-KeLiu ?


-
 
Old 06-25-2016, 11:53 AM   #19
Rach k
LQ Newbie
 
Registered: Apr 2016
Posts: 15

Rep: Reputation: Disabled
re #18
I am using ubuntu 12.04.5 LTS 32 bits.
Even I am getting the same results
 
Old 06-25-2016, 01:07 PM   #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
Re #19, #15.

I misunderstood something, or read from the wrong post. (#14).
Your result in post #15 is perfect. What's the problem ? If any.




-

Last edited by knudfl; 06-25-2016 at 01:12 PM.
 
Old 06-25-2016, 11:06 PM   #21
Rach k
LQ Newbie
 
Registered: Apr 2016
Posts: 15

Rep: Reputation: Disabled
Re #20
I was expecting this as the output
Code:
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ ns-gpsr-keliu wireless-gpsr.tcl
num_nodes is set 100
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
GPSR configuration file
INITIALIZE THE LIST xListHead
Loading connection pattern...
Loading scenario file...
Load complete...
Starting Simulation...
channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 129.2
SORTING LISTS ...DONE!
NS EXITING...
but what the problem is, there is no variations in results, like Throughput, packet delivery ratio and all. I am getting negative and zero. This is the result, I am getting.
Code:
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ ns-gpsr-keliu g1.tclSeeding Random number generator with 5.0

num_nodes is set 15
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
GPSR configuration file
INITIALIZE THE LIST xListHead
Loading connection pattern...
Loading scenario file...
Load complete...
Starting Simulation...
SORTING LISTS ...DONE!
NS EXITING...
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f all.awk trace.tr
cbr s:0 r:0, r/s Ratio:-nan, f:38184 
avg_end_to_end_delay 0.0000
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f pdr.awk trace.tr
sent:38184 recieve:0, PDR:0.0000 
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f tput.awk trace.tr
Average Throughput[kbps] = -0.00		 StartTime=6.32	StopTime=0.00
Code:
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ ns-gpsr-keliu g4.tcl
Seeding Random number generator with 60.0

num_nodes is set 15
warning: Please use -channel as shown in tcl/ex/wireless-mitf.tcl
GPSR configuration file
INITIALIZE THE LIST xListHead
Loading connection pattern...
Loading scenario file...
Load complete...
Starting Simulation...
SORTING LISTS ...DONE!
NS EXITING...
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f pdr.awk trace.tr
sent:36357 recieve:0, PDR:0.0000 
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f tput.awk trace.tr
Average Throughput[kbps] = -0.00		 StartTime=32.29	StopTime=0.00
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f all.awk trace.tr
cbr s:0 r:0, r/s Ratio:-nan, f:36357 
avg_end_to_end_delay 0.0000
so I am guessing it as a wrong result.
 
Old 06-26-2016, 06:59 AM   #22
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 #21.

It's a general issue with GPSR-KeLiu, (GPSR-hls?) that no packages are received.
See http://www.linuxquestions.org/questions/tags/gpsr/

Please check with the default examples :
GPSR_KeLiu_examples.06.2016.tar.gz
https://drive.google.com/file/d/0B7S...ew?usp=sharing

gpsr-hls-examples-03.15.tar.gz
https://drive.google.com/file/d/0B7S...ew?usp=sharing

Seed : Per definition the seed is always random.


-
 
Old 06-27-2016, 12:09 AM   #23
Rach k
LQ Newbie
 
Registered: Apr 2016
Posts: 15

Rep: Reputation: Disabled
Re #22
Hello Mr. Knudfl,
Thank you for your generous help. I have tried default examples which is mentioned in #22, it isnt working. It is showing the following error.
Code:
ubuntu34@ubuntu:~/Downloads/keliu$ ns-gpsr-keliu wireless-gpsr.tcl
couldn't read file "../tcl/lib/ns-bsnode.tcl": no such file or directory
    while executing
"source.orig ../tcl/lib/ns-bsnode.tcl"
    ("uplevel" body line 1)
    invoked from within
"uplevel source.orig[list $fileName]"
    invoked from within
"if [$instance_ is_http_url $fileName] {
set buffer [$instance_ read_url $fileName]
uplevel eval $buffer
} else {
uplevel source.orig[list $fileName]
..."
    (procedure "source" line 8)
    invoked from within
"source ../tcl/lib/ns-bsnode.tcl"
    (file "wireless-gpsr.tcl" line 198)
I have replaced the ns-bsnode.tcl and com.tcl

Last edited by Rach k; 06-27-2016 at 12:10 AM.
 
Old 06-27-2016, 03:59 AM   #24
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 #23.

tcl/lib/ns-bsnode.tcl and tcl/mobility/com.tcl :
The default wireless-gpsr.tcl was meant to be run from ns-2.3x/gpsr/.
In that way you have tcl/ available outside the gpsr/ folder.

Alternatively you can have a folder tcl/{lib/, mobility/} outside the examples folder.

'wireless-gpsr.tcl' depends on three configuration files : gpsr.tcl, ns-bsnode.tcl, com.tcl.
* gpsr.tcl, ns-bsnode.tcl, com.tcl cannot be replaced with some random files.


-
 
Old 06-28-2016, 11:37 PM   #25
Rach k
LQ Newbie
 
Registered: Apr 2016
Posts: 15

Rep: Reputation: Disabled
Re #24,
@knudfl

Hi,I have corrected the above error. But what I am facing is unable to analyse the statastics like PDR,end-end delay, normalised routing load. The only result, I am getting is throughput, by the throughput2007.awk script.
Code:
ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f end-to-end.awk trace.tr
Total Delay ms:0.000000 
Total Sent AGT CBR Packets :0.000000 
Total Drop RTR Packets :0.000000 
Number of RTR received packets:0.000000
Number of Agent CBR received packets:0.000000
Average Delay ms:-nan 
Packet Delivery ratio PDR -nan
 The throughput in bits per second is 0.000000
 The spectral Efficiency in b/s/Hz is 0.000000

ubuntu34@ubuntu:~/Downloads/ns-allinone-2.34/ns-2.34/gpsr$ awk -f Throughput2007.awk trace.tr
Average Throughput[kbps] = 11123.03		 StartTime=59.14	StopTime=999.90
Average Throughput[kbps] = 11123.03		 StartTime=59.14	StopTime=999.90
All most all awk scripts I have tried, which you have mentioned in one of your earlier post in the folder "awk#perl#python__scripts-10.2015 (2)".
https://www.dropbox.com/s/kv3irmojc5...t2007.awk?dl=0
 
Old 06-29-2016, 01:25 AM   #26
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 #25.

Same with GPSR-hls :
Code:
$ awk -f throughput-2015.awk fangzhen1.tr
start Time = 1.000000, stopTime = 0.000000
sent_packets     396
received_packets 0
PDR 0.00%
Average Throughput[kbps] = -0.00   StartTime=1.00  StopTime = 0.00
Other suggestions : ns3 + GPSR, Omnet++.
ns3 https://groups.google.com/forum/?fro...rum/ns-3-users
Omnett++ https://groups.google.com/forum/?fro...!forum/omnetpp


-
 
Old 07-27-2016, 08:31 AM   #27
Ruqayya
LQ Newbie
 
Registered: Jul 2016
Posts: 2

Rep: Reputation: Disabled
#20

@ Rach_k

hello. i m also stuck in the same problem. i have tried both gpsr-hls and gpsr-keliu versions. tried many awk scripts to get the statistics like throughput,Packet delivery ratio etc but no success. Any success in analysing these statistics?
 
Old 07-27-2016, 11:15 PM   #28
Rach k
LQ Newbie
 
Registered: Apr 2016
Posts: 15

Rep: Reputation: Disabled
Re #27
@ Ruqayya

Hi, I haven't got the desired results. Sorry I couldn't help.
 
Old 07-28-2016, 12:34 AM   #29
Ruqayya
LQ Newbie
 
Registered: Jul 2016
Posts: 2

Rep: Reputation: Disabled
Re#27
thanks for reply. one more question.
In the trace which i got through gpsr-hls patched which i changed according to my scenario, all recieved packets are at RTR level and no packet is recieved at AGT level why this is happening ?? please help
 
Old 07-28-2016, 07:41 AM   #30
alwaleed16
LQ Newbie
 
Registered: Jul 2016
Posts: 13

Rep: Reputation: Disabled
Dear knudfl,

I patched GPSR in ns 2.35 on Ubuntu 12.04 32bit according to the following commands:

$ tar xvf ns-allinone-2.35_gcc482.tar.gz ( Patched for gcc-4.8.2 and -4.9.1 ).
https://drive.google.com/file/d/0B7S...ew?usp=sharing
$ cd ns-allinone-2.35/
$ patch -p0 < GPSR-hls_ns235.patch
https://drive.google.com/file/d/0B7S...ew?usp=sharing
$ ./install
$ cd ns-2.35/
$ cp ns ns-gpsr-hls
$ sudo cp ns-gpsr-hls /usr/local/bin/
... Then you can do: $ ns-gpsr-hls ssoumayaa.tcl
... from the examples, gpsr-hls-examples-05.14.tar.gz
https://drive.google.com/file/d/0B7S...ew?usp=sharing

But when I tried to run ssoumayaa.tcl example the following error appeared

Configuring Nodes (40)
INITIALIZE THE LIST xListHead
Starting Simulation...
Segmentation fault (core dumped)
khalid@khalid-VirtualBox:~/ns-allinone-2.35/ns-2.35/gpsr$

Please, how can I overwrite this problem.

Thanks
 
  


Reply

Tags
gpsr, gpsr-235, gpsr-hls, gpsr-keliu, ns2


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
How to patch DYMOUM routing protocol in ns-2.33 ! omar11 Linux - Software 7 08-15-2012 05:15 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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