<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi,<div class=""><br class=""></div><div class="">Developing such a solution is going to be quite complicated any way you look at it, and will require deep understanding of a number of things in order to operate it, and there are a number of tradeoffs you’ll need to make based on your exact use case. I don’t think a mailing list discussion is a going to get you the skills required to build a solution like this - you have quite a bit of study ahead of you.<div class=""><br class=""></div><div class="">However, if you cannot use DNS (why?) I can think of a few other options - these are presented merely as a starting point for your investigations - you’ll need to have a strong understanding of these in order to make decisions about which is appropriate for you:</div><div class="">1) Anycast - this uses IP routing to get to the closest instance of an IP address. You might want to combine that with a redirect if the message is sent to the anycast IP, to have the client do subsequent things by talking to the “real” IP of the server.</div><div class="">2) Use geoip to figure out where a user is, and redirect them to the closest instance if they are not already talking to that. Client will need to be configured to one of the servers? Or all of them with some sort of preference? Not sure what is appropriate for you here.</div><div class="">3) Use geoip like (2) but with a single central server, which replies with 301. This may work for some use cases - i.e. inbound heavy, and may not work with all clients.</div><div class=""><br class=""></div><div class="">There are a bunch of considerations - for example, what is “closest” ? I don’t expect you to answer that to me, but, you will need to have a clear definition before you can embark on this project.</div><div class=""><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 9/06/2017, at 6:30 PM, 赵国杰 <<a href="mailto:zhaoguojie2010@163.com" class="">zhaoguojie2010@163.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div style="line-height: 1.7; font-size: 14px; font-family: Arial;" class=""><div class="">That's the thing. I'm not be able to use dns, just raw ip.<br class=""><br class="">Cheers,<br class="">Jesse<br class=""></div><div id="divNeteaseMailCard" class=""></div><br class="">在 2017-06-09 14:24:33,"David Villasmil" <<a href="mailto:david.villasmil.work@gmail.com" class="">david.villasmil.work@gmail.com</a>> 写道:<br class=""> <blockquote id="isReplyContent" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid" class=""><div dir="ltr" class="">You'd need geographical dns resolution, the dns returns the ip closest to the request's location... I thought that's how you're deciding what ip to give to the users...</div><div hspace="streak-pt-mark" style="max-height:1px" class=""><img alt="" style="width:0px;max-height:0px;overflow:hidden" src="https://mailfoogae.appspot.com/t?sender=aZGF2aWQudmlsbGFzbWlsLndvcmtAZ21haWwuY29t&type=zerocontent&guid=792e12b0-7d27-4fa5-9342-f729bc0bff25" class=""><font color="#ffffff" size="1" class="">ᐧ</font></div><div class="gmail_extra"><br clear="all" class=""><div class=""><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr" class=""><div class="">Regards,</div><div class=""><br class=""></div>David Villasmil<div class="">email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank" class="">david.villasmil.work@gmail.com</a></div><div class="">phone: +34669448337</div></div></div></div>
<br class=""><div class="gmail_quote">On Fri, Jun 9, 2017 at 2:20 AM, 赵国杰 <span dir="ltr" class=""><<a href="mailto:zhaoguojie2010@163.com" target="_blank" class="">zhaoguojie2010@163.com</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="line-height: 1.7; font-size: 14px; font-family: Arial;" class=""><div class="">Hi David,<br class="">     Does that mean the user send the request to a randomly selected kamailio first, and then use it as a hop to direct to the closest one? How can I direct the users to their closest kamailio? Is there any doc that I can refer to ??<br class=""><br class="">Thanks<br class="">Jesse<br class=""></div><div class=""><div class="h5"><div id="m_7843372897678189064divNeteaseMailCard" class=""></div><br class="">在 2017-06-09 14:09:51,"David Villasmil" <<a href="mailto:david.villasmil.work@gmail.com" target="_blank" class="">david.villasmil.work@gmail.<wbr class="">com</a>> 写道:<br class=""> <blockquote id="m_7843372897678189064isReplyContent" style="PADDING-LEFT:1ex;MARGIN:0px 0px 0px 0.8ex;BORDER-LEFT:#ccc 1px solid" class=""><div dir="ltr" class="">You can use the <div class="">alias=udp:myglobaldomain:5060</div><div class=""><br class=""></div><div class="">to use a single domain, and direct the users to their closest ip.</div></div><div hspace="streak-pt-mark" style="max-height:1px" class=""><img alt="" style="width:0px;max-height:0px;overflow:hidden" src="https://mailfoogae.appspot.com/t?sender=aZGF2aWQudmlsbGFzbWlsLndvcmtAZ21haWwuY29t&type=zerocontent&guid=81b960a6-9f25-4626-9cc1-ef7e787df6e7" class=""><font color="#ffffff" size="1" class="">ᐧ</font></div><div class="gmail_extra"><br clear="all" class=""><div class=""><div class="m_7843372897678189064gmail_signature" data-smartmail="gmail_signature"><div dir="ltr" class=""><div class="">Regards,</div><div class=""><br class=""></div>David Villasmil<div class="">email: <a href="mailto:david.villasmil.work@gmail.com" target="_blank" class="">david.villasmil.work@gmail.com</a></div><div class="">phone: <a href="tel:+34%20669%2044%2083%2037" value="+34669448337" target="_blank" class="">+34669448337</a></div></div></div></div>
<br class=""><div class="gmail_quote">On Fri, Jun 9, 2017 at 1:59 AM, 赵国杰 <span dir="ltr" class=""><<a href="mailto:zhaoguojie2010@163.com" target="_blank" class="">zhaoguojie2010@163.com</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="line-height: 1.7; font-size: 14px; font-family: Arial;" class=""><div class="">hello David,<br class="">    I want the user to register to the kamailio server which is closest to the user. Each user(aka subscriber) has a unique domain, but my kamailio servers have 10 different domains which are their public ip. Let's say, based on user's ip, the closest kamailio server's domain is 35.185.3.4. I can use the one account which has the domain 35.185.3.4 to register to that kamailio server. I don't think I can do that with just 1 account. If i'm wrong, please tell me the write way.<br class=""><br class="">Thanks<br class="">Jesse<br class=""></div><div class=""><div class="m_7843372897678189064h5"><div id="m_7843372897678189064m_-4770366159232173140divNeteaseMailCard" class=""></div><br class="">在 2017-06-08 22:46:33,"David Villasmil" <<a href="mailto:david.villasmil.work@gmail.com" target="_blank" class="">david.villasmil.work@gmail.co<wbr class="">m</a>> 写道:<br class=""> <blockquote id="m_7843372897678189064m_-4770366159232173140isReplyContent" style="PADDING-LEFT:1ex;MARGIN:0px 0px 0px 0.8ex;BORDER-LEFT:#ccc 1px solid" class="">Sorry, i have to ask: why not just 1 account for all servers? There are many solutions to replicate the dbs, share the dbs amongst all kamailios, etc... just wondering <br class=""><div class="gmail_quote"><div dir="ltr" class="">On Thu, Jun 8, 2017 at 8:42 AM <a href="mailto:zhaoguojie2010@163.com" target="_blank" class="">zhaoguojie2010@163.com</a> <<a href="mailto:zhaoguojie2010@163.com" target="_blank" class="">zhaoguojie2010@163.com</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi all.<br class="">
    I have 10 kamailio servers across the world. Each of them has a public ip which is also their SIP DOMAIN. When a user register on my service, I'd use their username and password to generate 10 sip accounts, one for each kamailio server so that they can register to any of them.  So for each user I will have to insert 10 records in the subscriber table. Is there a better way to do this?<br class="">
