[ns] Please Help - wireless nodes - packets dropping problem when more than one agent is attached

2009-03-11 Thread chekhov_neo


Hi,

I'm new to ns2. I've been trying to simulate a wireless scenario in which a
mobile node sends data to another mobile node. I attached two udp agents
with node0 with cbr traffic for both of them. Then i attached two null
agents to node1 to receive the data. Both the agents are started at the same
time and made to run simultaneously. While I do so most of the packets get
dropped. Is there any problem if i attach two agents to a wireless node and
make them work at the same time? 

The following is my tcl code:

# ==
# Define options
# ==
set val(chan)   Channel/WirelessChannel;# channel type
set val(prop)   Propagation/TwoRayGround   ;# radio-propagation
model
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(ifqlen) 50 ;# max packet in ifq
set val(nn) 2  ;# number of mobilenodes
set val(rp) DSR;# routing protocol
set val(x)  300 
   ;# X dimension of the topography in meters
set val(y)  300 
   ;# Y dimension of the topography in meters   
# =
# Main Program
# ==

set ns [new Simulator]

$ns use-newtrace

set tf [open out.tr w]
$ns trace-all $tf
set nf [open out.nam w]
$ns namtrace-all-wireless $nf $val(x) $val(y)

set topo [new Topography]
$topo load_flatgrid $val(x) $val(y)

create-god $val(nn)

# configure node
$ns node-config -adhocRouting $val(rp) \
-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   

set n0 [$ns node]
set n1 [$ns node]

$n0 set X_ 100.0
$n0 set Y_ 100.0
$n0 set Z_ 0.0

$n1 set X_ 200.0
$n1 set Y_ 100.0
$n1 set Z_ 0.0

$ns at 0.1 "$n0 setdest 50.0 100.0 0.5"
$ns at 0.1 "$n1 setdest 150.0 100.0 0.5"

set udp0 [new Agent/UDP]
$ns attach-agent $n0 $udp0
set cbr0 [new Application/Traffic/CBR]
$cbr0 set packetSize_ 500
$cbr0 set interval .005
$cbr0 attach-agent $udp0

set udp1 [new Agent/UDP]
$ns attach-agent $n0 $udp1 
set cbr1 [new Application/Traffic/CBR]
$cbr1 set packetSize_ 500
$cbr1 set interval .005
$cbr1 attach-agent $udp1

set null0 [new Agent/Null]
$ns attach-agent $n1 $null0

set null1 [new Agent/Null]
$ns attach-agent $n1 $null1

$ns connect $udp0 $null0
$ns connect $udp1 $null1

$ns at 0.1 "$cbr0 start"
$ns at 0.1 "$cbr1 start"

$ns at 4.5 "$cbr0 stop"
$ns at 4.5 "$cbr1 stop"

$ns at 5.0 "finish"

proc finish {} {
global ns tf nf
$ns flush-trace
close $tf
close $nf
exec nam out.nam &
exit 0
}

$ns run
---

Please help.

Regards,
arun chekhov
-- 
View this message in context: 
http://www.nabble.com/Please-Help---wireless-nodes---packets-dropping-problem-when-more-than-one-agent-is-attached-tp22453839p22453839.html
Sent from the ns-users mailing list archive at Nabble.com.



[ns] a special function required in queue

2009-03-11 Thread muralikrishna g

hi to all users...

now i am working with ns-2.33, here i required is that, keeping a threshold
level to queue and if the threshold level is reached i have to intimate the
upstream node..

how to do it.. please help me as early as possible i am in need..

thank you all

by
Muralikrishna Gaddam


Re: [ns] ns problem

2009-03-11 Thread Teerawat Issariyakul


Hi,

Basically, you are accessing the slot -1 which does not exist. I posted
the details at

http://t-issariyakul.blogspot.com/2009/03/no-slot-error-for-classifiers.html

For more information about Classifiers, see Chapter 6 in the following
book from Springer:

T. Issaraiyakul and E. Hossain, "Introduction to Network Simulator
NS2", Springer 2008.
http://www.springer.com/engineering/signals/book/978-0-387-71759-3

You may also find the following website useful:
http://www.ece.ubc.ca/~teerawat/NS2.htm

Best,
Teerawat

On 3/11/2009, "ali bala"  wrote:

