Configure turn server for WebRTC on Amazon EC2

Datetime:2016-08-22 22:57:04          Topic:          Share

As we all know, WebRTC is used for video communication.

In video communication, data packets are transferred from one place to another place, therefore a user is able to see other user’s streaming.

But sometimes, when there are some network securities like firewall, then data packet does not transfer and we do not get proper streaming of another user i.e. we get black screen as other user’s stream.

So for this solution, we use turn server.

The TURN Server is a VoIP media traffic NAT traversal server and gateway. It can be used as a general-purpose network traffic TURN server and gateway, too.

Here, I am going to explain you the steps of installing and configuring turn server on Amazon EC2.

First of all download these 2 packages :

libevent-2.0.21-stable.tar.gz ( http://libevent.org/ )

turnserver-2.6.5.2.tar.gz ( https://code.google.com/p/rfc5766-turn-server/downloads/list )

then run these commands :

1. To install libevent package

$ tar xvfz libevent-2.0.21-stable.tar.gz

$ cd libevent-2.0.21-stable