I have a simple UDP client server written in C++ on Ubuntu 9.10 where the client sends a set to the server. How can I check how much time s it taking to sent it. I need to find the time from start of transfer to end.
Supposing my server and client are on the same machine then can I somehow save the system time and find the difference or something ?
If you are asking how long it takes for the packet to arrive at the server, there is no built in way to get that information.
If the server sends a reply, you can time how long it takes between sending the request and getting the reply and divide by 2 (not accurate, but a decent estimate).