<br class="">
Cheers<br class="">
Jesse<br class="">
______________________________<wbr class="">_________________<br class="">
Kamailio (SER) - Users Mailing List<br class="">
<a href="mailto:sr-users@lists.kamailio.org" target="_blank" class="">sr-users@lists.kamailio.org</a><br class="">
<a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank" class="">https://lists.kamailio.org/cgi<wbr class="">-bin/mailman/listinfo/sr-users</a><br class="">
</blockquote></div>
</blockquote></div></div></div><br class=""><br class=""><span title="neteasefooter" class=""><div class=""> <br class="webkit-block-placeholder"></div></span><br class="">______________________________<wbr class="">_________________<br class="">
Kamailio (SER) - Users Mailing List<br class="">
<a href="mailto:sr-users@lists.kamailio.org" target="_blank" class="">sr-users@lists.kamailio.org</a><br class="">
<a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank" class="">https://lists.kamailio.org/cgi<wbr class="">-bin/mailman/listinfo/sr-users</a><br class="">
<br class=""></blockquote></div><br class=""></div>
</blockquote></div></div></div><br class=""><br class=""><span title="neteasefooter" class=""><div class=""> <br class="webkit-block-placeholder"></div></span><br class="">______________________________<wbr class="">_________________<br class="">
Kamailio (SER) - Users Mailing List<br class="">
<a href="mailto:sr-users@lists.kamailio.org" class="">sr-users@lists.kamailio.org</a><br class="">
<a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank" class="">https://lists.kamailio.org/<wbr class="">cgi-bin/mailman/listinfo/sr-<wbr class="">users</a><br class="">
<br class=""></blockquote></div><br class=""></div>
</blockquote></div><br class=""><br class=""><span title="neteasefooter" class=""><div class=""> <br class="webkit-block-placeholder"></div></span>_______________________________________________<br class="">Kamailio (SER) - Users Mailing List<br class=""><a href="mailto:sr-users@lists.kamailio.org" class="">sr-users@lists.kamailio.org</a><br class="">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users<br class=""></div></blockquote></div><br class=""></div></div></div></body></html>