Pages

Saturday, April 30, 2011

TCP VS UDP & IP Topics

Can you explain the difference between UDP and TCP internet protocol (IP) traffic and its usage with an example?
A. Transmission Control Protocol (TCP) and User Datagram Protocol (UDP)is a transportation protocol that is one of the core protocols of the Internet protocol suite. Both TCP and UDP work at transport layer TCP/IP model and both have very different usage.

Difference between TCP and UDP

TCP
UDP
Reliability: TCP is connection-oriented protocol. When a file or message send it will get delivered unless connections fails. If connection lost, the server will request the lost part. There is no corruption while transferring a message.
Reliability: UDP is connectionless protocol. When you a send a data or message, you don't know if it'll get there, it could get lost on the way. There may be corruption while transferring a message.
Ordered: If you send two messages along a connection, one after the other, you know the first message will get there first. You don't have to worry about data arriving in the wrong order.
Ordered: If you send two messages out, you don't know what order they'll arrive in i.e. no ordered
Heavyweight: - when the low level parts of the TCP "stream" arrive in the wrong order, resend requests have to be sent, and all the out of sequence parts have to be put back together, so requires a bit of work to piece together.
Lightweight: No ordering of messages, no tracking connections, etc. It's just fire and forget! This means it's a lot quicker, and the network card / OS have to do very little work to translate the data back from the packets.
Streaming: Data is read as a "stream," with nothing distinguishing where one packet ends and another begins. There may be multiple packets per read call.
Datagrams: Packets are sent individually and are guaranteed to be whole if they arrive. One packet per one read call.
Examples: World Wide Web (Apache TCP port 80), e-mail (SMTP TCP port 25 Postfix MTA), File Transfer Protocol (FTP port 21) and Secure Shell (OpenSSH port 22) etc.
Examples: Domain Name System (DNS UDP port 53), streaming media applications such as IPTV or movies, Voice over IP (VoIP), Trivial File Transfer Protocol (TFTP) and online multiplayer games etc

Further readings

UDP is the faster protocol as it doesn't wait for acknowledgement so it is not at all having reliability as  compared to TCP.

Bridging the Analog-IP Gap

The name "encoder" does not really do these technological miracles justice. These investment-protecting, budget-saving marvels build a bridge between two generations of surveillance technology and bring harmony to your network.

IP-based video surveillance systems bring many important benefits. The image quality they deliver is a vast improvement. The networks are more scalable and cheaper to run. Better still, computerization means you can automate systems to bring about event management and intelligent video. Nevertheless, it is too early to claim that this development has rendered analog CCTV surveillance systems obsolete.

One option to installers would be to replace everything analog. This would mean getting rid of the existing analog cameras, the coaxial cables that have been laid inside and outside the buildings, the recording systems (AVRs or DVRs) and the management system. It would then be necessary to introduce an entirely new Ethernet cabling infrastructure, which would involve not insubstantial disruption, along with new IP-compatible storage hardware and a management system suited to IP or network video.

In many cases, that would be a waste of time and money, and the people who bought analog systems are not going to write off their investment any time soon, especially when around 95 percent of the estimated 40 million surveillance cameras installed in the world are still analog.

While analog technology is being fast eclipsed by IP video, which is growing at 30 percent a year according to IMS Research, there is no reason why the two infrastructures cannot be rationalized together, apart from a few technological hurdles. These barriers to integration are, in most cases, easily surmountable.

For most installations, the most valuable service you can offer your clients is to migrate them from analog to IP video by making judicious use of their existing network. The key to this magic passage is the video encoder. Encoders help convert analog networks into IP-friendly formats, putting the existing investment in cameras and coaxial cable to good use.

4 comments: