Scaling Location Services in Large SIP Networks with Kamailio

A new edition of FOSDEM(Free and Opensource Software Developers’ European Meeting) took place between 5-6 February in Brussels, Belgium.

Another great attendance this year, over 5000 people participated in almost 300 talks on various topics like Operation System, Administration, and Security. This year also marked the presence of a new Developer Room dedicated to Open Source Telephony, where projects like Asterisk, Mobicents, Yate and of course Kamailio were represented by talks regarding new features, development and administration.

This year, along with Henning Westerholt, Head of IT Operations Internet Access & Communications at 1and1, we presented the talk “Scaling Location Services in Large SIP Networks by using Kamailio”. The talk covered the functionality of a new Kamailio module called “p_usrloc” that adds some important benefits to location discovery services: redundancy of data, failover and fallback algorithms in case of emergency and load balancing of requests.

Location service is a key component in a SIP aware network. It serves the role of translating a phone number to an IP address, so it has a pivot role in any communication scenario.  When providing High Availability services to users, scaling SIP location services takes a crucial place.  One can achieve this daunting task by using several modules like “carrrierroute”, “p_usrloc”, “registrar”.

The changes from a traditional location service are represented by the usage of special locations DB, separated in two location groups. Distributing users to one of the location group is performed on a stateless proxy (often called a balancer) using the “carrierroute” module. The two statefull proxies (all running Kamailio) synchronize information using a Main Database, which allows configuration of location databases, subscriber matching, blacklisting etc.

One of the reasons for separation location information from the main database, is that the nature of that information is very ephemeral, being subject to a large number of INSERT, UPDATE and SELECT queries performed concurrently from several servers. In a location group, all queries are replicated among members, so a failure will ensure that data is still available. The fallback algorithm takes care of any obsolete data, so users of “p_usrloc” are ensured that they have the latest bindings to an AOR (Address of Record).

There are no restriction imposed on a proxy connecting to only one group, so if one proxy fails, the other one can take his part automatically and connect to the other location group, thus ensuring service is delivered without interruptions.

The module “p_usrloc” has made it into the master branch of the project. Feedback from the community was great, so new features like consistent hashing and eventual consistency are planned to the near future.

Check out the whole of the presentation at http://kamailio.org/events/2011-fosdem/p_usrloc.pdf

Category: Technology & Development
0 comments0

Your comment