RTPProxy is a software proxy delivering high-performance control to any kind of VoIP network infrastracture.

RTPProxy enables the following services in a VoIP network.

  1. VoIP calls to traverse NAT firewalls systems
  2. Packet flow optimization
  3. Relaying of voice, video or any RTP stream of data
  4. Playing of pre-encoded in-band announcements
  5. Re-framing of RTP payload
  6. Routing VoIP to VPN links routing
  7. Real-time stream copying

Install RTPProxy on CentOS 7.x using steps provided below:

  1. Change directory to /usr/src.
[root@kamailio-cloud ~]# cd /usr/src/
  1. Clone rtpproxy source from github.
[root@kamailio-cloud src]# git clone https://github.com/sippy/rtpproxy.git
Cloning into 'rtpproxy'...
remote: Counting objects: 8581, done.
remote: Total 8581 (delta 0), reused 0 (delta 0), pack-reused 8581
Receiving objects: 100% (8581/8581), 3.82 MiB | 561.00 KiB/s, done.
Resolving deltas: 100% (6205/6205), done.
[root@kamailio-cloud src]#
  1. cd into rtpproxy source tree.
[root@kamailio-cloud src]# cd rtpproxy/

4.Configure the source tree for installing rtpproxy

[root@kamailio-cloud rtpproxy]# ./configure
  1. Compile rtpproxy
[root@kamailio-cloud rtpproxy]# make
  1. Install Rtpproxy
[root@kamailio-cloud rtpproxy]# make install
  1. Copy init.d script to /etc/rc.d/init.d directory.
[root@kamailio-cloud rtpproxy]# cp rpm/rtpproxy.init /etc/rc.d/init.d/rtpproxy
  1. Make the file executable
[root@kamailio-cloud rtpproxy]# chmod +x /etc/rc.d/init.d/rtpproxy
  1. Add a user that will run the program. I will add user called rtpproxy and group called rtpproxy:
root@kamailio-cloud rtpproxy]# mkdir -p /var/run/rtpproxy
root@kamailio-cloud rtpproxy]# groupadd -g 8002 rtpproxy
root@kamailio-cloud rtpproxy]# useradd -u 8002 -g 8002 -d /var/run/rtpproxy -M -s /bin/false  rtpproxy
root@kamailio-cloud rtpproxy]# chown rtpproxy:rtpproxy -R /var/run/rtpproxy/
  1. Check the location of rtpproxy executable file
root@kamailio-cloud rtpproxy]# which rtpproxy
  1. Change rtpproxy=/usr/bin/rtpproxy to /usr/local/bin/rtpproxy, pidfile in /etc/rc.d/init.d/rtpproxy file
[root@kamailio-cloud rtpproxy]# nano /etc/rc.d/init.d/rtpproxy

Sample output is as shown:

# Source function library.
. /etc/rc.d/init.d/functionsopy
prog=rtpproxy
rtpproxy=/usr/local/bin/$prog
user=rtpproxy
lockfile=/var/lock/subsys/$prog
pidfile=/var/run/$prog.pid
  1. You can include Additional Options like:
OPTIONS=" -l 192.168.1.60 -s unix:/var/run/rtpproxy.sock"

Rtpproxy will listen on ip: 192.168.1.60 , control socket being unix:/var/run/rtpproxy.sock.
To make it listen on an UDP socket, add option:

CONTROL_SOCK=udp:127.0.0.1:7722

12 Reload and start rtpproxy

[root@kamailio-cloud rtpproxy]# systemctl daemon-reload 
[root@kamailio-cloud rtpproxy]# /etc/init.d/rtpproxy start
  1. To set to run at startup, type:
[root@kamailio-cloud rtpproxy]# chkconfig rtpproxy on

You are done with the installation. In case of any error, alert us via comment section.