>
>hi
>i wrote a simple example and run at ns but i see this:
>
>--- Classfier::no-slot{} default handler (tcl/lib/ns-lib.tcl) ---
>    _o18: no target for slot -1
>    _o18 type: Classifier/Hash/Dest
>content dump:
>classifier _o18
>    0 offset
>    0 shift
>    2147483647 mask
>    1 slots
>    slot 2: _o116 (Classifier/Port)
>    -1 default
>-- Finished standard no-slot{} default handler --
>
>i havent understanding about that
>i wanted to know about that
>thanks
>
>
>
>  
>



[ns] Fwd: ns-2.31 and Gnutellasim

2009-03-11 Thread negin fathoalahnejad

-- Forwarded message --
From: negin fathoalahnejad 
Date: Wed, Mar 11, 2009 at 5:57 PM
Subject: ns-2.31 and Gnutellasim
To: ns-users@isi.edu


Hello,
I am trying to add gnutellasim to ns-2.31. Does anybody have an idea about
the possible changes I have to do regarding some files, as it is mentioned
for previous versions of ns?

Thanks,
Negin


Re: [ns] the function generating a node in NS2.33

2009-03-11 Thread Mubashir Rehmani

Hi Nadine,

The objects of nodes are created in Node.cc, present in the common folder of
ns2.

http://rp.lip6.fr/ns-doc/ns226-doc/html/node_8cc-source.htm
http://rp.lip6.fr/ns-doc/ns226-doc/html/node_8h.htm

Regards

Mubashir Husain Rehmani
www-npa.lip6.fr/~rehmani 

2009/3/11 Nadine Chen 

>
> Hi all,
> Do you know please where can I find the function that generates the node in
> NS2.33?
> Thank you.
>
>
>
>
>


-- 
Mubashir Husain Rehmani


[ns] the function generating a node in NS2.33

2009-03-11 Thread Nadine Chen

Hi all,
Do you know please where can I find the function that generates the node in 
NS2.33?
Thank you.



  


Re: [ns] Re s: Scheduler: Event UID not valid!

2009-03-11 Thread martini.spy


Thanks for your reply!
I have already read that post, though, and I think that my problem is
indicated by:
1. You are using timers. When a timer is scheduled again without the 
previous schedule expiring - Trace which timer is scheduled and when it 
will expire.

But how can I find which timer is scheduled again?? This will be found in
scheduler.cc or mac-802.11.cc?

Plus, I am using the Infrastructure mode support for IEEE 802.11 when I get
that message. So, I found here:
http://nsnam.cvs.sourceforge.net/viewvc/nsnam/ns-2/CHANGES.html?view=log&r1=1.662&pathrev=MAIN
that there is a patch for "802.11 infra code; bug fixes" but haven't found
where to download it from, since there's nothing from the link above... 
Does anybody know something more on that?
Thank you very much everyone!
Spyros


Helber Wagner wrote:
> 
> 
> Hi,
> 
> Take a look at this post:
> http://mailman.isi.edu/pipermail/ns-users/2006-May/055823.html
> 
> Hope it helps,
> 
>  ___
> Helber Wagner da Silva
> MSc. Student in Applied Informatics
> University of Fortaleza - Ceará - Brazil
> URL: http://www.nr2.ufpr.br/~helber
> 
> 
> 
> 
> 
> 
> De: Spyros Marinis 
> Para: ns-users@ISI.EDU
> Enviadas: Quarta-feira, 11 de Março de 2009 12:18:17
> Assunto: [ns] Scheduler: Event UID not valid!
> 
> 
> Hi all!
> I use ns-2.33 and I am running a simulation for wireless sctp. 
> However the simulation stops at the very beginning, and it shows:
> Scheduler: Event UID not valid!
> I have read some older posts here about this, but they are all, as well as
> the proposed solutions, for older versions of ns, and some of the changes
> indicated are already on ns-2.33.
> Can anyone help me and guide me what to do?
> Thank you very much in advance. Any help will be appreciated,
> Spyros
> 
> 
> 
> 
>   
> ___ 
> Χρησιμοποιείτε Yahoo!; 
> Βαρεθήκατε τα ενοχλητικά μηνύματα (spam); Το Yahoo! Mail 
> διαθέτει την καλύτερη δυνατή προστασία κατά των ενοχλητικών 
> μηνυμάτων http://login.yahoo.com/config/mail?.intl=gr 
> 
> 
> 
>   Veja quais são os assuntos do momento no Yahoo! +Buscados
> http://br.maisbuscados.yahoo.com
> 

-- 
View this message in context: 
http://www.nabble.com/Scheduler%3A-Event-UID-not-valid%21-tp22457449p22462312.html
Sent from the ns-users mailing list archive at Nabble.com.




[ns] Res: Scheduler: Event UID not valid!

2009-03-11 Thread Helber Wagner

Hi,

Take a look at this post: 
http://mailman.isi.edu/pipermail/ns-users/2006-May/055823.html

Hope it helps,

 ___
Helber Wagner da Silva
MSc. Student in Applied Informatics
University of Fortaleza - Ceará - Brazil
URL: http://www.nr2.ufpr.br/~helber






De: Spyros Marinis 
Para: ns-users@ISI.EDU
Enviadas: Quarta-feira, 11 de Março de 2009 12:18:17
Assunto: [ns] Scheduler: Event UID not valid!


Hi all!
I use ns-2.33 and I am running a simulation for wireless sctp. 
However the simulation stops at the very beginning, and it shows:
Scheduler: Event UID not valid!
I have read some older posts here about this, but they are all, as well as the 
proposed solutions, for older versions of ns, and some of the changes indicated 
are already on ns-2.33.
Can anyone help me and guide me what to do?
Thank you very much in advance. Any help will be appreciated,
Spyros




  
___ 
Χρησιμοποιείτε Yahoo!; 
Βαρεθήκατε τα ενοχλητικά μηνύματα (spam); Το Yahoo! Mail 
διαθέτει την καλύτερη δυνατή προστασία κατά των ενοχλητικών 
μηνυμάτων http://login.yahoo.com/config/mail?.intl=gr 



  Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com

Re: [ns] starting Cygwin in windows vista

2009-03-11 Thread hakki


Thanks  for everyting, I downloaded them however, while I have been
installing ns-2 I faced an error message such that "tclcl-1.15 make failed".
And I don't know how can I solve this. 

best
hakki


trihedraldoc wrote:
> 
> I don't think you did download all packages otherwise Xfree86 libraries
> would have been found. 
> Did you make sure you did not "Hide Obsolete packages"? 
> Sorry but I acnnot see any other reason why those libraries wouldn't be
> there.  
> 
> 
> hakki wrote:
>> 
>> Hi, I dowloaded all the packages in cygwin also `xinit`, however, while I
>> have been trying to install ns-2, it gives a such error " Xfree86 package
>> is not installed". I have never seen Xfree86 packages in setup of cygwin,
>> I downloaded all the packages. What do you offer?
>> 
>> best
>> hakki
>> 
>> 
>> trihedraldoc wrote:
>>> 
>>> Hi.
>>> I used ns-2 on Cygwin on XP. Worked like a charm,
>>> Now I am struggling with installing it on the newest cygwin running on
>>> vista home premium. However I am seeing some light after few trials.
>>> here's my suggestions
>>> 1- Install every package Cygwin offers (do not "hide obsolete" packages.
>>> you need those since they include the xorg libraries that are vital to
>>> ns-2)
>>> 2- when you installed all packages of cygwin you will see in your
>>> Windows start menu two entries
>>> -Cygwin
>>> -Cygwin-x
>>>   In Cygwin-x click on xwinserver and that opens the xterminal
>>> magically.
>>> 
>>> Good luck
>>> 
>>> 
>>> Bello Lawal wrote:
 
 
 Hello,
 Pls. am getting difficulities in starting cygwin in windows vista. Pls.
 can some  one help?
 
 Many thanks 
 
 
 
   
 
 
>>> 
>>> 
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/starting-Cygwin-in-windows-vista-tp20874488p22459620.html
Sent from the ns-users mailing list archive at Nabble.com.




[ns] M ulti Channel Multi interface 802.11

2009-03-11 Thread Kiran K Chauhan

Hello Friends,

Did anyone try the Notebook:multi channel multi interface for NS2?

I could make the changes in file and do propoer installation ut while
running the example file twoflows2channel.tcl it gives error as:

