I recently published a new module for kamailio which allows it to connect to NATS and consume messages using queue groups NATS is a very cool distributed messaging system. One of my favorite things about NATS is, there are no brokers and it’s extremely easy to setup. You can setup a nats-server cluster in about […]
Category: Kamailio
I recently submitted a new module to the kamailio project which adds an interface to update/control presence records using json. Effectively, you can turn on/off a phone’s Busy Lamp Field (BLF) by sending an http request containing json body to kamailio. The following is a quick guide on how to set up kamailio to accept […]
This is a quick post on how to use keepalived to setup high-availability on two kamailio machines. In this setup there will be a “primary” and “secondary” node. Each node will be running kamailio and keepalived with a “shared” or sometimes referred to as a “floating” IP address. The idea is that each node will […]
This post will demonstrate how to run FreeSWITCH and Kamailio on a single server. FreeSWITCH will handle authentication and act as registrar while Kamailio will handle presence updates using the NSQ module. You might be wondering why this setup would be useful. The reason we found, is that FreeSWITCH is not so great at handling […]
This post explains how to setup Kamailio as an SBC and IP Gateway. We are using Debian 8 in this example. It uses Kamailio’s dispatcher module to distribute calls to Asterisk. It uses RTPEngine to proxy media to & from the public internet across the LAN to Asterisk. This is a powerful setup as you […]
In this setup, we will have 2 Kamailio servers, referred to as ‘nodes’. One will be active and one will standby. There is a 3rd ‘floating’ IP that is moved to which ever node is active. Kamailio should be configured to use the floating IP. In this example, the nodes are: kam01: 10.10.10.18 kam02: 10.10.10.19 […]
cd /usr/src/ git clone https://github.com/sippy/rtpproxy.git cd rtpproxy ./configure make make install cp scripts/rtpproxy.init.debian /etc/init.d/rtpproxy chmod +x /etc/init.d/rtpproxy sed -i “s/DAEMON=\/usr\/bin\/rtpproxy/DAEMON=\/usr\/local\/bin\/rtpproxy/g” /etc/init.d/rtpproxy cat > /etc/default/rtpproxy <<EOT # Defaults for rtpproxy # I like to use same user as Kamailio when running on Kamailio box USER=”kamailio” GROUP=”kamailio” PIDFILE=”/var/run/rtpproxy.pid” # replace with your network interface IP address LISTEN_ADDR=9.8.7.6 […]
Here we will compile and install Kamailio from GIT master branch and create our own systemd service configuration file. # install dependencies apt-get install libpq-dev pkg-config build-essential bison make libperl-dev git linux-headers-$(uname -r) libunistring-dev flex libjson-c-dev libevent-dev # download & compile cd /usr/src git clone git://git.sip-router.org/kamailio kamailio-git cd kamailio-git # include your own modules, these […]
In this example, I will share how to setup Kamailio to proxy SIP requests to a SIP switch (such as FreeSWITCH or Asterisk). 192.168.1.101 is the IP of Kamailio 192.168.1.102 is the IP of FreeSWITCH or Asterisk Here are snippets from the main config script, kamailio.cfg: … #!define IPADDRESS “192.168.1.101” #!define SWITCH_IPADDRESS “192.168.1.102” #!define FLAG_FROM_SWITCH […]