Professional Documents
Culture Documents
TCP and UDP
TCP and UDP
Transmission Control Protocol (TCP) is connection-oriented, meaning once a connection has been
established, data can be transmitted in two directions. TCP has built-in systems to check for errors and
to guarantee data will be delivered in the order it was sent, making it the perfect protocol for
transferring information like still images, data files, and web pages.
But while TCP is instinctively reliable, its feedback mechanisms also result in a larger overhead,
translating to greater use of the available bandwidth on your network.
What is UDP?
User Datagram Protocol (UDP) is a simpler, connectionless Internet protocol wherein error-checking
and recovery services are not required. With UDP, there is no overhead for opening a connection,
maintaining a connection, or terminating a connection; data is continuously sent to the recipient,
whether or not they receive it.
Although UDP isn’t ideal for sending an email, viewing a webpage, or downloading a file, it is largely
preferred for real-time communications like broadcast or multitask network transmission.
Another notable discrepancy with TCP vs UDP is that TCP provides an ordered delivery of data from
user to server (and vice versa), whereas UDP is not dedicated to end-to-end communications, nor does
it check the readiness of the receiver (requiring fewer overheads and taking up less space).
Feature TCP UDP
Optimal use Used by HTTPS, HTTP, SMTP, POP, Video conferencing, streaming,
FTP, etc DNS, VoIP, etc
The reason for UDP’s superior speed over TCP is that its non-existent ‘acknowledgement’ supports a
continuous packet stream. Since TCP connection always acknowledges a set of packets (whether or
not the connection is totally reliable), a retransmission must occur for every negative
acknowledgement where a data packet has been lost.
But because UDP avoids the unnecessary overheads of TCP transport, it’s incredibly efficient in terms
of bandwidth, and much less demanding of poor performing networks, as well.
The flow controls from TCP, although dependable, are unable to recover missing data fast enough to
be useful in real-time video communications. And while data integrity is important, it has to be
balanced with speed to ensure the pace of communication remains unhindered.
That’s why the Lifesize web and desktop apps have been developed to prioritize UDP over TCP for
media transport, while our Icon meeting room systems exclusively use UDP for real-time media.
Additionally, Lifesize employs strategies like error concealment, error correction, and rate controls for
robust UDP media connections sans lags or latency.
Lifesize strongly recommends our customers enable access via UDP toward our cloud servers, as this
can help achieve the best user experience possible.
1. Open Lifesize
Open the Lifesize web or desktop app to get started. Lifesize supports a wide range of devices and
user preferences, with apps for PC and Mac computers, Android and iOS phones and tablets, and a
browser-based web app for any devices unable to download applications.
2. Choose preferences
Once you’re in the Lifesize app, you’ll want to choose your port preferences. To place calls to other
devices through a firewall, you need to configure your firewall to allow incoming and outgoing traffic
to the Lifesize system through the reserved TCP or UDP ports.
To minimize the number of UDP ports available for communication, you can restrict the range by
changing values in Preferences > Network > Reserved Ports. By default, Lifesize systems
communicate through ports in the range 60000 – 64999 for video, voice, presentations, and camera
control.
While Lifesize encourages users to stick to this range, you do have the ability to restrict the number of
UDP ports that are available. If the range you choose is not a subset of the default, be sure it begins
with a port number greater than 49151.
Additionally, the range has to start with an even number and end with an odd number to include an
even number of total ports. For example, if a range starts at 62000, set the lower end to 62000 and the
upper end to 62099 to allocate 100 ports (the required minimum).
Please note, changing the values in Reserved Ports will cause the system to restart.
This table is a great resource on the necessary firewall and proxy settings associated with UDP, as
you’ll need to configure your firewall to allow outbound access from your network to your UDP
ports. If you happen to have third-party integration for approved Cisco® and Polycom® devices, you
will be provided with an H.460 server IP address, as well.
Be sure to click Save on your updates. Successful proxy connection shows as Connected, but if your
proxy status shows Failed, it’s important to check your settings and try again.
4. Enable UDP
With UDP enabled on Lifesize, users can make the most of their video calls and conferencing, thanks
to 30 frames of video or more per second. This image-refresh interval is so fast, you won’t have to
wait for delayed data retransmissions, which means improvements in clarity, consistency, and
productivity all in one platform.
The first computer sends a packet with the SYN bit set to 111 (SYN =
"synchronize?"). The second computer sends back a packet with the ACK
bit set to 111 (ACK = "acknowledge!") plus the SYN bit set to 111. The
first computer replies back with an ACK.
The SYN and ACK bits are both part of the TCP header:
A diagram of the TCP header with rows of fields. Each row is 32 bits long.
The first row contains a 16-bit source port number and 16-bit destination
port number. The second row contains a 32-bit sequence number. The third
row contains a 32-bit acknowledgement number. The fourth row contains a
4-bit data offset number, 6 bits that are marked as reserved, 6 control bits
(URG, ACK, PSH, RST, SYN, and FIN), and a 16-bit window size
number. The fifth row contains a 16-bit checksum and 16-bit urgent
pointer. The header ends with options and padding which can be of
variable length.
The ACK and SYN bits are highlighted on the fourth row of the header.
The first computer sends a packet with data and a sequence number. The
second computer acknowledges it by setting the ACK bit and increasing
the acknowledgement number by the length of the received data.
The sequence and acknowledgement numbers are part of the TCP header:
A diagram of the TCP header with rows of fields. Each row is 32 bits long.
The first row contains a 16-bit source port number and 16-bit destination
port number. The second row contains a 32-bit sequence number. The third
row contains a 32-bit acknowledgement number. The fourth row contains a
4-bit data offset number, 6 bits that are marked as reserved, 6 control bits
(URG, ACK, PSH, RST, SYN, and FIN), and a 16-bit window size
number. The fifth row contains a 16-bit checksum and 16-bit urgent
pointer. The header ends with options and padding which can be of
variable length.
The 32-bit sequence and acknowledgement numbers are highlighted.
Those two numbers help the computers to keep track of which data was
successfully received, which data was lost, and which data was
accidentally sent twice.