num_nodes is set 4
INITIALIZE THE LIST xListHead
INITIALIZE THE LIST xListHead
INITIALIZE THE LIST xListHead
INITIALIZE THE LIST xListHead
INITIALIZE THE LIST xListHead

(_o25 cmd line 1)
invoked from within
"_o25 cmd add-route-tag 1 999"
invoked from within
"catch "$self cmd $args" ret"
invoked from within
"if [catch "$self cmd $args" ret] {
set cls [$self info class]
global errorInfo
set savedInfo $errorInfo
error "error when calling class $cls: $args" $..."
(procedure "_o25" line 2)
(SplitObject unknown line 2)
invoked from within
"$node_(0) add-route-tag 1 999"
(file "2.tcl" line 84)
Calling superclass Agent's command function!Calling superclass Agent's
command function!Calling superclass Agent's command function!Calling
superclass Agent's command function!

It will be really helpful if somebody helps me in this regard

Thanks

Regards
Kiran

-- 

Every footstep in life is full of possibilities we just need to know our
ability to explore them




Re: [ns] Scheduler: Event UID not valid!

2009-03-11 Thread Sidney Doria

A good answer is here:

http://web.syr.edu/~dchen02/FAQ.txt

QUESTION 1.

Sidney Doria
UFCG / BRAZIl



2009/3/11 Spyros Marinis :
>
> Hi all!
> I use ns-2.33 and I am running a simulation for wireless sctp.
> However the simulation stops at the very beginning, and it shows:
> Scheduler: Event UID not valid!
> I have read some older posts here about this, but they are all, as well as 
> the proposed solutions, for older versions of ns, and some of the changes 
> indicated are already on ns-2.33.
> Can anyone help me and guide me what to do?
> Thank you very much in advance. Any help will be appreciated,
> Spyros
>
>
>
>
>
> ___
> Χρησιμοποιείτε Yahoo!;
> Βαρεθήκατε τα ενοχλητικά μηνύματα (spam); Το Yahoo! Mail
> διαθέτει την καλύτερη δυνατή προστασία κατά των ενοχλητικών
> μηνυμάτων http://login.yahoo.com/config/mail?.intl=gr
>



-- 
Sidney Doria
Redes ad hoc móveis
Doutorado em Computação
UFCG
Brasil

"Nessa jornada, o conhecimento será o seu escudo..."
(Mestre dos Magos no episódio do grimoire de ouro)



[ns] ns problem

2009-03-11 Thread ali bala

hi
i wrote a simple example and run at ns but i see this:

--- Classfier::no-slot{} default handler (tcl/lib/ns-lib.tcl) ---
    _o18: no target for slot -1
    _o18 type: Classifier/Hash/Dest
content dump:
classifier _o18
    0 offset
    0 shift
    2147483647 mask
    1 slots
    slot 2: _o116 (Classifier/Port)
    -1 default
-- Finished standard no-slot{} default handler --

i havent understanding about that
i wanted to know about that
thanks



  


[ns] Scheduler: Event UID not valid!

2009-03-11 Thread Spyros Marinis

Hi all!
I use ns-2.33 and I am running a simulation for wireless sctp. 
However the simulation stops at the very beginning, and it shows:
Scheduler: Event UID not valid!
I have read some older posts here about this, but they are all, as well as the 
proposed solutions, for older versions of ns, and some of the changes indicated 
are already on ns-2.33.
Can anyone help me and guide me what to do?
Thank you very much in advance. Any help will be appreciated,
Spyros




  
___ 
Χρησιμοποιείτε Yahoo!; 
Βαρεθήκατε τα ενοχλητικά μηνύματα (spam); Το Yahoo! Mail 
διαθέτει την καλύτερη δυνατή προστασία κατά των ενοχλητικών 
μηνυμάτων http://login.yahoo.com/config/mail?.intl=gr 


Re: [ns] How to get incoming packets source and destination address

2009-03-11 Thread obaid abbasi

Hello,

In the receive "recv(Packet* p, Handler*)" function of agent You can easily
access the IP header of a packet.
hdr_ip* iph = hdr_ip::access(p);

You can get source ( iph->src_.addr_) and destination (iph->dst_.addr_)
address.


Regards,
Ubaid Abbasi
INRIA-CNRS Lab (LaBRI)
University Of Bordeaux
France




