[SR-Users] Learn Kamailio.cfg Basics

Gertjan Wolzak g.wolzak at foize.com
Mon Aug 19 16:18:27 CEST 2013


Hello Nishar,

 

Well, still take the kamailio config example, only change the Asterisk ip
address and port.

 

#!ifdef WITH_ASTERISK

asterisk.bindip = "192.168.178.25" desc "Asterisk IP Address"

asterisk.bindport = "5080" desc "Asterisk Port"

kamailio.bindip = "192.168.178.25" desc "Kamailio IP Address"

kamailio.bindport = "5060" desc "Kamailio Port"

#!endif

 

Let's assume that 192.168.175.25 is  your Kamailio server and asterisk has
the ip address 192.168.175.26 and asterisk listens on port 5060.

 

Then change the Kamailio config to :

 

#!ifdef WITH_ASTERISK

asterisk.bindip = "192.168.178.26" desc "Asterisk IP Address"

asterisk.bindport = "5060" desc "Asterisk Port"

kamailio.bindip = "192.168.178.25" desc "Kamailio IP Address"

kamailio.bindport = "5060" desc "Kamailio Port"

#!endif

 

The other thing you have to change is the mysql config on the Kamailio
server, but that's easy..

 

#!ifdef WITH_ASTERISK

#!define DBASTURL "mysql://asterisk:asterisk_password@localhost/asterisk"

#!endif

 

The above you will change to :

 

#!ifdef WITH_ASTERISK

#!define DBASTURL
"mysql://asterisk:asterisk_password@192.168.178.26/asterisk"

#!endif

 

 

Hope this helps.

 

Just remember these examples are for authentication against the Asterisk
database.

 

You can ofcourse do the authentication on Kamailio and dispatch the calls to
Asterisk, just make sure then that you creat a sip trunk on Asterisk and set
insecure=port,invite

 

Success.

 

 

 

From: sr-users-bounces at lists.sip-router.org
[mailto:sr-users-bounces at lists.sip-router.org] On Behalf Of Nishar M.H
Sent: maandag 19 augustus 2013 10:25
To: Kamailio (SER) - Users Mailing List
Subject: Re: [SR-Users] Learn Kamailio.cfg Basics

 

Thanks for the link.

from this document. I got some ideas and they have used a single server for
both Kamailio and Asterisk.

For me, i am trying to make individual server for Kamailio and Asterisk.

Now i am creating some cfg file and testing on it. I don't have much idea
about cfg but trying understand each line one by one. 

Thanks everyone for the support and reply. 

Regards,

Nishar Hamsa.



 

On Mon, Aug 19, 2013 at 10:12 AM, Gertjan Wolzak <g.wolzak at foize.com> wrote:

Hello Nishar,

 

Take a look at the Asipto Knowledgebase, they have good tutorials.

 

http://kb.asipto.com/asterisk:index

 

Good luck.

 

From: sr-users-bounces at lists.sip-router.org
[mailto:sr-users-bounces at lists.sip-router.org] On Behalf Of Nishar M.H
Sent: maandag 19 augustus 2013 6:40
To: Kamailio (SER) - Users Mailing List
Subject: Re: [SR-Users] Learn Kamailio.cfg Basics

 

Hi,

Which document did you follow ?

Can you share me the URL ?

I don't know from where i have to start. I have successfully installed and
configured kamailio server. Now i am able to register softphone to it. Now
my next step step is integration part with Asterisk Server. Here i am
struggling a  little bit and using individual servers(Two VMs) for Asterisk
and Kamailio for the testing.

Regards,

Nishar Hamsa.

 

On Sun, Aug 18, 2013 at 6:22 PM, Stoyan Mihaylov
<stoyan.v.mihaylov at gmail.com> wrote:

I successfully integrated Kamailio and Asterisk.

We started with pure kamailio and sip phones. I mean - kamailio and couple
of sip phones registered to it, calls between them etc.

Then we added Asterisk, forward from Kamailio to Asterisk and forward from
Asterisk to Kamailio.

In our case - Kamailio works as load-balance and for user registration. And
Asterisk do other  tasks. 

 

On Sun, Aug 18, 2013 at 1:25 PM, Nishar M.H <nisharmh85 at gmail.com> wrote:

Do you have cfg file that is connecting with Asterisk ?

As per my previous post in this forum i have created Trunk in Asterisk and
it shows registered.

Like :

kamailio                  192.168.20.208                               N
5060     OK (2 ms)

Like this how can i check In My kamailio server whether my Asterisk Server
is connected or not ?



 

 

Regards,

Nishar Hamsa

 

On Sun, Aug 18, 2013 at 2:20 PM, Salman Zafar <msalman212 at gmail.com> wrote:

You may have to restart Kamailio service to make your new changes
implemented from cfg.

 

On Sun, Aug 18, 2013 at 3:16 PM, Nishar M.H <nisharmh85 at gmail.com> wrote:

Thanks To all.

If i create a cfg file where can i compile the cfg file ?

http://sip-router.org/wiki/cookbooks/core-cookbook/devel

I am using this above the link for the basics.

Regards,

Nishar Hamsa.

 

 

On Sun, Aug 18, 2013 at 1:33 PM, Alex Balashov <abalashov at evaristesys.com>
wrote:

Nishar,



On 08/18/2013 04:59 AM, Nishar M.H wrote:

I am comfortable with Asterisk.
Here i am facing the issues with kamailio. Last few days i have been
struggling in kamailio integration with asterisk.
http://lists.sip-router.org/pipermail/sr-users/2013-August/079311.html
I couldn't understand anything about kamailio configuration.
So i want to learn about the .cfg file and the programming they have
used for.

 

Kamailio is a complex and esoteric piece of software, one that definitely
requires understanding of SIP protocol mechanics to grasp. Even so, it will
be a slow process, and requires patience above all else.  You shouldn't be
frustrated with yourself for not immediately comprehending everything.  Just
take it step-by-step, with the goal of learning more every day.

Cheers,

-- Alex

-- 
Alex Balashov - Principal
Evariste Systems LLC
235 E Ponce de Leon Ave
Suite 106
Decatur, GA 30030
United States
Tel: +1-678-954-0670 <tel:%2B1-678-954-0670> 
Web: http://www.evaristesys.com/, http://www.alexbalashov.com/



_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users at lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users






-- 


Thanks & Regards,

----------------------------------------------------------------------------
----------------


 
 
 
 
 

Nishar Hamsa








----------------------------------------------------------------------------
----------------
 
 
 
 
 
 


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users at lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




-- 

Regards

 

**************************
Muhammad Salman
***************************


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users at lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




-- 


Thanks & Regards,

----------------------------------------------------------------------------
----------------
 
 

Nishar Hamsa








----------------------------------------------------------------------------
----------------
 
 
 
 


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users at lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

 


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users at lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




-- 


Thanks & Regards,

----------------------------------------------------------------------------
----------------


 

Nishar Hamsa








----------------------------------------------------------------------------
----------------
 


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users at lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




-- 


Thanks & Regards,

----------------------------------------------------------------------------
----------------



Nishar Hamsa






----------------------------------------------------------------------------
----------------


 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20130819/41b67e5f/attachment-0001.html>


More information about the sr-users mailing list