OpenVPN UDP or TCP, Which is Better?

This question has been asked many times before. “Which is better for OpenVPN TCP or UDP” bluntly neither is better. TCP is more reliable than UDP however UDP performs better than TCP.

As TCP is a stateful protocol every packet that is sent requests that an acknowledgement “ACK” packet is received as a reply. This causes a greater overhead on TCP connections but does make them more reliable.

UDP on the other hand is a stateless protocol. This means that packets are sent and assumed that they are received the other end with no retry or acknowledgement. This will make UDP quicker than TCP but less reliable. On a network as big as the Internet there can often be packet loss. Each connection you initiate crosses many routers on many different ISP’s if one ISP is having some issues this may cause packet loss meaning your data does not get to its destination.

OpenVPN in UDP mode will resend data if it is not received at the other end as the encapsulated TCP / IP protocol will recognize the packet loss and try a retransmission of the data.

UDP SSL VPN’s are better for VoIP and Gaming traffic where as a TCP SSL VPN is better for overall reliability.

Conclusion:
For short distances between vpn server and client use UDP.
For long distances between vpn server and client use TCP.

This entry was posted in OpenVPN and tagged , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *


*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>