Openvpn tcp or udp (specific situation, reliability-layer collisions)

openvpntcpudp

My question is whether to use TCP of UDP for my OpenVPN connection.
I've set up a simple network for a startup company that allows users from the outside to access the network via an OpenVPN server (in routing mode). The only thing users will do with the vpn is accessing files.

The priority is to keep the integrity of the files intact. With that in mind, should I use the UDP of TCP protocol for my vpn tunnel? I've read up on reliability-layer collisions (i.e. on http://openvpn.net/index.php/open-source/documentation/security-overview.html), but since tcp, the openvpn transport layer and the tunneled TCP session can all provide the reliability checks for me, so it leaves me wondering what would work best for me.

So, should I use TCP or UDP in this situation?

Best Answer

UDP. Always UDP for tunneled connections if you can swing it from a network/firewall perspective. The underlying TCP flows will take care of retries if necessary. If you used TCP at the OpenVPN layer, you end up in a situation where both layers can send duplicate packets in the case of loss. This can cause significant performance problems.

Related Topic