after install some new protocol in ns2.35, it appears some mistake when i run the tcl file
i install ns2.35 with cygwin and i followed the guide of the site below
http://www.comp.sd.tmu.ac.jp/kazuyas...s2_greedy.html when i install the greedy protocol successful and turn to test it , the result was show as below: $ ns greedy.tcl num_nodes is set 7 INITIALIZE THE LIST xListHead Starting Simulation... channel.cc:sendUp - Calc highestAntennaZ_ and distCST_ highestAntennaz_ = 1.5 , distCST_ = 550.0 SORTING LISTS...DONE! after that ,when i open the nam file ,it has nothing but the topology, i mean , it doesn't contain any communicate process. i don't know why. and when i use the greedy protocol the tcl file i write ,it does't work either. could anyone help me? thx a lot! by the way , i am new to ns2 and English is not my mother language. thank you for your time. |
Welcome to LQ.
Quote:
More complex ? Then you will have to edit greedy.tcl, or write a new file.tcl . Or even better : Use another "greedy protocol" like the versatile GPSR-hls. GPSR : "Greedy Perimeter Stateless Routing" GPSR info, see posts #2 and #3 here ... http://www.linuxquestions.org/questi...-4175528835/#2 Examples : gpsr-hls-examples-03.15.tar.gz https://drive.google.com/file/d/0B7S...ew?usp=sharing - |
Quote:
But i still fell confused with something. Would please explain what is the protocol works in ns2? my point is that : when i simulate the aodv sample successful, and then only change the protocol to greedy and simulator it again ,the xwin tells me Invalid flow. if you want see the tcl file, just tell me. i don't know what if i described clearly. anyway, thank you vary much . |
Re #3.
A random file.tcl cannot be used with : set val(rp) GREEDY Please have another look at greedy.tcl : Three files are used >>> 1) greedy.tcl 2) nbr.tcl : A configuration file. 3) topo2.txt : A traffic / scene file. - |
Quote:
but when i turn to the gpsr i found i have the same problem with someone you ever help. http://www.linuxquestions.org/questi...-a-4175528835/ but i still fell confused, should i install some new ns2.35 ? in the link http://network-simulator-ns-2.7690.n...g-td29371.html i can't follow the code because i do not use linux $ cp ns ns-gpsr-hls $ sudo cp ns-gpsr-hls /usr/local/bin/ so i just cope the hls-example file to /usr/local/ after that when i run ssoumayaa.tcl ,the xwin hints me that Segmentation fault(core dumped) was that(directly cope) cause the error? |
Re #5.
Segmentation fault : Probably caused by a 64bits Cygwin. Ns2 is for a 32bits OS. Suggest : Install 'VirtualBox' in Windows 7. And then install a genuine 32bits 'Linux OS' into VirtualBox. Re http://network-simulator-ns-2.7690.n...g-td29371.html * In /home/<name>/ : $ tar xvf ns-allinone-2.35_gcc482.tar.gz (ns-2.35 patched for gcc-4.6.. -4.9.2) https://drive.google.com/file/d/0B7S...ew?usp=sharing $ cd ns-allinone-2.35/ $ patch -p0 < GPSR-hls_ns235.patch https://drive.google.com/file/d/0B7S...ew?usp=sharing $ ./install $ cd ns-2.35/ $ cp ns ns-gpsr-hls $ sudo cp ns-gpsr-hls /usr/local/bin/ ... Then you can do: $ ns-gpsr-hls ssoumayaa.tcl ... from the examples, gpsr-hls-examples-05.14.tar.gz https://drive.google.com/file/d/0B7S...ew?usp=sharing The examples can be kept in / used from any folder in /home/<name>/. - |
Quote:
because my windows is 32bits, so the cygwin i installed is 32bits too. maybe i miss something else. should i modified some files in the ns2.35 as well as i install the greedy protocol ? it seems that the patch has deleted the modifying which i made for greedy protocol. maybe it is the problem laid? |
1 Attachment(s)
Quote:
does it means that what i have done is work? |
Re #8.
No images for text, please. HOWTO create a file "result.txt" (Or whatever file name you want) : $ ns ssoumayaa.tcl 2>&1 | tee result.txt - |
Quote:
maybe you misunderstand what i mean. in my opinion , the xwin do not throw any erro and the nam file has create successfully. even though i don't know what situation does the nam file described, but at least it runs. and does all above means that the ssoumayaa.tcl run correct ? or is the ssoumayaa runs success in an other way, doesn't like what i post? thanks a lot. knudfl! |
Re #10.
An OK simulation $ ns ssoumayaa.tcl .. will create the files fangzhen1.nam ~110kb, fangzhen1.tr ~175kB. And the terminal text is : Code:
[knudfl@localhost test__hls-utils]$ ns235-gpsr-hls ssoumayaa.tcl |
Quote:
by the way , you are awesome and i still use cygwin. well, would please tell me what's the tr file's formart so i can analyze it. such as the delay, delay jitter , the rate of the package loss and the energy consumption. or something else. |
Re #12.
NS-2 Trace Formats http://nsnam.isi.edu/nsnam/index.php/NS-2_Trace_Formats Analyzing tools : ns-2.3x/hls/utils/{evaluate.pl, evFromdirectory.pl, gls_evaluate.pl, runfromdirectory.pl} * Also included in gpsr-hls-examples-05.14.tar.gz . Using : $ perl <script>.pl fangzhen1.tr More scripts for analyzing : awk-and-perl_scripts_12.2014.tar.gz https://drive.google.com/file/d/0B7S...ew?usp=sharing - |
Quote:
for example , i'd like to use evaluate.pl to evaluste the tr file do you mean using: $ perl evaluate.pl fangzhen1.tr ? but this did't work for me unless i use : perl evaluate.pl -f fangzhen1.tr for instead. dose the evaluate.pl test the move speed , and the evFromdirectory.pl and runfromdirectory.pl is the recursive of evaluate.pl ? i can't get it. it is my first time to use perl, so i just google something. thanks. |
Quote:
then i turn to KeLiu-gpsr, after install successfully, i found i can even hardly create nodes. when i use the code Code:
for {set i 0} {$i < $opt(nn) } {incr i} { would you please give me some advice? |
All times are GMT -5. The time now is 09:59 AM. |