LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 12-04-2013, 03:13 AM   #16
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled

ubuntu-12.04.3-desktop-i386.iso is it this one?

Will this be ok for GPSR?
 
Old 12-04-2013, 06:44 AM   #17
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 15 .

`i386' is used for 32bits** x86 by Debian / Ubuntu, probably for historical reasons.
All 32bits packages use suffix i386.deb,
though I doubt that any of those would work with an i386 computer.
The iso files also use "i386" for the i686 OS's.

`i686' appears when you have installed the OS : $ uname -m

-
 
Old 12-04-2013, 12:50 PM   #18
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled
I have installed ubuntu 11.10 32bits (i686) and have done the step in post #8

but i got this errors

============================================================
* 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... gcc-4.1
checking whether the C compiler works... no
configure: error: in `/home/iraq/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.

when I check ls /usr/bin/gcc* __ out ----> /usr/bin/gcc /usr/bin/gcc-4.5 /usr/bin/gcc-4.6

means, g++4.1 is not there, I tried to installit by using:
$ sudo apt-get install g++-4 , i got the following message:

ir@ubuntu:~/ns-allinone-2.33$ sudo apt-get install g++-4
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package g++-4
E: Couldn't find any package by regex 'g++-4'
ir@ubuntu:~/ns-allinone-2.33$

how to settle this??

Many thanks
 
Old 12-04-2013, 02:49 PM   #19
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 18 .

Ubuntu 11.10 : Why not use the supported "12.04.3" ? ?

About gcc / g++ version 4.1.2 :
None are available with `apt-get' : Ubuntu's 11.04 .. 13*.

gcc/g++ ver. 4.1.2 for 11.10 : post #62 here
http://www.linuxquestions.org/questi...164/page5.html

12.04 : post #18 here
http://www.linuxquestions.org/questi...022/page2.html


Quote:
I have installed ubuntu 11.10 32bits (i686) and have done the step in post #8
You will have to delete ns-allinone-2.33, and start from scratch.

-
 
Old 12-04-2013, 10:54 PM   #20
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled
Tq..

Is your advice that I have to install ubuntu 12.04 and then install new ns-2.33?

what about the file in in post #8?
 
Old 12-04-2013, 11:25 PM   #21
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled
I updated my ubuntu to 12.04 .
 
Old 12-05-2013, 12:00 AM   #22
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled
I think it gone smothly .. how to make sure GPSR works?

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.
 
