[Spce-user] SBC outbound_proxy setting

Schaefer, Larry Larry.Schaefer at pgi.com
Wed Jan 22 12:31:08 EST 2014


Barry,

Thanks for the feedback… After looking further into the issue, I am now thinking that I need to move any retry logic into the Kamailio Load Balancer layer.

From looking at examples, I might be able to either fork the initial Invite to all four of my servers, and use the server that responds first to be used and have the other Invites cancelled.

Or I might be able to send a single Invite (as I do today), but handle a 408 Timout error and send a new Invite to a different server.  I was also having an issue where my application send back a 302 Moved Temporarily which was making it back to the client (I would want to hand that at the load balancer / sbc layer).

If anyone has example of a kamailio load balancer config file that handles 408, 302, or forks Invites, I would love to see some examples… Until then, I will continue to research and see what examples I can find on the internet.

Thanks,
Larry

From: Barry Flanagan [mailto:barry at flanagan.ie]
Sent: Wednesday, January 22, 2014 4:31 AM
To: Schaefer, Larry
Cc: spce-user at lists.sipwise.com
Subject: Re: [Spce-user] SBC outbound_proxy setting

On 21 January 2014 19:13, Schaefer, Larry <Larry.Schaefer at pgi.com<mailto:Larry.Schaefer at pgi.com>> wrote:
I am trying to add SPCE with SBC application into an existing SIP architecture, seeing if I could replace an existing SBC with SPEC SBC.

I have questions about the outbound_proxy setting and how it handles failures.  The following A record points to four IP addresses, but in my architecture, I might expect only a couple of the IP addresses to respond (service is running in Amazon EC2, so servers might come and go).

Having an A record with 4 IP addresses doesn't really do what you want. Only a single IP address will be returned by DNS, just that it will change each time to return one of the 4 available. SPCE is still going to fail if the IP is is given is not available.

outbound_proxy=sip:blob.dev.us-west-1.bobdev.pgi.com<http://blob.dev.us-west-1.bobdev.pgi.com>

I am not totally sure of how outbound_proxy operates, so will leave that for others.


I have also attempted to create a service locator SVR DNS address (_sip._udp.blob.dev.us-west-1.bobdev.pgi.com<http://udp.blob.dev.us-west-1.bobdev.pgi.com>), and SBC uses that address, but also does not attempt next server if the selected server does not respond.

I would think that SRV records would be the way to go for you. However, the way you have set it up still results in only one of your 4 IPs being returned, and again, gives you no redundancy.

What you need to do is to give each of your IPs a hostname in DNS and remove the A records you have for them in blob.dev.us-west-1.bobdev.pgi.com<http://blob.dev.us-west-1.bobdev.pgi.com>, and then set up SRV records for _sip._udp.blob.dev.us-west-1.bobdev.pgi.com<http://udp.blob.dev.us-west-1.bobdev.pgi.com> for each of the 4 hostnames giving them all the same weight and priority.

Now when SPCE queries it will receive back 4 possible endpoints for SIP UDP, all with the same weight/priority and should try them all until it gets a response (assuming that outbound_proxy/SPCE is set to use DNS SRV lookups).

Have a look at http://en.wikipedia.org/wiki/SRV_record<http://en.wikipedia.org/wiki/SRV_record#Retrieving_a_SRV_record> under the section "Provisioning for high service availability"

Hope this helps.

-Barry Flanagan

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sipwise.com/mailman/private/spce-user_lists.sipwise.com/attachments/20140122/bd6861c5/attachment.html>


More information about the Spce-user mailing list