Using TCP Westwood protocol compilation error - networking

Hi Guys,
I'm working with a friend on network protocol simulation with ns-2,I'm new to this environment and facing some difficulties.
The one tutorial I used did this for the Westwood protocol, so I'll include my errors for that one just because it's a little simpler.
This is the guide I followed:
http://web.cs.ucla.edu/~nrl/hpi/tcpw/tcpw_ns2/tcp-westwood-ns2.html
Outline of steps:
Add tcp-westwood.cc & tcp-westwood.h files to tcp folder in
the main ns2 directory (ns-2.35)
Edit the makefile to include tcp-westwood.o file (within the obj_cc variable).
Add the appropriate lines to ns-default.tcl file (see link)
Recompile (recompile steps: go to ns-2.35 directory; type "./configure"; type
"make")
Goal:
To try out TCP Westwood protocol (a third party protocol source code) in ns-2 to simulate some network scenarios.
Problem:
When I run test.tcl using the Reno tcp protocol I get no errors. But when I change the line "set tcp [new Agent/TCP/Reno" to "set tcp [new Agent/TCP/Westwood" in the test.tcl file, I get the output from the screen shot (see attached).
I have upload code files here on google drive.
Any help or tip will be greatly appreciated.

Related

use mavlink without qgroundcontrol

I'm trying to conect my PX4Flow sensor to a raspberry pi. It seems that nearly everybody is using qgroundcontrol to access and control it. But as I'd like to integrate it into some bigger program, I'd like to control it with some self-written simple python code, if possible.
My aim is to:
access the camera (to measure the speed - later)
get gyrometer values
I don't need the ultra sonic sensor.
I found out that I can use MAVlink for the communication between the px4flow sensor and the raspberry pi. I cloned the git repository and followed the steps on https://github.com/mavlink/mavlink until the generation of header file (python -m mavgenerate). With that, I can generate a new python file. I don't know if this is correct, and I don't know what to do with that python file. No more file (header files) are copied or generated. How do I go on? How do I use the library? How do I even test the connection?
If I understand you correctly, you want to make a module to communicate with PX4Flow.
I have some experience in building a ground control station with ardupilot. I think the procedure is roughly the same:
Generate the proper mavlink library, what you have done by using mavgenerate. Read some guidance of mavlink communication procedure.
Read the source code in PX4Flow communication module https://github.com/PX4/Flow/blob/master/src/modules/flow/communication.c, which shows what kind of messages have been sent to client side (e.g. your communication module)
Start write the module code to communicate with PX4Flow. You may need to start with HEARTBEAT msg first to establish connections between your module and PX4Flow. Note that you can always receive HEARTBEAT messages from PX4Flow. You can start with decoding these ones.
Implement your other functionalities.
You can read sources code of QGourndControl during step 3 and step 4. Make sure to find the right module in its repo.
My communication module is built using JavaScript https://github.com/kvenux/nodegcs, if it helps.

how to transfer file between two local computers using grid-ftp

I want to do some measurements on file transfer protocols and I installed grid ftp on both computers that I have in lab which are in the same LAN.
I just want to transfer files between these two computers using grid-ftp protocol but when I use this command:
globus-url-copy sshftp://172.17.20.164/home/username/gridftp/1gbfile file:///home/
it gives me an error and says: error: an end of file was reached
globus_xio: An end of file was reached
172.17.20.164 is ip address for destination computer and 172.17.20.167 is ip for source.
I created end point on globus.org for both of the computers and both of the endpoints statuses are active.
I just don't know how to transfer a file between these two computers using grid-ftp. I will appreciate any kind of help. Thanks

how can I edit TCP protocol (tcp.cc)

My research is about minimizing End to End retransmission delay by touching Transport Layer Process to Process communication.
I did some changes to tcp.cc , changed window size. the changes i am doing are not affecting. ex: even if i removed tcp.cc file from NS2 folder but TCP topologies are still working, why is that?
Thanks!
Once you made any changes in .cc files then you have to run make command in your NS2.xx folder.

QualNet Simulator

I have two question about simulation on QulaNet simulator:
I want to build a network on QualNet Simulator, each node in this network send a message [application layer message] to other nodes in its range. I read in the manual there are two types of application layer protocol, one for generating traffic (ex: CBR), and one for application layer routing protocol(ex: BellmanFord), i wonder which type i should follow to apply what i mentioned in the first two lines.
I think there is no need to any routing protocol, in the GUI there is a "None" choice, but i didn't find the source code of it yet ! Where i can find it.
Thanks,
Dont confuse with Bellmanford and CBR protocols.Bellmanford is a routing protocol but they placed under Application layer for their programming convienience.
CBR is your actual Data traffic so you can see all the statistics related to your data traffic under cbr(client,server).When coming to network routing protocol in QulaNet if you did not configured any routing protocol by default it will take Bellmanford as routing protocol for which you can see the statistics under application layer.

How to configure FastRWeb to use RServer built-in web server

I'm new to RServe (and FastRWeb). I installed RServe 1.7.0 as I want to use its built-in webserver. As I already have apache running on this machine I want to run RServe/FastRWeb on a custom port.
I did cd /usr/local/lib/R/site-library/FastRWeb;sudo ./install.sh, which created /var/FastRWeb/ directory tree.
I'm not seeing any configuration file that mentions port. The default /var/FastRWeb/code/rserve.conf looks like this:
socket /var/FastRWeb/socket
sockmod 0666
source /var/FastRWeb/code/rserve.R
control enable
I'm guessing that means it uses unix sockets, by default? So I think my question is what exactly do I have to put in (and remove from) that file to, say, have it listen on TCP port 8888? And is there anything else I need to do? (I want to be able to connect from other machines, not just localhost.)
Possibly related, is I've looked at /var/FastRWeb/web/index.html and it contains javascript that is going to connect to /cgi-bin/R/ Is that path specific to when using Apache, or is it going to be fine, as-is, when using RServe?
There is an explanation of setting port in the Rserve 1.7.0 release announcement. Therefore, at the top of rserve.conf, I added this line: http.port 8888 Then I used the start script (as root), to start it.
This got me halfway as now http://127.0.0.1:8888/ works, but gives me a page that says:
Error in try(.http.request("/", NULL, NULL, c(48, 6f, 73, 74, 3a, 20, :
could not find function ".http.request"
The second half of the solution is to add this to the top of /var/FastRWeb/code/rserve.R:
library(FastRWeb)
.http.request <- FastRWeb:::.http.request
Then start things going by running /var/FastRWeb/code/start. There is no default handler, so you can test it with http://127.0.0.1:8888/info. Or a more interesting example is http://127.0.0.1:8888/example1.png (to view a chart) or http://127.0.0.1:8888/example2 (to view a mix of html and chart)
Note: I did not delete or edit any other configuration to get this working. That means we also have the unix socket listening. If that is not needed remove those two lines from the Rserve.conf file.
If you want it listening on all IP addresses, not just localhost, then add remote enable to your Rserve.conf file. NOTE: Make sure you understand the security consequences before opening your server to the world.
So, after those two changes, my /var/FastRWeb/code/Rserve.conf file looks like:
http.port 8888
remote enable
source /var/FastRWeb/code/rserve.R
control enable
Did you see Jay Emerson's write-up from a while back about how to use RServe as a backend for web-driven analysis? As I recall, one still uses Apache for the redirection, rather than an explicit port as you surmise here.
Jay's setup was very impressive. He used Rserve to provide mixed table/chart pages written via the grid package, all very slick and very fast, based of an immense data set (from a UN agency, or the World Bank, or something). But I can't find a link to that report right now...

Resources