Old 12-05-2013, 01:20 AM   #23
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 22 .
Quote:
how to make sure GPSR works ?
Please have a look into ns-2.33/hls/utils/**
... and then read http://www.linuxquestions.org/questions/tags/gpsr-hls/
And also use "gpsr-hls-examples-0113.tar.gz"
https://drive.google.com/file/d/0B7S...it?usp=sharing

-
 
Old 12-07-2013, 02:18 AM   #24
en.khalid82
Member
 
Registered: Apr 2013
Posts: 61

Original Poster
Rep: Reputation: Disabled
Dear Mr.Knudfl, may you show me how can I create a scenario file in GPSR like another protocols ( for example, number of nodes, network area size, and etc) in order to calculate the packet delivery fraction and end-to-end delay for that protocol.

Thanks
 
Old 12-08-2013, 08:43 AM   #25
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 24 .

"number of nodes" : set opt(nn) 5 #number of nodes.
Or : set val(nn) 5 #number of nodes.
Or : http://www.winlab.rutgers.edu/~zhibi.../NS_examp.html

"network area size" : Please have a look at this line (hls.tcl) :
"set val(use_gk) 0 ;# > 0: use GridKeeper with this radius".
Looks like it's about "radius".
And paper-cmu.tcl has something too :
"# set opt(radius) 250 ;# radius of communication (XXX -- compute it)".

Quote:
calculate the packet delivery fraction and end-to-end delay
May be use an awk script for those calculations → →
→ awk_scripts_11.2013.tar.bz2 → →
https://drive.google.com/file/d/0B7S...it?usp=sharing

-
 
Old 12-11-2013, 10:59 PM   #26
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled
when im trying to run below tcl file:
I got this
radiorange 250, x 500 y 500
length : 1.000000 , cellperline 3 , heigth 1.000000
maxlevel 1
radiorange 250, x 500 y 500
length : 1.000000 , cellperline 3 , heigth 1.000000
maxlevel 1
radiorange 250, x 500 y 500
length : 1.000000 , cellperline 3 , heigth 1.000000
maxlevel 1
format_aodv: invalid AODV packet type

how to solve it?

Code:
 

# Define options
# ======================================================================

set val(chan)       Channel/WirelessChannel  	;#channel type
set val(prop)       Propagation/TwoRayGround	;#radio propagation delay
set val(netif)      Phy/WirelessPhy		;#network interface type
set val(mac)        Mac/802_11			;#MAC type
set val(ifq)        Queue/DropTail/PriQueue	;#interface queue type
set val(ll)         LL				;#link layer type
set val(ant)        Antenna/OmniAntenna		;#antenna model
set val(x)              500 			;# X dimension of the topography
set val(y)              500  			;# Y dimension of the topography
set val(ifqlen)         50            		;# max packet in ifq
set val(seed)           0.0
set val(adhocRouting)   GPSR			;#routing protocol
set val(nn)             50             		;# how many nodes are simulated
set val(cp)             "cbr_n50_mc10" 		;#cbr with 20 nodes and max connection 5
set val(sc)             "scen_n50_m10_p20"	;#scen with 20 node, speed of 10, pause time 30 
set val(stop)           900           		;# simulation time

# =====================================================================
# Main Program
# ======================================================================

#
# Initialize Global Variables
#

# create simulator instance
set ns_	[new Simulator]


# setup topography object
set topo	[new Topography]


# create trace object for ns and nam
#for new trace file format
$ns_ use-newtrace 

set tracefd	[open out1.tr w]
set namtrace    [open out2.nam w]

$ns_ trace-all $tracefd
$ns_ namtrace-all-wireless $namtrace $val(x) $val(y)



# define topology
$topo load_flatgrid $val(x) $val(y)

#
# Create God
#
set god_ [create-god $val(nn)]


# New API to config node: 
# 1. Create channel (or multiple-channels);
# 2. Specify channel in node-config (instead of channelType);
# 3. Create nodes for simulations.

# Create channel #1 and #2
set chan_1_ [new $val(chan)]
set chan_2_ [new $val(chan)]


#configure the node
$ns_ node-config -adhocRouting $val(adhocRouting) \
                 -llType $val(ll) \
                 -macType $val(mac) \
                 -ifqType $val(ifq) \
                 -ifqLen $val(ifqlen) \
                 -antType $val(ant) \
                 -propType $val(prop) \
                 -phyType $val(netif) \
                 #-channelType $val(chan) \
		 -topoInstance $topo \
		 -agentTrace ON \
                 -routerTrace ON \
                 -macTrace ON \
		 -movementTrace ON \
		 -channel $chan_1_ 

# node_(1) can also be created with the same configuration, or with a different
# channel specified.
# Uncomment below two lines will create node_(1) with a different channel.
#  $ns_ node-config \
#		 -channel $chan_2_ 


#
#  Create the specified number of nodes [$val(nn)] and "attach" them
#  to the channel. 

for {set i 0} {$i < $val(nn) } {incr i} {
	set node_($i) [$ns_ node]
	$node_($i) random-motion 0		;# disable random motion	
	
}


# 
# Define node movement model, generated using cbr-gen
#
puts "Loading connection pattern..."
source $val(cp)

# 
# Define traffic model, generated using mov-gen
#
puts "Loading scenario file..."
source $val(sc)



# Define node initial position in nam
for {set i 0} {$i < $val(nn)} {incr i} {

    # 20 defines the node size in nam, must adjust it according to your scenario
    # The function must be called after mobility model is defined
    
    $ns_ initial_node_pos $node_($i) 20
}


#
# Tell nodes when the simulation ends
#
for {set i 0} {$i < $val(nn) } {incr i} {
    $ns_ at $val(stop).0 "$node_($i) reset";
}

#ending simulation
$ns_ at  $val(stop) "$ns_ nam-end-wireless $val(stop)"
$ns_ at $val(stop) "stop"
$ns_ at 900.01 "puts \"END SIMULATION!!!!\" ; $ns_ halt"

proc stop {} {
	global ns_ tracefd namtrace
	$ns_ flush-trace
	close $tracefd
	close $namtrace
	}

#run ns
$ns_ run

Last edited by hothifa; 12-19-2013 at 12:29 PM. Reason: asked my admin
 
Old 12-12-2013, 02:14 AM   #27
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 26 .
Quote:
format_aodv: invalid AODV packet type
Please use "code tags",
i.e. type [/code] at code end, and [code] at code start.
http://www.linuxquestions.org/questi....php?do=bbcode
http://www.linuxquestions.org/questi...gs-4175464257/
... Please edit post #26.

Your tcl code, "hothifa.tcl" : What is "cbr_n50_mc10", line 17, 107 ?
.. and "scen_n50_m10_p20", line 18 ?
Please attach the files, or upload to 'Google Drive' if they are big files.
? May be the doubtful expression "format_aodv" origins from one of those ?
** The simulation runs OK with random files cbr_n50_mc10, scen_n50_m10_p20 :
$ ns-hls hothifa.tcl

P.S. : There seems to be an object by name "format_aodv" in 'ns(-hls)',
so may be you have a failed build of "gpsr-hls" ?
Please install the package gpsr-hls-2.33-ubuntu10_i386.deb,
then you can test all GPSR-hls tcl files with the ns-hls' command.


-

Last edited by knudfl; 12-12-2013 at 06:32 AM.
 
Old 12-12-2013, 12:22 PM   #28
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled
I'm sorry, i could not understand what do you mean by post #27.

this tcl file i used to aodv since long time , I just changed AODV to GPSR and got the message in #26. however, I can not run ns-hls but when i run the example of hls.tcl by using " ns hls.tcl"

The following as you mentioned is runing correctly, but I can not get end to end delay or packet delivery fraction ... and so on ..
I use to run all awk scrip on the trace file.. for example " awk -f PDF.awk out.tr", some times i got no resurlt (all = ZERO), and with other awk files i got " awk: all.awk:62: fatal: division by zero attempted

below is what i got when i run ns hls.tcl



iraq@ubuntu:~/Downloads/hls-utils$ ns-hls hls.tcl
ns-hls: command not found
iraq@ubuntu:~/Downloads/hls-utils$ ns hls.tcl

Code:
num_nodes is set 40
Configuring Nodes (40)
INITIALIZE THE LIST xListHead
Starting Simulation...
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
radiorange 250, x 2000 y 2000
length : 3.000000 , cellperline 12 , heigth 3.000000
maxlevel 3
SORTING LISTS ...DONE!
channel.cc:sendUp - Calc highestAntennaZ_ and distCST_
highestAntennaZ_ = 1.5,  distCST_ = 550.0
--- Classfier::no-slot{} default handler (tcl/lib/ns-lib.tcl) ---
	_o31: no target for slot 0
	_o31 type: Classifier/Port
content dump:
classifier _o31
	0 offset
	0 shift
	2147483647 mask
	1 slots
		slot 255: _o33 (CMUTrace/Recv)
---------- Finished standard no-slot{} default handler ----------
iraq@ubuntu:~/Downloads/hls-utils$

Last edited by hothifa; 12-19-2013 at 12:31 PM.
 
Old 12-17-2013, 02:44 AM   #29
hothifa
LQ Newbie
 
Registered: Dec 2013
Posts: 13

Rep: Reputation: Disabled
problem with running awk script

Hi dears,

Im trying to run example of gpsr or hls but i got this error :

" awk: all.awk:62: fatal: division by zero attempted

I tried with many awk script but i could not get result

any help
 
Old 12-17-2013, 06:21 AM   #30
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
@hothifa : You will have to edit posts #26, #28 to use `code tags' :
Please read post #27 and follow the two links.

You can also use the " # " tool in the 'Advanced Editor' for editing to `code tags'


-
 
  


Reply

Tags
gpsr, gpsr-hls, 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 implement my own protocol with AgenjJ dissou Programming 2 02-14-2011 08:49 AM
How to implement my own protocol with AgentJ dissou Linux - Networking 0 02-10-2011 03:25 AM
Telnet protocol through GPRS/GSM Modem capa_master Linux - Newbie 1 12-22-2010 03:05 AM
i am using ubuntu as os. for NS2 to implement a routing protocol in ns2. sujovasu Programming 1 07-27-2010 01:44 AM
LXer: Tutorial: Border Gateway Protocol, The Routing Protocol of the Internet LXer Syndicated Linux News 0 11-13-2008 05:11 AM

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

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