[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ns] large window size in satellite simulation



Hi, Everyone

I am a new ns user,and have some questions.

I try  TCP over satellite(GEO) simulation.
When I set large window, some packets drop.
Why do packets drop?

I use following scripts.
As the result of simulation of this script, 12packets dropped
consecutively after 4[sec] from ftp start.  
Could anyone tell me the reason ?

I wonder if this is concerned with "qlim"...

Thanks in advance.
Takeshi 


____
Takeshi KITAHARA <E-mail:[email protected]>


###########From here############
set ns [new Simulator]
$ns rtproto Dummy

set f [open free.tr w]
$ns trace-all $f

proc finish {} {
       global ns f  
       $ns flush-trace
       exit 0
}

proc dump { time src } {
	puts "[expr [ns now]+$time] [$src get cwnd]"
}

set opt(chan)           Channel/Sat
set opt(bw_up)          2Mb; 
set opt(phy)            Phy/Sat
set opt(mac)            Mac/Sat
set opt(ifq)            Queue/DropTail
set opt(qlim)           100
set opt(ll)             LL/Sat

	set n0 [$ns satnode-geo-repeater -150 $opt(chan)]

	set n1 [$ns satnode-terminal 37.9 -122.3]; 
	set n2 [$ns satnode-terminal 42.3 -71.1]; 

	$n1 add-gsl geo $opt(ll) $opt(ifq) $opt(qlim) $opt(mac) $opt(bw_up) \
            $opt(phy) [$n0 set downlink_] [$n0 set uplink_]
	$n2 add-gsl geo $opt(ll) $opt(ifq) $opt(qlim) $opt(mac) $opt(bw_up)  \
	    $opt(phy) [$n0 set downlink_] [$n0 set uplink_]
	
        $ns trace-all-satlinks $f
 
  	set tcp0 [new Agent/TCP/Reno]
	$ns attach-agent $n1 $tcp0
	$tcp0 set window_ 125

	set ftp0 [new Application/FTP]
	$ftp0 attach-agent $tcp0

	set tcp_sink0 [new Agent/TCPSink]
	$ns attach-agent $n2 $tcp_sink0

	$ns connect $tcp0 $tcp_sink0
	$ns at 0.0 "$ftp0 start"

	set satrouteobject_ [new SatRouteObject]
	$satrouteobject_ compute_routes

for { set i 0 } { $i < 61 } { incr i } {
	$ns at $i "dump $i $tcp0"
}        
        $ns at 60.0 "finish"

	$ns run
###############Till here##################