Hellow Folks

It's really urgent i need a help, i don't know what's wrong i am getting
this error while runing .tcl script for nse.

root@bipul-Linux:/home/bipul/Desktop# nse Emulation1.tcl
warning: no class variable Scheduler/RealTime::adjust_new_width_interval_

    see tcl-object.tcl in tclcl for info about this warning.

warning: no class variable Scheduler/RealTime::min_bin_width_

TapAgent(_o40): linked sock 6 as READABLE
TCPTapAgent(_o43): sent packet (sz: 40)
TCPTapAgent(_o43): sent packet (sz: 40)
TCPTapAgent(_o43): sent packet (sz: 40)


bipul@bipul-Linux:~/Desktop$ cat out.tr
+ 0.010148 2 1 tcp 40 ------- 0 2.0 1.0 0 0
- 0.010148 2 1 tcp 40 ------- 0 2.0 1.0 0 0
r 0.011184 2 1 tcp 40 ------- 0 2.0 1.0 0 0
+ 3.010266 2 1 tcp 40 ------- 0 2.0 1.0 0 1
- 3.010266 2 1 tcp 40 ------- 0 2.0 1.0 0 1
r 3.011308 2 1 tcp 40 ------- 0 2.0 1.0 0 1
+ 9.010389 2 1 tcp 40 ------- 0 2.0 1.0 0 2
- 9.010389 2 1 tcp 40 ------- 0 2.0 1.0 0 2
r 9.011431 2 1 tcp 40 ------- 0 2.0 1.0 0 2

Below is my code. for nse

set ns [new Simulator]
$ns use-scheduler RealTime

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

set entry_node [$ns node]
set exit_node [$ns node]
set tcp_node [$ns node]

$ns simplex-link $entry_node $tcp_node 10Mb 1ms DropTail
$ns simplex-link $tcp_node $exit_node 10M 1ms DropTail

# Configure the entry node
set tap1 [new Agent/TCPTap];               # Create the TCPTap Agent
set bpf [new Network/Pcap/Live];           # Create the bpf
set dev [$bpf open readonly eth0]
$bpf filter "src 113.19.128.48 and src port 80 and dst 113.19.128.60 and
dst port 16384"
$tap1 network $bpf;                        # Connect bpf to TCPTap Agent
$ns attach-agent $entry_node $tap1;        # Attach TCPTap Agent to the node

# Configure the exit node
set tap2 [new Agent/TCPTap];       # Create a TCPTap Agent
set ipnet [new Network/IP];        # Create a Network agent
$ipnet open writeonly
$tap2 network $ipnet;              # Connect network agent to tap agent
$tap2 advertised-window 512
$tap2 extipaddr "113.19.128.48"
$tap2 extport 80
$ns attach-agent $exit_node $tap2;        # Attach agent to the node.

# Configure the TCP agent
set tcp [new Agent/TCP/FullTcp]
$ns attach-agent $tcp_node $tcp

# Connect the agents.
$ns simplex-connect $tap1 $tcp
$ns simplex-connect $tcp $tap2


$ns at 0.01 "$tcp advance 1"
$ns at 20.0 "finish"

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

$ns run


I hope i will get the answer soon

Thank you.

Reply via email to