[SR-Users] I think I found issue to Kamailio not forwarding ACK sent to it by Asterisk

Federico Cabiddu federico.cabiddu at gmail.com
Tue May 22 14:08:53 CEST 2018


You have to  listen on two different ports and advertise them according to
you routing if you have only one interface (IP) where your Kamailio is
listening to.

Cheers,

Federico

On Tue, May 22, 2018 at 2:02 PM, Wilkins, Steve <swwilkins at mitre.org> wrote:

> Good morning and thank you for your response.
>
>
>
> I thought that advertise took care of listening on Public and Private IP
> Address.
>
>
>
> I did try -
>
> listen=udp:Private-IP-Address:5060 advertise 34.226.187.61:5060
>
> listen=udp:Public-IP-Address:5060
>
> but I got errors without changing the port, My Asterisk only communicate
> on 5060, so changing the port would not help me.
>
>
>
> I do have modparam("rr", "enable_double_rr", 2); I was not sure if mhomed
> needed to be set in this scenario.
>
>
>
> I have done a lot of searching and have not many examples of the situation
> I am facing.
>
>
>
> I think I am just missing something.
>
>
>
> Thanks again!
>
>
>
> .
>
>
>
>
>
>
>
> *From:* sr-users [mailto:sr-users-bounces at lists.kamailio.org] *On Behalf
> Of *Federico Cabiddu
> *Sent:* Tuesday, May 22, 2018 2:35 AM
>
> *To:* Kamailio (SER) - Users Mailing List <sr-users at lists.kamailio.org>
> *Subject:* Re: [SR-Users] I think I found issue to Kamailio not
> forwarding ACK sent to it by Asterisk
>
>
>
> Good morning,
>
> so, if I understand correctly Kamailio is listening on a single interface
> which is natted.
>
> You need two R-R, one with the public and one with the private IP. You
> also need to put Kamailio on listen on two different ports and use the
> listen directive along with its advertise parameter.
>
>
>
> Regards,
>
>
>
> Federico
>
>
>
> On Tue, May 22, 2018 at 12:12 AM, Wilkins, Steve <swwilkins at mitre.org>
> wrote:
>
> What is actually happening is –
>
>
>
> I M USING Kamailio 5.2 with Asterisk 14.6 and 15.3.  Asterisk cannot reach
> Kamailio on Public IP (Per design)
>
>
>
> Asterisk 14.6: If Asterisk sends an ‘INVITE’ to Kamailio (on Private IP),
> then Kamailio sends back a ‘200 OK’ with its Public IP in both
> Record-Routes.
>
> Asterisk 14.6 is changing the first Record-Route to the Private-IP of
> Kamailio and also changes the Via to The same Private IP, and hence the ACK
> is
>
> sent to and received by Kamailio…Call works perfect. (Asterisk developers
> say they are not doing this!).
>
>
>
> Asterisk >= 15.0: The above mentioned Record-Route and Via do not get
> changed and hence the ACK is sent to Kamailio’ s Public IP, but never makes
> it there (because the my firewall will not allow it).
>
>
>
> This is why I was wondering if I could change the Record-Route on the
> ‘200  OK’ that is sent to Asterisk.  I just can’t figure out how to do it.
>
>
>
> Thank you for your time!
>
>
>
> *From:* sr-users [mailto:sr-users-bounces at lists.kamailio.org] *On Behalf
> Of *Federico Cabiddu
> *Sent:* Monday, May 21, 2018 5:06 PM
>
>
> *To:* Kamailio (SER) - Users Mailing List <sr-users at lists.kamailio.org>
> *Subject:* Re: [SR-Users] I think I found issue to Kamailio not
> forwarding ACK sent to it by Asterisk
>
>
>
> Not sure I understand your scenario.
>
> How many interfaces your kamailio has?
>
> How's the callflow going?
>
> Public->Kamailio->Asterisk?
>
> Did you have a look on "advertise" parameter of core "listen" directive?
>
> https://www.kamailio.org/wiki/cookbooks/5.1.x/core#listen
>
>
>
> Best regards,
>
>
>
> Federico
>
>
>
> On Mon, May 21, 2018 at 7:32 PM, Wilkins, Steve <swwilkins at mitre.org>
> wrote:
>
> Hello,
>
>
>
> I set that double route to ‘2’ and Kamailio still not hearing traffic
> coming in from Public.  I think I need to figure out how to get Kamailio to
> set the first RR in the ‘200 OK’ to its Private IP, because  the Server
> Kamailio is on may not be open to public traffic.
>
>
>
> Thank you
>
>
>
> *From:* sr-users [mailto:sr-users-bounces at lists.kamailio.org] *On Behalf
> Of *Federico Cabiddu
> *Sent:* Monday, May 21, 2018 1:08 PM
> *To:* Kamailio (SER) - Users Mailing List <sr-users at lists.kamailio.org>
> *Subject:* Re: [SR-Users] I think I found issue to Kamailio not
> forwarding ACK sent to it by Asterisk
>
>
>
> Hi,
>
> if you have Kamailio listening on private IP and public IP you need two
> record-routes.
>
> Have a look at this param of the rr module:
>
> http://www.kamailio.org/docs/modules/devel/modules/rr.html#
> rr.p.enable_double_rr
>
>
>
> Best regards,
>
>
>
> Federico
>
>
>
>
>
> On Mon, May 21, 2018 at 7:01 PM, Wilkins, Steve <swwilkins at mitre.org>
> wrote:
>
>
>
> Hello All,
>
>
>
> When Kamailio  sends a ‘200 OK’ to Asterisk, it is putting its Public IP
> into the Record-Routes.  In Asterisk 14.6, it would send the ‘ACK’ back to
> the Private IP Address of Kamailio, but Asterisk 15.x is using the Public
> IP Address that Kamailio placed in the Record-Routes so…
>
> *Is there a way to force Kamailio to set the Record-Route to its Private
> IP address of the first Record-Route in messages forwarded to Asterisk*?
>
>
>
> Thank you?
>
>
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
>
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
>
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20180522/d2fedff9/attachment.html>


More information about the sr-users mailing list