2009/3/11 muralikrishna g 

>
> hi to all...
>
> i am working with network simulator ns-2.33, here at an intermediate
> node i have to know the incoming packets source and destination
> address. how to get this please help me
>
> thank you
>
>


[ns] segmenation fault for more than 20 nodes in OLSR

2009-03-11 Thread Syed Md. Ashraful Karim

Hi
I modified the UM-OLSR protocol to add some security elements. it works fine 
until the number nodes crosses 20. with more nodes i am getting a segmentation 
fault. 

can anybody help me , why segmentation fault may occur? help with some causes 
and remedies.  how can i debug it? i think the memory is not overloaded, as 
OLSR runs with more than 50/100 nodes. 
thanks in advance.

/Ashraf




  


[ns] Need help to use Rayleigh fading in ZigBee

2009-03-11 Thread pratiti bhadra

Hi all,

How can I use rayleigh fading model in ZigBee stack.
Tworayground radio  propagation model used in ZigBee/IEEE 802.15.4 . Can I
use rayleigh fading propagation model instead of tworayground.
How can I change it.

-- 
With best regards,
 Pratiti


[ns] How to get incoming packets source and destination address

2009-03-11 Thread muralikrishna g

hi to all...

i am working with network simulator ns-2.33, here at an intermediate
node i have to know the incoming packets source and destination
address. how to get this please help me

thank you



Re: [ns] Energy consumption for mobile nodes notreceiving/transmitting

2009-03-11 Thread Rodrigo Palucci Pantoni

Hi Mubashir,
This node state that Salvo mentionde is called "Sleep mode" for the 
wireless node (defined in the specifications) ?

Thank you

- Original Message - 
From: "Mubashir Rehmani" 
To: "Salvo Danilo Giuffrida" 
Cc: "ns-users" 
Sent: Tuesday, March 10, 2009 12:59 PM
Subject: Re: [ns] Energy consumption for mobile nodes 
notreceiving/transmitting


>
> Hi Salvo,
>
> Yes, it is normal. For instance there are 10 nodes that are within the 
> range
> of each other. If node 1 sends packet to node 10, then all the nodes
> overhear the packet, and discard the packet (because the packet is not
> destined to it). Thus, it is obvious that, in this case, nodes will 
> consume
> some energy.
>
> Regards
> Mubashir Husain Rehmani
> http://www.irisa.fr/asap/Members/mrehmani/Mubashir
>
> 2009/3/10 Salvo Danilo Giuffrida 
>
>>
>> Hello, is it normal that a mobile node that does not transmit,
>> receive, or forward data in an ad-hoc network, consumes anyway energy,
>> just because it's in the range of two nodes communicating (in-between,
>> but it doesn't forward packets to or from them, they are able to talk
>> directly)?
>> Thanks a lot
>>
>>
>
>
> -- 
> Mubashir Husain Rehmani 



Re: [ns] starting Cygwin in windows vista

2009-03-11 Thread hakki


Hi, I dowloaded all the packages in cygwin also `xinit`, however, while I
have been trying to install ns-2, it gives a such error " Xfree86 package is
not installed". I have never seen Xfree86 packages in setup of cygwin, I
downloaded all the packages. What do you offer?

best
hakki


trihedraldoc wrote:
> 
> Hi.
> I used ns-2 on Cygwin on XP. Worked like a charm,
> Now I am struggling with installing it on the newest cygwin running on
> vista home premium. However I am seeing some light after few trials.
> here's my suggestions
> 1- Install every package Cygwin offers (do not "hide obsolete" packages.
> you need those since they include the xorg libraries that are vital to
> ns-2)
> 2- when you installed all packages of cygwin you will see in your Windows
> start menu two entries
> -Cygwin
> -Cygwin-x
>   In Cygwin-x click on xwinserver and that opens the xterminal magically.
> 
> Good luck
> 
> 
> Bello Lawal wrote:
>> 
>> 
>> Hello,
>> Pls. am getting difficulities in starting cygwin in windows vista. Pls.
>> can some  one help?
>> 
>> Many thanks 
>> 
>> 
>> 
>>   
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/starting-Cygwin-in-windows-vista-tp20874488p22439492.html
Sent from the ns-users mailing list archive at Nabble.com.