I dont know about siremis, but you can forward calls to different groups of Asterisk servers - using <br>ds_select_dst(<a name="AEN140" style="font-family:Helvetica,Arial;font-size:15px;font-style:italic;font-weight:bold;background-color:rgb(255,255,255);text-decoration:none"><code class="FUNCTION">set, alg</code></a>);<div>
Where set is set of Asterisk servers - you can check that module.</div><div>The problem is - I have no idea how you can select different sets in kamailio.cfg, except by length, or some matching pattern in CallerID.</div><div>
But if you put whole logic used in Asterisk in DB - then you dont care which server will take the call, because you can put whole logic purely in DB - including extensions etc.</div><div>At least I prefer to have almost nothing in extensions.conf - and everything to stay either in DB or in AGI scripts.</div>
<div><br></div><div>My knowledge of Kamailio is very very basic - I know only few things there.</div><div>Asterisk and Kamailio can run on same server, but I cant see any reason for that. I mean you will have lot of troubles in such case, and nothing &quot;good&quot;. This is only if you want to make some tests. But you can expect lot of troubles.</div>
<div><br><div><br><div class="gmail_quote">On Fri, Feb 3, 2012 at 9:40 PM, Greg Mannie <span dir="ltr">&lt;<a href="mailto:greg@latigi.com">greg@latigi.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Thank you for your detailed response.  Sorry for the trouble but would you be able to also answer the following.<br>
<br>
Do you know if this same type of deployment would be suited to our needs.  Many of the Asterisk servers we host are for clients, who have their own extensions, voicemail, ivr etc.  I was hoping I could setup routes on the kamailio and direct them to the appropriate asterisk server.<br>

<br>
Initially I thought it would be as simple as setting up an inbound route on Asterisk. Ha..  I also installed siremis 3.2 and perhaps reading on how to use it will provide clearer details.<br>
<br>
I know so little, I&#39;m not even sure if I need to have Kamailio and Asterisk running on the same server, since I only want Kamailio as a proxy.<br>
<br>
<br>
Regards,<br>
<br>
Greg<br>
<br>
<br>
Quoting Stoyan Mihaylov &lt;<a href="mailto:stoyan.v.mihaylov@gmail.com" target="_blank">stoyan.v.mihaylov@gmail.com</a>&gt;:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">
We were in similar situation. Many years with Asterisk and then we were<br>
forced to use ser - and we preferred Kamailio.<br>
Now we do:<br>
Kamailio has global IP address and clients register to it.<br>
Kamailio forward all calls to Asterisk boxes using following:<br>
  ds_select_dst(&quot;1&quot;,&quot;4&quot;);#You can use many asterisk boxes this way<br>
  $sht(forw=&gt;$ft)=$du; #this way I store used path<br>
I used t_relay, instead of forward, because my Asterisks are with local IP.<br>
Calls from Asterisk are send to Kamailio if they are to local user, or to<br>
our SIP provider. There are no problems with calls from Asterisk to SIP<br>
provider, even if Asterisk is behind NAT.<br>
Asterisk accepts calls from SIP provider though registrar lines in<br>
sip.conf. Asterisk can forward calls from our SIP provider to  local users<br>
in Kamailio.<br>
I got problems with ACK and BYE. To solve them, I used<br>
if(($td==&quot;<a href="http://sip.name.of.kamailio.server.com" target="_blank">sip.name.of.<u></u>kamailio.server.com</a>&quot;)||($si==&quot;<u></u>IPofServer&quot;)){<br>
  $du=$sht(forw=&gt;$ft);<br>
}<br>
<br>
On Fri, Feb 3, 2012 at 8:13 PM, Greg Mannie &lt;<a href="mailto:greg@latigi.com" target="_blank">greg@latigi.com</a>&gt; wrote:<br>
<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">
Hello<br>
<br>
After much reading I have come to the realization that after years of<br>
using Asterisk I know very little about Sip.<br>
<br>
I have my Kamailio box up, I have Asterisk 1.8.x running with realtime<br>
working.  I thought it would be just a case of registering SIP trunks from<br>
my provider to the kamailio and registering our internal asterisk servers<br>
to the kamailio.<br>
<br>
Much of what I read talks about using Asterisk as the PSTN interface, but<br>
that interface is through a sip trunk purchased from a provider.  Won&#39;t<br>
Kamailio be the PSTN gateway?  The idea here is to pool all the sip trunks<br>
from the various hosted asterisk solutions (VM running asterisk) and point<br>
them all to a proxy to facilitate the aggregation of traffic.<br>
<br>
I have been reading SIP tutorials and the mailing list archives.  If<br>
anyone has a sample config and perhaps a little direction it would be<br>
highly appreciated.<br>
<br>
Thank you<br>
<br>
Greg<br>
<br>
<br>
<br>
<br>
<br></div></div>
______________________________<u></u>**_________________<div class="im"><br>
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a><br>
</div><a href="http://lists.sip-router.org/**cgi-bin/mailman/listinfo/sr-**users" target="_blank">http://lists.sip-router.org/**<u></u>cgi-bin/mailman/listinfo/sr-**<u></u>users</a>&lt;<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.<u></u>org/cgi-bin/mailman/listinfo/<u></u>sr-users</a>&gt;<br>

<br>
</blockquote>
<br>
</blockquote><div class="HOEnZb"><div class="h5">
<br>
<br>
<br>
______________________________<u></u>_________________<br>
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a><br>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/<u></u>cgi-bin/mailman/listinfo/sr-<u></u>users</a><br>
</div></div></blockquote></div><br></div></div>