README 1.47 KB
Newer Older
1
For NSE integration and traffic generation, we need the following files
2
3
4
5
as part of the FBSD disk image or it should be part of 
/usr/testbed/sup/sup/FBSD43-STD/root*/etc/testbed on the boss node.

a) nseinput.tcl and startnse present in this directory
6
7
b) NSE executable file. To build it the first time, chdir to
   this directory. Then do a
8

9
10
11
   ./nse-install

c) Then do a
12
   cp nse nseinput.tcl startnse <sup_directory>
13

14
15
16
The current NSE trafgen comes with a major caveat:

0) It comes with all the bugs and idiosyncrasies of the FullTcp, FTP and
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
   Telnet models in NS.

Here is an example scenario:

source tb_compat.tcl
set ns [new Simulator]

#Create four nodes
set nodeA [$ns node]
set nodeB [$ns node]

$ns duplex-link $nodeA $nodeB 100Mb 0ms DropTail

##### ftp0
set tcp0 [new Agent/TCP/FullTcp/Tahoe]
$ns attach-agent $nodeA $tcp0
set ftp0 [new Application/FTP]
$ftp0 attach-agent $tcp0

set tcp1 [new Agent/TCP/FullTcp/Sack]
$ns attach-agent $nodeB $tcp1
$tcp1 listen

#Connect the traffic sources with the traffic sink
$ns connect $tcp0 $tcp1  

##### telnet0
set tcp2 [new Agent/TCP/FullTcp/Newreno]
$ns attach-agent $nodeB $tcp2
set telnet0 [new Application/Telnet]
$telnet0 attach-agent $tcp2

set tcp3 [new Agent/TCP/FullTcp]
$tcp3 listen
$ns attach-agent $nodeA $tcp3

$ns connect $tcp2 $tcp3

55
56
57
58
59
60
$ns at 30.0 "$ftp0 start"
$ns at 120.0 "$ftp0 stop"
$ns at 60.0 "$telnet0 start"
$ns at 90.0 "$tcp2 set segsize_ 256; $tcp3 set segsize_ 512"
$ns at 150.0 "$telnet0 stop"

61
62
#Run the simulation
$ns run