Both sides previous revision
Previous revision
Next revision
|
Previous revision
Next revision
Both sides next revision
|
userdoc:tt_kamailio [2014/09/04 20:57] abelbeck |
userdoc:tt_kamailio [2014/09/07 08:09] abelbeck [Kamailio SIP Server] |
[[http://www.kamailio.org/|Kamailio]] (former OpenSER) is an Open Source SIP Server. | [[http://www.kamailio.org/|Kamailio]] (former OpenSER) is an Open Source SIP Server. |
| |
To know Kamailio is to know SIP. | "To know Kamailio is to know SIP." -- Fred Posner |
| |
| [[http://www.slideshare.net/oej/kamailio-a-quick-introduction|A Quick Introduction to Kamailio]], by Olle E Johansson |
| |
| <iframe src="//www.slideshare.net/slideshow/embed_code/16142201" width="427" height="356" frameborder="0" marginwidth="0" marginheight="0" scrolling="no" style="border:1px solid #CCC; border-width:1px; margin-bottom:5px; max-width: 100%;" allowfullscreen> </iframe> <div style="margin-bottom:5px"> <strong> <a href="https://www.slideshare.net/oej/kamailio-a-quick-introduction" title="Kamailio :: A Quick Introduction" target="_blank">Kamailio :: A Quick Introduction</a> </strong> from <strong><a href="http://www.slideshare.net/oej" target="_blank">Olle E Johansson</a></strong> </div> |
| |
!!Note: AstLinux 1.2.0 or later is required, with custom build!! | !!Note: AstLinux 1.2.0 or later is required, with custom build!! |
==== Initial Configuration ==== | ==== Initial Configuration ==== |
| |
The CLI (Command Line Interface) must be used to enable, and disable kamailio. Kamailio will be enabled if the ''/mnt/kd/kamailio/'' directory exists. On first install, issue the command... | The CLI (Command Line Interface) must be used to enable, and disable kamailio. Kamailio will be enabled if the ''/mnt/kd/kamailio/kamailio.cfg'' file exists. On first install, issue the command... |
| |
cp -a /stat/etc/kamailio /mnt/kd/ | cp -a /stat/etc/kamailio /mnt/kd/ |
| |
The ''/mnt/kd/kamailio/'' directory now exists, populated with a default configuration. Start kamailio with the following command, this will also create a symlink from ''/etc/kamailio/'' -> ''/mnt/kd/kamailio/'' ... | The ''/mnt/kd/kamailio/'' directory now exists, populated with a default configuration, including ''kamailio.cfg'' . Start kamailio with the following command, this will also create a symlink from ''/etc/kamailio/'' -> ''/mnt/kd/kamailio/'' ... |
| |
service kamailio init | service kamailio init |
INFO: Extra tables succesfully created. | INFO: Extra tables succesfully created. |
| |
At this point you can customize your kamailio configuration. Edit the /etc/kamailio/kamailio-local.cfg file to add switches such as "''#!define WITH_ASTERISK''" and interfaces to listen on. More details described below. Apply any edits to the files in ''/etc/kamailio/'' with the command... | At this point you can customize your kamailio configuration. Edit the /etc/kamailio/kamailio-local.cfg file to add switches such as "''#!define WITH_ASTERISK''" and interfaces/ip's to listen on. More detailed examples are described below. Apply any edits to the files in ''/etc/kamailio/'' with the command... |
| |
service kamailio restart | service kamailio restart |
| |
!!Tip ->!! The web interface may be used to Edit the configuration and Restart Kamailio. | !!Tip ->!! The web interface may be used to Edit the configuration and Restart Kamailio. |
| |
| While the default configuration files in the ''/stat/etc/kamailio/'' directory are typically only used one time for initial configuration, the files are a good reference using "''diff -u''" with your custom configuration. |
| |
==== Configuration Examples ==== | ==== Configuration Examples ==== |
| |
== Kamailio proxy's SIP but Asterisk does the RTP directly: == | \\ |
| **Kamailio proxy's SIP but Asterisk does the RTP directly:** |
| |
Example: EXTIP 10.10.50.65 - DNS 'pbx4', INTIP 192.168.110.1/24 network | Example: EXTIP 10.10.50.65 - DNS 'pbx4', INTIP 192.168.110.1/24 network |
udpbindaddr=0.0.0.0:5080 | udpbindaddr=0.0.0.0:5080 |
| |
!!Note ->!! Requires Pass EXT->Local UDP 10000-20000 (default asterisk rtp.conf range) | !!Note ->!! Requires firewall Pass EXT->Local UDP 10000-20000 (default asterisk rtp.conf range) |
| |
== Kamailio proxy's SIP and RTP using rtpproxy: == | \\ |
| **Kamailio proxy's SIP and RTP using rtpproxy:** |
| |
Example: EXTIP 10.10.50.65 - DNS 'pbx4', INTIP 192.168.110.1/24 network | Example: EXTIP 10.10.50.65 - DNS 'pbx4', INTIP 192.168.110.1/24 network |
!!Tip ->!! The 'rtpproxy' daemon is automatically started when ''WITH_NAT'' is defined. | !!Tip ->!! The 'rtpproxy' daemon is automatically started when ''WITH_NAT'' is defined. |
| |
!!Note ->!! Requires Pass EXT->Local UDP 16384-16639 (default rtpproxy range) | !!Note ->!! Requires firewall Pass EXT->Local UDP 16384-16639 (default rtpproxy range) |
| |